随笔分类 - 深度学习
摘要:https://zhuanlan.zhihu.com/p/258604402 code: https://zhuanlan.zhihu.com/p/188881658
阅读全文
摘要:NMS即non maximum suppression即非极大抑制,顾名思义就是抑制不是极大值的元素,搜索局部的极大值。在最近几年常见的物体检测算法(包括rcnn、sppnet、fast-rcnn、faster-rcnn等)中,最终都会从一张图片中找出很多个可能是物体的矩形框,然后为每个矩形框为做类
阅读全文
摘要:从 Mini-Batch SGD 说起 我们先从 Mini-Batch SGD 的优化过程讲起,因为这是下一步理解 Batch Normalization 中 Batch 所代表具体含义的知识基础。 我们知道,SGD 是无论学术圈写文章做实验还是工业界调参跑模型最常用的模型优化算法,但是有时候容易被
阅读全文
摘要:卷积后的尺寸变化计算过程: 假设图像大小为N*N矩阵 卷积核的尺寸为K*K矩阵 卷积的方式(边缘像素填充方式):P 卷积的步长为S*S 那么经过一层这样的卷积后出来的图像为: 最后得到的输出即为N*N大小图像。 池化层的尺寸变化计算过程: O=输出图像的尺寸。I=输入图像的尺寸。S=移动步长Ps=池
阅读全文
摘要:官方文档:https://pytorch.org/docs/stable/nn.html#loss-functions 1:torch.nn.L1Loss mean absolute error (MAE) between each element in the input x and target
阅读全文
摘要:# ckpt转saved_model并自定义输入输出tensor名字input_node = tf.placeholder(tf.float32, shape=(None, None, None, 3),name="input") logits_tf = network.deeplab_v3(inp
阅读全文
摘要:with tf.Session() as sess: # The `Iterator.string_handle()` method returns a tensor that can be evaluated # and used to feed the `handle` placeholder.
阅读全文
摘要:###################### 在将tensorflow 的.ckpt文件转成pb文件和pb文件测试时需要网络节点的输入和输出名称 以下方法,。均不可行!!!!! ###################### with tf.Session() as sess: # 加载模型定义的gr
阅读全文
摘要:https://zhuanlan.zhihu.com/p/28216012
阅读全文
摘要:卷积的计算方法: 步长为1的卷积的动态过程: 三通道输入,俩个卷积核的动态计算过程: 讲的很清楚的专栏:https://zhuanlan.zhihu.com/p/27908027,https://zhuanlan.zhihu.com/p/28173972 (太惭愧了,人家写的这么清楚都觉得力不从心转
阅读全文
摘要:对比tf来说简单了好几个量级。。 1. 先建立一个字典,保存三个参数: # 只保存了参数 state = {‘net':model.state_dict(), 'optimizer':optimizer.state_dict(), 'epoch':epoch}torch.save(state, mo
阅读全文
摘要:源码:class AverageMeter(object): """Computes and stores the average and current value""" def __init__(self, name, fmt=':f'): self.name = name self.fmt =
阅读全文
摘要:1 img = cv2.imread("4.jpg") #是BGR格式,数据范围在 0~255,通道格式为(H,W,C) 2 height, width, channel = img.shape 3 img = cv2.resize(img,(width, height))
阅读全文
摘要:命令:whereis cudnn.h CUDNN_H_PATH=$(whereis cudnn.h) cat ${CUDNN_H_PATH} | grep CUDNN_MAJOR -A 2 结果:#define CUDNN_MAJOR 7 #define CUDNN_MINOR 5 #define
阅读全文
摘要:Num elementsParameter nameDescriptionTypeRangeExample 1 Class names The class to which the object belongs. String N/A Person, car, Road_Sign 1 Truncat
阅读全文
摘要:1:前言 提起TensorFlow的模型,大家最熟知的莫过于checkpoint文件了,但是其实TensorFlow 1.0 以及2.0 提供了多种不同的模型导出格式,除了checkpoint文件,TensorFlow2.0官方推荐SavedModel格式,使用tf.serving部署模型的时候采用
阅读全文
浙公网安备 33010602011771号