Open louxiantuo opened 4 years ago
You need to generate it yourself and its organization is in the readme
根据您给的对于在readme上给的结构,我自己生成了,类似以下的txt:
D:/xunleiDownload/DASNet-master/DASNET/dataset/ChangeDetectionDataset/Model/with_shift/train/A/00000.jpg
D:/xunleiDownload/DASNet-master/DASNET/dataset/ChangeDetectionDataset/Model/with_shift/train/B/00000.jpg
D:/xunleiDownload/DASNet-master/DASNET/dataset/ChangeDetectionDataset/Model/with_shift/train/OUT/00000.jpg
D:/xunleiDownload/DASNet-master/DASNET/dataset/ChangeDetectionDataset/Model/with_shift/train/A/00001.jpg
D:/xunleiDownload/DASNet-master/DASNET/dataset/ChangeDetectionDataset/Model/with_shift/train/B/00001.jpg
D:/xunleiDownload/DASNet-master/DASNET/dataset/ChangeDetectionDataset/Model/with_shift/train/OUT/00001.jpg
D:/xunleiDownload/DASNet-master/DASNET/dataset/ChangeDetectionDataset/Model/with_shift/train/A/00002.jpg
D:/xunleiDownload/DASNet-master/DASNET/dataset/ChangeDetectionDataset/Model/with_shift/train/B/00002.jpg
D:/xunleiDownload/DASNet-master/DASNET/dataset/ChangeDetectionDataset/Model/with_shift/train/OUT/00002.jpg
D:/xunleiDownload/DASNet-master/DASNET/dataset/ChangeDetectionDataset/Model/with_shift/train/A/00003.jpg
D:/xunleiDownload/DASNet-master/DASNET/dataset/ChangeDetectionDataset/Model/with_shift/train/B/00003.jpg
D:/xunleiDownload/DASNet-master/DASNET/dataset/ChangeDetectionDataset/Model/with_shift/train/OUT/00003.jpg
D:/xunleiDownload/DASNet-master/DASNET/dataset/ChangeDetectionDataset/Model/with_shift/train/A/00004.jpg
D:/xunleiDownload/DASNet-master/DASNET/dataset/ChangeDetectionDataset/Model/with_shift/train/B/00004.jpg
D:/xunleiDownload/DASNet-master/DASNET/dataset/ChangeDetectionDataset/Model/with_shift/train/OUT/00004.jpg
...
但是,这种情况下image_name似乎没法得到,是我生成的train.txt文件的格式有问题吗?
Traceback (most recent call last):
File "D:/xunleiDownload/DASNet-master/DASNET/train.py", line 225, in
首先请仔细阅读cfg/CDD.py。你需要自己生成TXT文件不必包含绝对路径,其A,B,OUT文件夹中的对应文件需要并列在同一行并以空格隔开,例如 A/01,jpg B/01.jpg OUT/01.jpg 另外需要注意pytorch版本。
I encountered the same problem, I do not know how to generate train.txt, can you explain it more specifically, thank you.
OK,give me your e-mail,and I will send u my train.txt file,then u can refer it.
dudubit@126.com Thank you so much.
dudubit@126.com Thank you so much.
Ok,I already sent ur e-mail.about val.txt,train.txt and grenratetxt.py. And your should change ur path.
raminram6970@gmail.com would you mind sent to me email about val.txt,train.txt and grenratetxt.py thanks
------------------ 原始邮件 ------------------ 发件人: "raminrahimi6970"<notifications@github.com>; 发送时间: 2020年5月13日(星期三) 下午5:03 收件人: "lehaifeng/DASNet"<DASNet@noreply.github.com>; 抄送: "185221369"<185221369@qq.com>;"Comment"<comment@noreply.github.com>; 主题: Re: [lehaifeng/DASNet] Do u have data about this code?Thank you! (#4)
raminram6970@gmail.com would you mind sent to me email about val.txt,train.txt and grenratetxt.py thanks
— You are receiving this because you commented. Reply to this email directly, view it on GitHub, or unsubscribe.
raminram6970@gmail.com would you mind sent to me email about val.txt,train.txt and grenratetxt.py thanks
Ok,I already sent ur e-mail.about val.txt,train.txt and grenratetxt.py. And your should change ur path.
thanks but i do not received file
On Wed, May 13, 2020 at 2:42 PM louxiantuo notifications@github.com wrote:
raminram6970@gmail.com would you mind sent to me email about val.txt,train.txt and grenratetxt.py thanks
Ok,I already sent ur e-mail.about val.txt,train.txt and grenratetxt.py. And your should change ur path.
— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/lehaifeng/DASNet/issues/4#issuecomment-627888248, or unsubscribe https://github.com/notifications/unsubscribe-auth/AHB4G6XBNAOMDCMJ5PPL4FLRRJXBRANCNFSM4MQAOV5Q .
HI, louxiantuo, thanks for your kindly help. I hope you enjoy it and have better research.
thanks but i do not received file … On Wed, May 13, 2020 at 2:42 PM louxiantuo @.> wrote: @. would you mind sent to me email about val.txt,train.txt and grenratetxt.py thanks Ok,I already sent ur e-mail.about val.txt,train.txt and grenratetxt.py. And your should change ur path. — You are receiving this because you commented. Reply to this email directly, view it on GitHub <#4 (comment)>, or unsubscribe https://github.com/notifications/unsubscribe-auth/AHB4G6XBNAOMDCMJ5PPL4FLRRJXBRANCNFSM4MQAOV5Q .
I send it again,please check it.
Could you release the train.txt, val.txt and grenratetxt.py on GitHub or Google Driver or others? I think many people want to refer it. Thank you!
OK,I will upload in my github,and I will send a link in here.
https://github.com/louxiantuo/DASnet-train.txt-val.txt- @TingquanGao
Hi Thanks a lot for your help I want to test some image with Pretrained model for CCD but have error like this: Missing key(s) in state_dict: "CNN.fc6_1.0.weight", "CNN.fc6_1.0.bias", "CNN.fc7_1.0.weight", "CNN.fc7_1.0.bias" perhaps some wight of this file " CDD_model_best.pth" that you are upload in google drive are miss. can you help me? thanks a lot
Hi Thanks a lot for your help I want to test some image with Pretrained model for CCD but have error like this: Missing key(s) in state_dict: "CNN.fc6_1.0.weight", "CNN.fc6_1.0.bias", "CNN.fc7_1.0.weight", "CNN.fc7_1.0.bias" perhaps some wight of this file " CDD_model_best.pth" that you are upload in google drive are miss. can you help me? thanks a lot
I think that in the test part, there is no need to reversely calculate the gradient, so the parameters of fc layers do not need to be saved in the model file.Thus when the model file is loaded, you could try to set strick = False
. My code is as follows:
model = models.SiameseNet(norm_flag='l2')
state_dict = torch.load('../pretrain/CDD_model_best.pth')['state_dict']
net = model.load_state_dict(state_dict, strict = False)
thanks a lot for your help after this I have to design my fc and then use model? or i can use: out_conv5, out_fc, out_embedding = net(img1, img2) for predict?
thanks a lot for your help after this I have to design my fc and then use model? or i can use: out_conv5, out_fc, out_embedding = net(img1, img2) for predict?
After this, you can use validate()
to predict, but you may need to modify validate()
.
yes sure I try your solution but have error when eval() the model it need fc layer. i think we have to had fc wight for validate and test. thanks for your answer are you test your solution?
yes sure I try your solution but have error when eval() the model it need fc layer. i think we have to had fc wight for validate and test. thanks for your answer are you test your solution?
Yes, base my solution, I have run the code successfully with the modified validate()
. But the results don’t seem to be excellent.
Do not excellent results because of missing the fully connected layer?
The reason for the unexcellent results seems to be the wrong version of my PyTorch.
I checked the network structure, and found that in the forward()
of Deeplab_V2
, "fc" layers are not seem to be used. So "fc" layers have no effect to the result.
if your result improve with change PyTorch version release version to use. thanks for your answer
Is your results improved with change version of pytorch?
No, the code does not seem to run successfully in my environment. I am still trying.
Actually,So am I.
发送自 Windows 10 版邮件https://go.microsoft.com/fwlink/?LinkId=550986应用
发件人: Tingquan Gao notifications@github.com 发送时间: Saturday, May 23, 2020 7:18:53 PM 收件人: lehaifeng/DASNet DASNet@noreply.github.com 抄送: louxiantuo louxiantuo@outlook.com; Author author@noreply.github.com 主题: Re: [lehaifeng/DASNet] Do u have data about this code?Thank you! (#4)
No, the code does not seem to run successfully in my environment. I am still trying.
― You are receiving this because you authored the thread. Reply to this email directly, view it on GitHubhttps://github.com/lehaifeng/DASNet/issues/4#issuecomment-633029917, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AETTUB4QC66X6VL2DEDWADDRS6WJ3ANCNFSM4MQAOV5Q.
Hi I run the code in PyTorch=1.3 and pretrained model that was upload but my result not seems very good what is the problem? thanks for your answer
Can you tell me how to run this code on Pycharm?
I have ChangeDetectionDataset ,but I don‘t have train.txt . I don't know how to write.