当前位置:网站首页>Usage of permute() function in pytorch
Usage of permute() function in pytorch
2022-08-03 03:02:00 【Mick..】
permute() function is used for dimension transformation.It often appears in image processing. For example, the read image is in numpy format, which is (h, w, c), but the data processed by torch is (c, h, w).So this function is often used
import torch##Conform to a normal distribution with mean 0 and variance 1x=torch.randn(2,3,5)print(x.size())##Dimension transformationx=torch.permute(x,(2,0,1))print(x.size())
边栏推荐
- 数据中台建设(八):数据服务体系建设
- JVM内部结构图及各模块运行机制总结
- 怎么做postgrsql主备?
- openCV第一篇
- VS Code 这么牛,再次印证了一句名言
- The cornerstone of high concurrency: multithreading, daemon threading, thread safety, thread synchronization, mutual exclusion lock, all in one article!...
- JSP第一篇 -----JSP九大内置对象(隐式对象)和四大域对象
- 45部署LVS-DR群集
- 如何准备考pmp?
- 从 npm 切换到 pnpm,真香!
猜你喜欢
随机推荐
国标GB28181协议EasyGBS平台项目现场通知消息过多导致系统卡顿该如何解决?
南瓜科学新品上线 开辟益智玩具新世界
236. 二叉树的最近公共祖先
华为防火墙双机热备技术:HRP、VGMP、VRRP,三大技术值得一学!
PHICOMM(斐讯)N1盒子 - Armbian5.77(Debian 9)基本配置
XSS攻击
8 个常用的 Wireshark 使用技巧,一看就会
孩子坐不住就是不专注?猿辅导揭秘专注力的三大误区
[QNX Hypervisor 2.2用户手册]10 虚拟设备参考
关于提高企业网络安全意识
高并发基石:多线程、守护线程、线程安全、线程同步、互斥锁,一文扫尽!...
向往的生活
VS Code 这么牛,再次印证了一句名言
有趣简单的M2处理器性能实验:Swift与C代码执行速度的比较
优秀的 Verilog/FPGA开源项目总结及交流群
可信的SSL证书颁发机构有哪些
软件定义网络实验之SDN网络简单管理及开发
项目管理到底管的是什么?
【Swoole系列3.3】单进程管理Process
WRF-Chem模式调试、运行、结果后处理等遇到的各种问题