当前位置:网站首页>Multi line display and single line display of tqdm
Multi line display and single line display of tqdm
2022-07-02 11:12:00 【lanmy_ dl】
introduce
from tqdm import tqdm
pbar = tqdm(total=n_batches)
Single line display
shortcoming , Can't see the process of change , Because it will cover ; advantage , Save screen , It's comfortable to see
for Cyclic data retrieval process
pbar.set_description('Train loss: %.3f / loss %.3f' % (train_loss / (i + 1), loss.item()))
pbar.update()
pbar.close()
like
Multi line display
Don't shut down close() Multi line display
for Cyclic data retrieval process
pbar.set_description('Train loss: %.3f / loss %.3f' % (train_loss / (i + 1), loss.item()))
pbar.update()
Supplement the complete cycle
The above cycle is train It takes each data to train the cycle , This is often the case
for i,(img, label) in enumerate(train_loader):
pbar.set_description('Train loss: %.3f / loss %.3f' % (train_loss / (i + 1), loss.item()))
pbar.update()
pbar.close() # If a single line shows that this line does not
边栏推荐
- How to use ide to automatically sign and debug Hongmeng application
- MTK full dump抓取
- JSP webshell free -- the basis of JSP
- 二叉树专题--AcWing 18. 重建二叉树(利用前、中序遍历,构建二叉树)
- Primary key policy problem
- K-d tree and octree of PCL
- Complement (Mathematical Simulation
- PCL point cloud to depth image
- III Chip startup and clock system
- php中self和static在方法中的区别
猜你喜欢
二叉树专题--AcWing 3384. 二叉树遍历(已知先序遍历 边建树 边输出中序遍历)
[play with FPGA learning 2 in simple terms ----- design skills (basic grammar)]
二叉树专题--AcWing 1497. 树的遍历(利用后、中序遍历,构建二叉树)
ImportError: cannot import name ‘Digraph‘ from ‘graphviz‘
Tick Data and Resampling
【AGC】构建服务3-认证服务示例
如何用list组件实现tabbar标题栏
Mongodb learning and sorting (condition operator, $type operator, limit() method, skip() method and sort() method)
How to use ide to automatically sign and debug Hongmeng application
三.芯片啟動和時鐘系統
随机推荐
二叉树专题--AcWing 3384. 二叉树遍历(已知先序遍历 边建树 边输出中序遍历)
How to implement tabbar title bar with list component
Uncover the secrets of Huawei application market application statistics
二叉树专题--洛谷 P1229 遍历问题(乘法原理 已知前、后序遍历求中序遍历个数)
【深入浅出玩转FPGA学习5-----复位设计】
快应用中实现自定义抽屉组件
华为联机对战服务玩家掉线重连案例总结
JVM garbage collector
Luogu p4281 [ahoi2008] emergency gathering / gathering (tree doubling LCA)
Point cloud projection picture
TIPC Service and Topology Tracking4
华为应用市场应用统计数据问题大揭秘
QT学习日记8——资源文件添加
Special topic of binary tree -- acwing 1497 Traversal of the tree (use post and mid order traversal to build a binary tree)
Primary key policy problem
Appgallery connect scenario development practice - image storage and sharing
一.STM32的开发环境,keil5/MDK5.14安装教程(附下载链接)
TIPC Service and Topology Tracking4
spritejs
JSP webshell free -- the basis of JSP