赞
踩
说明:本次实验仅为模型转换步骤的验证,所以不涉及模型训练部分。
源码地址:https://github.com/WongKinYiu/yolov7.git
模型地址:https://github.com/WongKinYiu/yolov7/releases/download/v0.1/yolov7.pt
def forward(self, x):
# x = x.copy() # for profiling
z = [] # inference output
self.training |= self.export
for i in range(self.nl):
x[i] = self.m[i](x[i]) # conv
bs, _, ny, nx = x[i].shape # x(bs,255,20,20) to x(bs,3,20,20,85)
x[i] = x[i].view(bs, self.na, self.no, ny, nx).permute(0, 1, 3, 4, 2).contiguous()
if not self.training: # inference
if self.grid[i
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。