原创 Python opencv添加聖誕帽,不需要微信官方

聖誕帽,命名爲hat.png,注意是png文件 person code: import cv2 from PIL import Image personPath = './xyjy.jpg' hatPath = './h

原创 tensorflow saver.restore()

加載pretrained_model模型 -需要注意的是,tensorflow提供了下列函數,可以將pretrained_model設爲文件夾,自動檢查並加載上次save的ckpt文件。 - 下面是facenet訓練時的加載上次

原创 tf.contrib.slim.conv2d 與 tf.nn.conv2d 區別

一般會 import tf.contrib.slim as slim slim.conv2d slim.conv2d(inputs, num_outputs, kernel_size, stride = 1, padding =

原创 Pytorch SSD jupyter notebook demo 報錯:need more than 0 values to unpack

pytorch ssd github : https://github.com/amdegroot/ssd.pytorch 運行demo中的demo.ipynb時,出現 need more than 0 values to unp

原创 秋招進展

今年找工作,所以接近一年沒寫博客了。 秋招崗位是cv算法崗,拿到了百度ssp,華爲sp,京東sp,大疆等公司的offer,最後選了華爲的Noah’s Ark Lab. 回學校了繼續努力,圖書館環境真好,接着好好學習,嘿嘿。 百度實

原创 python unicode 及解碼編碼方式簡介

python及編碼原理測試 基於utf—8環境。 #coding:utf-8 unicode爲通用編碼。 coding:utf-8的作用是聲明python解釋器及str的編碼方式,並不改變其他sys.getdefaultenco

原创 python list賦值不改變

list賦值 在修改facenet程序時,發現用攝像頭中出現兩個人臉的時候,每次只能框一個人臉,而5個特徵點則兩個人都能顯示。經過一番篩查,是在識別人臉的程序中,list初始化 bb = np.zeros(4,dtype=np.

原创 Leetcode 12 integer-to-roman

https://leetcode.com/problems/integer-to-roman/discuss/ Given an integer, convert it to a roman numeral. Input is

原创 Resnet-Tensorflow 在Mask-Rcnn 中的結構

閱讀Mask-Rcnn代碼時,觀察resnet結構。 其中重要的有identity_block和conv_block。 Identity Block: 1*1,3*3,1*1的三層stride=(1,1)卷積,最後直接輸出x+i

原创 *** Error in `appstreamcli': double free or corruption (fasttop): 0x00000000021ebfc0 ***

* Error in `appstreamcli’: double free or corruption (fasttop): 0x00000000021ebfc0 * ai@ai-X7Ti-Series:~$ sudo apt

原创 facenet-tensorflow人臉識別

項目地址:https://github.com/davidsandberg/facenet facenet基於MTCNN的人臉檢測和Inception-Resnet-v1的人臉識別網絡 softmax,center loss 訓

原创 tf.get_variable 和tf.variable_scope

http://blog.csdn.net/u012436149/article/details/53081454 http://blog.csdn.net/Jerr__y/article/details/70809528

原创 opencv 代替caffe.io.load_image

self.net.blobs['data'].reshape(1, 3, self.image_resize, self.image_resize) #image = caffe.io.load_image(image_file)

原创 numpy stack vstack hstack concatenate

基本都用作連接字符串,只是連接維度不同,而且hstack和vstack 相對於stack,不受兩個字符串shape必須相同的限制。 import numpy as np test_1 = np.array([[1, 2, 3],

原创 openCV3 cv2.putText()

找了很多cv2.putText,總提示 TypeError:an integer is required TypeError:integer argument expected, got float 只有這個好使 openCV