自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(16)
  • 收藏
  • 关注

原创 安装caffe

安装caffe下载:git clone https://github.com/BVLC/caffe.git修改 Makefile.config 文件进入 caffe ,sudo cp Makefile.config.example Makefile.configsudo gedit Makefile.config1.应用 cudnn将#USE_CUDNN := 1修改成: USE_CUDNN :=...

2018-03-08 10:47:21 305

原创 python3 tensorflow 模型的保存与恢复

保存model_path = r'C:\Users\。。。\Desktop\model.ckpt'init = tf.global_variables_initializer()saver = tf.train.Saver()with tf.Session() as sess:sess.run(init)训练save_path = saver.save(sess,

2018-02-01 11:27:44 461

原创 目标检测代码Faster-RCNN_TF

(1)编译时报错:/usr/local/lib/python2.7/dist-packages/tensorflow/include/tensorflow/core/platform/default/mutex.h:25:22: fatal error: nsync_cv.h: No such file or directory(之前TFFRCNN-master改用python2.7版本时

2018-01-04 16:54:38 9300 8

原创 目标检测代码mx-rcnn

(1)demo可以跑通,可以实现自己图片的目标检测python demo.py --prefix final --epoch 0 --imageimage1.jpg --gpu 0 --vis(2)训练bash script/vgg_voc07.sh 0报错:TypeError: init_params() got an unexpected keyword argumen

2018-01-04 16:50:18 1499

原创 python数据处理

1.读入excel数据import pandas as pdimport numpy as npdf=pd.read_excel(r'*****.xlsx')2.按列取数据# xx=df.ix[1:200,['name0','name1']]# yy=df.ix[1:200,['name3']]# xx=df.loc[1:200,['name0','

2017-09-06 16:38:59 327

原创 TypeError: string argument expected, got 'bytes'

代码:# 导入仿真库import tensorflow as tfimport numpy as np# 导入可视化库import PIL.Imagefrom cStringIO import StringIOfrom IPython.display import clear_output, Image, displayimport scipy.ndimage as nd

2017-08-25 13:34:55 2159 1

原创 TypeError: 'float' object cannot be interpreted as an integer

代码:A = np.random.rand(1e4, 1e4).astype('float32')报错:TypeError: 'float' object cannot be interpreted as an integer解决办法:A = np.random.rand(10000, 10000).astype('float32')

2017-08-24 15:25:17 21977

原创 TypeError: Input 'b' of 'MatMul' Op has type float32 that does not match type int32 of argument 'a'.

tensorflow word embedding代码:loss = tf.reduce_mean( tf.nn.nce_loss(nce_weights, nce_biases, embed, train_labels, num_sampled, vocabulary_size))报错:TypeError: Input 'b'

2017-08-24 12:30:23 19092 1

原创 TypeError: Expected int32, got list containing Tensors of type '_Message' instead.

代码:def convolve(img, W):    # The W matrix is only 2D    # But conv2d will need a tensor which is 4d:    # height x width x n_input x n_output    if len(W.get_shape()) == 2:        dims =

2017-08-21 16:09:46 564

原创 AttributeError: module 'tensorflow' has no attribute 'sub'

代码:import tensorflow as tfsess = tf.InteractiveSession()x = tf.Variable([1.0, 2.0])a = tf.constant([3.0, 3.0])x.initializer.run()sub = tf.sub(x, a)print (sub.eval())报错:Attr

2017-08-21 14:22:28 1570

原创 NameError: name 'xrange' is not defined

代码:import tensorflow as tfimport numpy as np# 用 NumPy 随机生成 100 个数据x_data = np.float32(np.random.rand(2, 100)) y_data = np.dot([0.100, 0.200], x_data) + 0.300# 构造一个线性模型b = tf.Vari

2017-08-21 13:59:57 2176 1

原创 Cannot interpret feed_dict key as Tensor: Can not convert a method into a Tensor.

代码:input1 = tf.placeholder(tf.types.float32)input2 = tf.placeholder(tf.types.float32)output = tf.mul(input1, input2)with tf.Session()as sess:print sess.run([output], feed_dict={input:[

2017-08-21 13:36:02 10085 2

原创 TypeError: 'str' object is not callable

from urllib import requestresponse = request.urlopen("http://www.baidu.com/")  # 打开网站fi = open("project.txt", 'w')                        # open一个txt文件page = fi.write(str(response.read()))  

2017-08-10 15:33:58 353

原创 installation of package ‘car’ had non-zero exit status

R语言安装car包报错:installation of package ‘car’ had non-zero exit status安装程序包‘E:/car_2.1-5.tar.gz’时退出狀態的值不是0升级RR3.3.3升级为R3.4.1car_2.1-5.tar.gz就会变为zip就不会报错了

2017-07-11 17:11:16 15210 1

原创 'E:\Program' 不是内部或外部命令,也不是可运行的程序 或批处理文件。

R语言安装包时报错'E:\Program' 不是内部或外部命令,也不是可运行的程序 或批处理文件。解决方法:把R安装在C盘

2017-07-11 17:03:58 6114

原创 Error in nnet.default(x, y, w, ...) : too many (2651) weights

R语言神经网络建模ji.nnet报错Error in nnet.default(x, y, w, ...) : too many (2651) weights解决方法:(都可)(1)减小size(2)设置MaxNWts参数(默认值1000)> 2651注意:MaxNWts首字母大写,在某本书中这个字母小写,所以改完了之后还是报错。

2017-07-11 16:37:48 3285 2

空空如也

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除