Closed longlizhi closed 1 year ago
请问可以更新添加CA.py注意力机制的代码吗?我在github找的CA.py的源代码按照你的方法添加一直报错(我是选择在Concat后面加注意力机制),报错如下:
Traceback (most recent call last): File "/hone/hndx/11z/yolow7-main-sE_cA/models/yolo. py",1ine 830, in model=Model(opt. cfg). to(device) File"/home/hudx/11z/yolow7-main-sE CA/nmodels/yolo. py", line 528, in init. self. model, self. save=parse. model(deepcopy(seLf. yamt), ch=[ ch])# model, savelist File "/home/hndx/LLz/yolayZ-main-SE CA/modets/yotopy", line 806, in parse_model m=nn. Sequential([m( args) forin range(n)]) if n>1 else m(* args)# module FiLe "/home/hnex/11z/yoLov7-main-SE CA/models/comon. py", Line 69, in init seLf. att=CoordAtt(channel TypeError: init-() missing 1 required positionat argument:' oup'
希望作者可以帮忙解答,谢谢
这不是说缺少一个输入参数吗
请问可以更新添加CA.py注意力机制的代码吗?我在github找的CA.py的源代码按照你的方法添加一直报错(我是选择在Concat后面加注意力机制),报错如下:
Traceback (most recent call last): File "/hone/hndx/11z/yolow7-main-sE_cA/models/yolo. py",1ine 830, in
model=Model(opt. cfg). to(device)
File"/home/hudx/11z/yolow7-main-sE CA/nmodels/yolo. py", line 528, in init.
self. model, self. save=parse. model(deepcopy(seLf. yamt), ch=[ ch])# model, savelist
File "/home/hndx/LLz/yolayZ-main-SE CA/modets/yotopy", line 806, in parse_model m=nn. Sequential([m( args) forin range(n)]) if n>1 else m(* args)# module
FiLe "/home/hnex/11z/yoLov7-main-SE CA/models/comon. py", Line 69, in init
seLf. att=CoordAtt(channel
TypeError: init-() missing 1 required positionat argument:' oup'
希望作者可以帮忙解答,谢谢