Comments (1)
@liluxing153
一般来说,网络的推理速度指的是神经网络跑完一次forward的速度,也就是上面
with torch.no_grad():
pred = net(img)
这一句的时间,按照你的速度应该也有200FPS,这个是比较通用的做法。
那为什么图像预处理或者后处理的时间不算呢?这主要是因为在真实的系统中,相机采集的数据是直接在内存中的,后端的网络输入是可以直接对接内存中的相机数据的,所以你在img_transforms中从硬盘读取的时间、转换成RGB的时间、归一化的时间、再把它挪到cuda内存上等等的时间都是不存在的。
那么后处理呢?其实你观察后处理的代码就可以发现核心的逻辑就是一个softmax再加上一个乘法求期望,这点计算量相比于神经网络的计算量九牛一毛,为什么还会比网络推理慢呢?这主要是由于为了方便用python的循环实现的,如果真正部署换成其他的方式,这点计算量是几乎没有延迟的。
综上,计算网络速度是看的网络推理速度,这也是一般的通用做法。
from ultra-fast-lane-detection-v2.
Related Issues (20)
- how to label for data
- 关于数据集转换
- 如何测试 论文中的 time 和fps
- 弯道的优化思路 HOT 1
- 根据CULane做测试的时候,训练莫名被killed HOT 6
- 无法生成culane_anno_cache.json文件 HOT 7
- 自己的dataset的__getitem__使用my_interp,出现re-initialize CUDA in forked subproces的问题
- 训练过程中会找不到一个文件
- 能否像V1那样使用辅助分支的方法训练
- 当我启用了SegHead结构后,就发生了报错。 HOT 2
- 更改输入网络的图片大小之后还有哪些需要修改 HOT 1
- curvelanes HOT 1
- Tusimple数据集问题
- 请问是否能够读取摄像头画面并实时进行预测呢?该如何设置? HOT 2
- python test.py python test.py configs/culane_res18.py --test_model --test_work_dir 时报错:No such file or directory: 'list/test.txt' HOT 1
- cuda installation
- Some raw file doesn't exist
- CULane data error
- demo.py for curvelane
- Calculating TN and TP for TuSimple
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ultra-fast-lane-detection-v2.