- 博客(145)
- 资源 (47)
- 收藏
- 关注
原创 Winograd算法实现卷积原理
Fast Algorithms for Convolutional Neural NetworksWinograd算法实现卷积原理
2022-05-21 15:46:02
3429
原创 TensorFlow pb模型修改和优化
TensorFlow 模型训练完成后,通常会通过frozen过程保存一个最终的pb模型。保存的pb模型是以GraphDef数据结构保存的,可以序列化保存为二进制pb模型或者文本pbtxt模型。GraphDef本质上是一个DAG有向无环图,里面主要是存放了一个算子node list,每个算子具有名称,attr等内容,以及通过input包含了node之间的连接关系。整个GraphDef的输入节点是以Placeholder节点来标识的,模型参数权重通常是以Const节点来保存的。不同于onnx,G...
2022-05-11 20:00:17
3008
原创 Roof-line Model性能分析模型简介
refRoofline Model与深度学习模型的性能分析 - 知乎Roofline: An Insightful Visual Performance Model for Floating-Point Programs and Multicore Architectureshttps://people.eecs.berkeley.edu/~kubitron/cs252/handouts/papers/RooflineVyNoYellow.pdfRoof-line Model模型简介..
2022-05-07 17:30:50
2612
原创 windows下sublime text 3使用clang format格式化C++代码
ref:Windows下clang-format的安装_wanlong1215的博客-CSDN博客_clang-format windowshttps://gist.github.com/danielTobon43/51764026f95240bbd03991089f0380a8llvm下载:Download LLVM releases安装后在sublime text package control里面安装clang format插件然后设置该插件:Settin...
2022-04-25 09:06:19
2583
原创 PyTorch模型转onnx
pytorch模型转onnx有几种方式实际数据输入jit trace方式torch script方式example 1(optional) Exporting a Model from PyTorch to ONNX and Running it using ONNX Runtime — PyTorch Tutorials 1.11.0+cu102 documentation# Super Resolution model definition in PyTorchimp
2022-03-17 15:00:46
9192
11
原创 openNMT-py CTranslate2性能对比流程
https://github.com/OpenNMT/OpenNMT-pypip install OpenNMT-pypip install ctranslate2参考OpenNMT-py github主页链接下载Pretrained models基于WMT训练的English-German - Transformer
2022-03-15 19:03:45
3550
3
原创 深度学习模型DAG拓扑排序
【图论】有向无环图的拓扑排序 - Treant - 博客园图基本无序需要多久排序问题特殊性如果一个图的节点基本有序需要多少时间进行排序
2022-02-09 14:54:05
1484
原创 TensorFlow不重新编译源码使用C/C++ API推理
E tensorflow/core/common_runtime/session.cc:67] Not found: No session factory registered for the given session options: {target: "" config: } Registered factories are {}.create new session failed
2021-12-30 16:58:37
2150
原创 NVIDIA GPU SM和CUDA编程理解
本文旨在加深理解GPU底层硬件架构以及硬件如何执行CUDA 程序的细节,并且反过头来进一步指导CUDA程序的编写。
2021-11-13 22:08:20
6989
2
原创 TensorFlow C++接口推理
下载TF代码,配置tfgit clone -b v1.14.0 https://github.com/tensorflow/tensorflow.gitcd tensorflow./configure # 配置tf编译选项编译tf so,ABI根据实际需要配置bazel build --cxxopt="-D_GLIBCXX_USE_CXX11_ABI=0" --config=opt //tensorflow:libtensorflow_cc.sobazel build --cxxopt
2021-10-26 21:10:40
603
原创 TensorFlow wide and deep模型保存和推理
保存saved model# infer input shapes and types from feature_columns as a parse_example_specparse_example_spec = tf.feature_column.make_parse_example_spec(deep_columns + wide_columns)print("parse_example_spec:", parse_example_spec)# expose serialized .
2021-10-11 22:00:33
456
2
原创 通过NVIDIA tensorflow使用cuda11和cudnn8
官方的tensorflow1.1x只支持cuda10.0和cudnn7,如何在更高的版本cuda和cudnn8使用tensorflow1.1x呢?最简单的方法是使用nvidia修改后的tensorflow:GitHub - NVIDIA/tensorflow: An Open Source Machine Learning Framework for EveryoneTensorFlow User Guide :: NVIDIA Deep Learning Frameworks Documentatio
2021-09-27 15:16:05
1464
原创 onnx模型图优化/模型修改
onnx模型修改、添加Node如何修改已有的ONNX模型 - 知乎ONNX内部节点修改方法_麦克斯韦恶魔的博客-CSDN博客onnx模型如何增加或者去除里面node,即修改图方法_The space of Shining-CSDN博客
2021-09-15 16:08:33
14884
1
原创 pytorch性能profiling
https://pytorch.org/blog/introducing-pytorch-profiler-the-new-and-improved-performance-tool/https://pytorch.org/tutorials/recipes/recipes/profiler_recipe.html
2021-06-01 11:16:20
2984
原创 Conv2D + batch normalization (BN) 融合
基本原理:利用卷积的线性性,将bn融合到conv2d的kernel和附加一个biasaddconv2d原理https://towardsdatascience.com/conv2d-to-finally-understand-what-happens-in-the-forward-pass-1bbaafb0b148conv2d+bn融合bn的gamma, betta, mean, var都是一个维度跟conv2d output channel维数相同的向量...
2021-04-08 20:49:47
3284
原创 git常用
git statusgit add -Agit push -fgit reset --soft "HEAD~1"git commit -m "xx"git remote add upstream xx.gitgit fetch upstreamgit checkout mastergit merge upstream/mastergit log --pretty=onelinegit rebase -i HEAD~2
2021-01-29 10:09:54
90
原创 c/c++ python之间named pipe进程间通信
https://www.cnblogs.com/MrListening/p/5858358.htmlhttps://www.cnblogs.com/biyeymyhjob/archive/2012/11/03/2751593.htmlhttps://zhuanlan.zhihu.com/p/58489873https://www.cnblogs.com/-wenli/p/13100104.html
2021-01-05 19:21:53
1798
2
原创 不同C++库ABI兼容问题解决方法
工作中偶尔会遇到使用多个C++库,但是这些库采用不同ABI编译的情况,有的采用ABI=0,有的采用ABI=1,不同ABI的so库是无法直接链接使用的。通常有两种解决方法:1:获得所有库的代码,从源码开始将所有库编译成相同的ABI设置。但有时候这个方法由于不开源不可能实现,或者实现非常麻烦。2:可以考虑通过适配器方式,通过C接口(extern C)的方式对库进行封装开放C API,使得不同ABI都可以进行调用。...
2020-11-24 20:48:21
2679
原创 C++通过pybind11调用Python 实现transpose
https://www.jianshu.com/p/c912a0a59af9https://stackoverflow.com/questions/44659924/returning-numpy-arrays-via-pybind11https://gist.github.com/terasakisatoshi/79d1f656be9023cc649732c5162b3fc4
2020-11-19 17:37:54
4136
原创 TensorFlow c++ dump graph to pbtxt
https://github.com/tensorflow/ngraph-bridgengraph-bridge-0.22.0-rc4\logging\tf_graph_writer.*#include <fstream>#include <iomanip>#include <iostream>#include <sstream>#include "tensorflow/core/framework/attr_value_util.h"#i
2020-10-22 17:04:33
498
原创 tensorflow bazel编译问题
TensorFlow bazel版本判断:TensorFlow下载目录的configure.py里面有_TF_MIN_BAZEL_VERSION,_TF_MAX_BAZEL_VERSION安装方法:在bazel github下载对应版本的bazel-2.0.0-installer-linux-x86_64.sh,然后./bazel-2.0.0-installer-linux-x86_64.sh --userPKIX path building failed: sun.secu....
2020-10-19 16:58:23
2188
2
原创 TensorFlow查看pb模型节点信息
example:import tensorflow as tfimport os model_dir = './'model_name = 'ocr.pb'def create_graph(): with tf.gfile.FastGFile(os.path.join( model_dir, model_name), 'rb') as f: graph_def = tf.GraphDef() graph_def.ParseFromS.
2020-08-22 18:26:57
2388
原创 设计模式博客
设计模式https://www.jianshu.com/p/e55fbddc071chttps://blog.csdn.net/varyall/article/details/82355964设计模式图解https://refactoringguru.cn/design-patterns/catalog
2020-06-11 09:18:20
207
原创 C++11 常用新特性
https://docs.microsoft.com/en-us/cpp/cpp/smart-pointers-modern-cpp?view=vs-2019https://docs.microsoft.com/en-us/cpp/cpp/how-to-create-and-use-shared-ptr-instances?view=vs-2019https://www.cnblogs.com/jiayayao/p/6128877.htmlraw指针需要手动new delete而智能指.
2020-05-12 21:32:03
1320
原创 常用算法 BFS DFS 广度,深度优先搜索
BFS:graph = { "A":["B", "C"], # 与A相连的节点是B,C "B":["A", "C", "D"], # 与B相连的节点是A,C,D "C":["A", "B", "D", "E"], "D":["B", "C", "E", "F"], "E":["C", "D"], "F":["D"] }def visit_node(node): print(node, "->")def bfs(graph,
2020-05-10 15:27:17
290
原创 gcc简单案例
gcc编译so和可执行文件gcc -o libfun1.so -shared -fPIC fun1.cpp就可以得到文件名为libhello.so的文件了。其中 -shared选项说明编译成的文件为动态链接库,不使用该选项相当于可执行文件-fPIC 表示编译为位置独立的代码,不用此选项的话编译后的代码是位置相关的。所以动态载入时是通过代码拷贝的方式来满足不同进程的需要,而不能达到真...
2020-04-19 18:33:55
434
原创 cmake简单案例
# cmake 最低版本需求cmake_minimum_required(VERSION 3.13)# 工程名称project(cmake_study LANGUAGES CXX)# 设置set(CMAKE_CXX_STANDARD 11)# cmake subdirectory# add_subdirectory(lib)# cmake build library# ...
2020-04-19 18:24:12
1163
3
原创 TensorFlow estimator教程列表
estimatorTensorFlow Estimators: Managing Simplicity vs. Flexibility inHigh-Level Machine Learning Frameworks (https://arxiv.org/abs/1708.02637)https://medium.com/learning-machine-learning/introdu...
2020-03-22 11:18:26
271
原创 Windows下运行Shell脚本
在Windows操作系统下运行Shell脚本,缺少的只是一个Git软件。其下载路径为Git - Downloading Package。安装之后,将安装路劲下的bin文件夹的路径添加到系统环境变量。于是我们就能够在CMD中通过sh xxx.sh来运行Shell脚本。转自https://zhuanlan.zhihu.com/p/59451678...
2020-02-25 10:33:46
19870
原创 MNIST数据读取-numpy版本
MNIST数据集地址:http://yann.lecun.com/exdb/mnist/格式解释范例超简单的numpy读取代码:import numpy as nptrain_images_path = 'train-images.idx3-ubyte'train_labels_path = 'train-labels.idx1-ubyte'test_image...
2020-02-08 20:42:55
550
转载 Linux的硬盘使用情况、挂载、SSD挂载
参考Linux的硬盘使用情况、挂载、SSD挂载(查看df -h不能看到的卷)https://www.cnblogs.com/lemon-flm/p/7597403.htmllinux 硬盘分区,分区,删除分区,格式化,挂载,卸载笔记https://www.cnblogs.com/phpk/p/10514736.html关键命令:lsblk, df -hLinux...
2020-02-03 16:01:04
496
原创 使用国内镜像源安装pytorch
先设置镜像源,如清华的conda镜像(可参考其他博客)conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/free/conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda...
2020-01-31 21:58:58
16556
3
原创 python代码格式化
除了pylint工具可以扫描代码不符合规范之处外,也有软件包可以自动对代码格式进行修改。自动将代码转换为pep8格式的python库autopep8,使用教程参考博客:Pycharm配置autopep8:自动调整代码为PEP8风格,in short:安装:pip install autopep8使用:autopep8 --in-place --aggressive <...
2020-01-17 09:43:35
439
原创 TensorFlow通过raw_ops调用底层op计算
example 1 简单加法import tensorflow as tfimport numpyx = 10y = 20a = tf.raw_ops.Add(x=x, y=y)# Start trainingwith tf.Session() as sess: # Run the initializer print(sess.run(a))...
2019-12-02 22:05:57
2013
6
DeepSpeed System Optimizations Enable Training Deep Learning
2021-10-23
Netron-Setup-4.5.0.zip
2020-09-12
cmake-3.17.2-win64-x64.zip
2020-05-23
伯克利 常用经典算法.pdf
2019-09-04
伯克利 常用经典算法.zip
2019-09-04
Practical data acquisition for instrumentation and control systems
2018-12-10
Protocol Buffer sublime text 3插件
2018-08-06
概率分布手册Hand-book on statistical distributions for experimentalists
2018-03-01
BFGS Optimization curve fitting 优化曲线拟合
2017-12-07
Handbook of Fluorescence Spectroscopy and Imaging
2017-11-23
CRLB 讲解PPT
2017-10-03
Principles of Optics 7th ed M.Born,E.Wolf.pdf 光学原理
2017-09-01
Principles of Fluorescence Spectroscopy Third Edition Joseph R Lakowicz.pdf
2017-08-13
免费高清屏幕录制软件FreeScreenVideoRecorder_3.0.45.1027
2016-11-10
深度学习 Deep Learning book, MIT, Ian Goodfellow, Aaron Courville, and Yoshua Bengio
2016-04-22
nnImplementationV2 神经网络C++实现
2016-04-21
sublime text 2 3 system verilog自动补充插件
2015-02-01
altera官方上海Quartus II时序分析相关三天培训教材练习实例_day3
2015-01-30
altera官方上海Quartus II时序分析相关三天培训教材练习实例_day2
2015-01-30
altera官方上海Quartus II时序分析相关三天培训教材练习实例_day1
2015-01-30
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人
RSS订阅