1、tflearn安装: tflearn安装的前提是scipy已经安装好,conda install numpy pandas jupyter notebook matplotlib 然后:conda install scipy h5py 最后:sudo pip install git+https: ...
分类:
系统相关 时间:
2018-10-06 16:32:18
阅读次数:
139
ipdb介绍 1、现在IPython之外使用debug功能,则需要安装ipdb(pip install ipdb),而后在需要进入调试的地方加上如下代码即可: import ipdb ipdb.set_trace() 2、命令 功能 h(elp) 显示帮助信息,help command显示这条命令的 ...
分类:
数据库 时间:
2018-10-05 17:13:57
阅读次数:
469
张量——N-dim 数组 1. 数组的创建 2. 符号数组的创建 3. 一维数组改变形状创建 4. 切片操作 5. 符号数组操作 6. 数组转化为列表 7. 维度为2的数组可以转化为矩阵 ...
分类:
其他好文 时间:
2018-10-02 20:24:45
阅读次数:
124
关于Anaconda的安装就不介绍了,本文主要介绍spyder中安装 tensorflow。废话少说 直接重点: 1、安装好Anaconda之后,找到spyder图标 点击install,等待安装完成(下面是已经安装好了的) 接着点击 左边的Environments 找到对应的环境,下载tensor ...
分类:
其他好文 时间:
2018-09-30 22:44:57
阅读次数:
202
从官网拷贝过来的,就是做个学习记录。版本 0.4 tensor to numpy 输出 进行转换 输出 注意,转换后的tensor与numpy指向同一地址,所以,对一方的值改变另一方也随之改变 numpy to tensor 输出 除chartensor外所有tensor都可以转换为numpy ...
分类:
其他好文 时间:
2018-09-30 22:38:55
阅读次数:
452
#最近要跑一个demo,需要用到tutorial_vgg19.py,原作者给的链接没有在github上,CSDN上找到了,但是格式是乱的,没办法只能自己把格式调了一下,结果还是好的,可以运行# -*- coding: utf-8 -*-"""VGG-19 for ImageNet.Pre-train ...
分类:
其他好文 时间:
2018-09-27 22:16:19
阅读次数:
821
torch.ger(vec1, vec2, out=None) → Tensor Outer product of vec1 and vec2. If vec1 is a vector of size nn and vec2 is a vector of size mm, then out must ...
分类:
其他好文 时间:
2018-09-27 19:47:56
阅读次数:
361
RuntimeError:one of the variables needed for gradient computation has been modified by an inplace operation 原因:0.4.0把Varible和Tensor融合为一个Tensor,inplace ...
分类:
其他好文 时间:
2018-09-24 00:26:36
阅读次数:
2407
//加上了注释,对pytorch又加深了理解import torch as t from torch import nn from torch.autograd import Variable from torch.optim import Adam from torchvision import ... ...
分类:
其他好文 时间:
2018-09-23 18:27:24
阅读次数:
310
torch.distributions.Categorical() 功能:根据概率分布来产生sample,产生的sample是输入tensor的index 如: >>> m = Categorical(torch.tensor([ 0.25, 0.25, 0.25, 0.25 ])) >>> m.s ...
分类:
其他好文 时间:
2018-09-23 16:26:33
阅读次数:
2068