Junshk / CinCGAN-pytorch

Unofficial Implementation of "Unsupervised Image Super-Resolution using Cycle-in-Cycle Generative Adversarial Networks" in CVPR 2018.
142 stars 27 forks source link

ReadMe file for training and testing #2

Open MFarooqAit opened 5 years ago

MFarooqAit commented 5 years ago

Could you provide the instructions to use your code for training and testing. Thank you.

Junshk commented 5 years ago

I briefly wrote down the instructions in the readme file. If you can't understand, please leave a comment.

MFarooqAit commented 5 years ago

@Junshk , Thank you! Currently i am following your instructions to run the code. If i face any difficulty, then i will ask you again. Again Thank you.

MFarooqAit commented 5 years ago

I have faced the following error: (pytorch-py2) I:\Models\CinCGAN-pytorch\code>python main.py --dir_data 'dataset' Traceback (most recent call last): File "main.py", line 10, in import data File "I:\Models\CinCGAN-pytorch\code\data__init__.py", line 3, in from dataloader import MSDataLoader File "I:\Models\CinCGAN-pytorch\code\dataloader.py", line 17, in from torch.utils.data.dataloader import _worker_manager_loop ImportError: cannot import name '_worker_manager_loop' from 'torch.utils.data.dataloader' (C:\Users\1234\Anaconda2\envs\pytorch-py2\lib\site-packages\torch\utils\data\dataloader.py)

I found the solutions to this problem at the following link: https://github.com/thstkdgus35/EDSR-PyTorch/issues/98

I try to apply some of them but unable to fix this problem. Can you help in this matter??

Junshk commented 5 years ago

What is your pytorch version? If you use 1.0.0, change the dataloader.py to 1.0.0 version from thstkdgus35 repository. My code is based on his 0.4.1 version code. And maybe you should change some part of my code. For example, loss.data[0] in main.py.

MFarooqAit commented 5 years ago

@Junshk , Thank you! I am using pytorch version1.0.0. okay, i am trying to following your instructions to fix this problem.

MFarooqAit commented 5 years ago

Dear @Junshk, I am using “EDSR_x4.pt” model during training as “EDSR_baseline_x4.pt” is not available at mentioned link. Therefore, I am facing dimension mismatching error as shown below. So kindly provide EDSR_baseline_x4.pt

I also visited EDSR Torch implementation(https://github.com/LimBee/NTIRE2017), but base model is provided with .t7 format, like EDSR_baseline_x4.t7. But to run your code we need .pt format.

So kindly help in this matter. Thank you.

RuntimeError: The expanded size of the tensor (64) must match the existing size (256) at non-singleton dimension During handling of the above exception, another exception occurred: Traceback (most recent call last): File "main.py", line 361, in main() File "main.py", line 84, in main GHR.load_state_dict(Loaded) File "I:\Models\CinCGAN-pytorch\code\model\edsr.py", line 71, in load_state_dict .format(name, own_state[name].size(), param.size())) RuntimeError: While copying the parameter named head.0.weight, whose dimensions in the model are torch.Size([64, 3, 3, 3]) and whose dimensions in the checkpoint are torch.Size([256, 3, 3, 3]).

Auth0rM0rgan commented 5 years ago

Hey @MFarooqAit,

Check out this link https://github.com/thstkdgus35/EDSR-PyTorch/issues/136

MFarooqAit commented 5 years ago

Hi@Auth0rM0rgan, corresponding to your provided link "No results matched your search" message is displayed. Kindly help!

Auth0rM0rgan commented 5 years ago

Hey @MFarooqAit,

I have updated the link. check it now. Also, you can use the pre-trained model which @Junshk uploaded in the repository. you need to change some parameters in option.py (n_resblocks = 32, n_feats=256 )

MFarooqAit commented 5 years ago

Hey@Auth0rM0rgan,

Thank you so much for your help.

MFarooqAit commented 5 years ago

Dear @Auth0rM0rgan , Training is done in two steps. Step1 : Training of denoising network, i.e, G1,D1, G2 networks (according to the CinC GAN paper) Step2 : Joint training (fine tuning ) of denoising and SR networks

The ouput " Epoch 20: Loss: idt 0.000000 2.370729 cyc 0.000000 1.735660 D 0.000000 0.973776, G: 0.000000 0.870190, psnr_hr: 5.089412, psnr_lr 5.857366" is for Step1. During Step1 idt, cyc, D, and G losses for SR network are zeros.

On Mon, Apr 1, 2019 at 6:19 PM Author Morgan notifications@github.com wrote:

Hey @MFarooqAit https://github.com/MFarooqAit, Your welcome. Did you train the model? When I am training the model some loss functions stay 0.00 and not changing at all. Is it same for you?

Epoch 20: Loss: idt 0.000000 2.370729 cyc 0.000000 1.735660 D 0.000000 0.973776, G: 0.000000 0.870190, psnr_hr: 5.089412, psnr_lr 5.857366

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/Junshk/CinCGAN-pytorch/issues/2#issuecomment-478539063, or mute the thread https://github.com/notifications/unsubscribe-auth/Abh-yaw131qesqyrErvhnUKi3ZmOYsPLks5vcetFgaJpZM4b48Bw .

Auth0rM0rgan commented 5 years ago

Hi @MFarooqAit,

Thanks for the explanation. I'm training the network for 400 epochs. Now, it's in epoch 145 and the losses for step 2 are still 0.000. When step2 is going to joint the training?

MFarooqAit commented 5 years ago

Dear @Auth0rM0rgan , When step1 training is finished (400 epoch), we have to explicitly start joint training (step2) of denoising and SR networks.

Author Morgan

On Tue, Apr 2, 2019 at 4:07 PM Author Morgan notifications@github.com wrote:

Hi @MFarooqAit https://github.com/MFarooqAit,

Thanks for the explanation, I trained the network for 145 epochs out of 400 and the losses for step 2 are still 0.000. When step2 is going to joint the training?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/Junshk/CinCGAN-pytorch/issues/2#issuecomment-478910227, or mute the thread https://github.com/notifications/unsubscribe-auth/Abh-yZgscAMv7tjRUpbT4yKVy8qBJRPTks5vcx3agaJpZM4b48Bw .

--


Regards, Muhammad Farooq

Auth0rM0rgan commented 5 years ago

@MFarooqAit,

Could you please explain more clearly? What exactly I have to do after step 1 training complete?

Don't think just need to change the joint variable to True to have a joint training of all generators together? (in the main.py, line 134)

MFarooqAit commented 5 years ago

Dear @Auth0rM0rgan , Currently I am doing the training of step1, so do not know exactly.

On Wed, Apr 3, 2019 at 5:18 AM Author Morgan notifications@github.com wrote:

@MFarooqAit https://github.com/MFarooqAit,

Could you please explain more clearly? What do I have to do exactly after step 1 training complete?

Don't think just need to change the joint variable f to True to have a joint training of all generators together?(in the main.py, line 134)

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/Junshk/CinCGAN-pytorch/issues/2#issuecomment-479229962, or mute the thread https://github.com/notifications/unsubscribe-auth/Abh-yf1moALpBMp5PK2fYzFglXyJXW2Pks5vc9cogaJpZM4b48Bw .

--


Regards, Muhammad Farooq

MFarooqAit commented 5 years ago

Dear @Auth0rM0rgan , No need to change anything in code. When training of step1(400epoch) is finished, then we start training again, it will be training of step2 (joint training of Denoising + EDSR network).

On Wed, Apr 3, 2019 at 8:44 AM Muhammad Farooq st118370@ait.asia wrote:

Dear Author Morgan, Currently I am doing the training of step1, so do not know exactly.

But i think we should make the following changes: 1) main.py, line# 26 opt.start_epoch = 400 2) option.py, line#85 parser.add_argument('--resume', type=int, default =1, help='load the model from the specified epoch')

On Wed, Apr 3, 2019 at 5:18 AM Author Morgan notifications@github.com wrote:

@MFarooqAit https://github.com/MFarooqAit,

Could you please explain more clearly? What do I have to do exactly after step 1 training complete?

Don't think just need to change the joint variable f to True to have a joint training of all generators together?(in the main.py, line 134)

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/Junshk/CinCGAN-pytorch/issues/2#issuecomment-479229962, or mute the thread https://github.com/notifications/unsubscribe-auth/Abh-yf1moALpBMp5PK2fYzFglXyJXW2Pks5vc9cogaJpZM4b48Bw .

--


Regards, Muhammad Farooq

--


Regards, Muhammad Farooq

huaixu16 commented 4 years ago

Could you provide the instructions to use your code for training and testing. Thank you.

could you provide your instructions?whats your torch version and python version?It seems like you run this code successfully.Thank you!

MFarooqAit commented 4 years ago

Dear huaixushiliu https://github.com/huaixushiliu,

I have used the same instruction to run the code as provided by the author to run the program for training.

python main.py --dir_data 'data_path'

My torch version is 0.4.1 with python of version 3.6.8.

On Sat, Oct 26, 2019 at 7:30 PM huaixushiliu notifications@github.com wrote:

Could you provide the instructions to use your code for training and testing. Thank you.

could you provide your instructions?whats your torch version and python version?It seems like you run this code successfully.Thank you!

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/Junshk/CinCGAN-pytorch/issues/2?email_source=notifications&email_token=AG4H5SITLIMNI2EGMDTIXZ3QQQZ5XA5CNFSM4G7DYBYKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOECKG5EY#issuecomment-546598547, or unsubscribe https://github.com/notifications/unsubscribe-auth/AG4H5SNR4S2NV6NUN4S635TQQQZ5XANCNFSM4G7DYBYA .

--


Regards, Muhammad Farooq

Ethean commented 4 years ago

Could you provide the instructions to use your code for training and testing. Thank you.

hi, I was encountered with this error, **

  1. FileNotFoundError: [Errno 2] No such file or directory: 'dataset/DIV2K/DIV2K_train_LR_mild/0331x4m.png'

** So I am confused that we should prepare the train data in the path '--dir_data' in advance? that means the code doesnot prepare the data? Thank u !!!!!

MFarooqAit commented 4 years ago

Dear Ethean, I think your instruction to run the code could be : python main.py --dir_data 'dataset'

On Mon, Oct 28, 2019 at 7:51 PM Ethean notifications@github.com wrote:

Could you provide the instructions to use your code for training and testing. Thank you.

hi, I was encountered with this error, **

  1. FileNotFoundError: [Errno 2] No such file or directory: 'dataset/DIV2K/DIV2K_train_LR_mild/0331x4m.png'

** So I am confused that we should prepare the train data in the path '--dir_data' in advance? that means the code doesnot prepare the data? Thank u !!!!!

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/Junshk/CinCGAN-pytorch/issues/2?email_source=notifications&email_token=AG4H5SNZTGKBQYJPL7TT5ATQQ3N5LA5CNFSM4G7DYBYKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOECMYGTY#issuecomment-546931535, or unsubscribe https://github.com/notifications/unsubscribe-auth/AG4H5SPMSDTKHTVY4BTXRNLQQ3N5LANCNFSM4G7DYBYA .

--


Regards, Muhammad Farooq

Ethean commented 4 years ago

Dear Ethean, I think your instruction to run the code could be : python main.py --dir_data 'dataset'

thanks for replay! i ran this code in pycharm and i did change the parameter '--dir_data', but still i got this.again thank u!

MFarooqAit commented 4 years ago

Have you follows the correct format of dataset. I means images in DIV2K/DIV2K_train_LR_mild/ folder should have the naming format like; 0331x4m.png ???

On Tue, Oct 29, 2019 at 9:42 AM Ethean notifications@github.com wrote:

Dear Ethean, I think your instruction to run the code could be : python main.py --dirdata 'dataset' … <#m-2568193457645604824_>

thanks for replay! i ran this code in pycharm and i did change the parameter '--dir_data', but still i got this.again thank u!

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/Junshk/CinCGAN-pytorch/issues/2?email_source=notifications&email_token=AG4H5SMZAVRB3I6V67HPV2DQQ6PJVA5CNFSM4G7DYBYKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOECPBLPQ#issuecomment-547231166, or unsubscribe https://github.com/notifications/unsubscribe-auth/AG4H5SPEKY6PQAN37TLRXMDQQ6PJVANCNFSM4G7DYBYA .

--


Regards, Muhammad Farooq

Ethean commented 4 years ago

Have you follows the correct format of dataset. I means images in DIV2K/DIV2K_train_LR_mild/ folder should have the naming format like; 0331x4m.png ??? On Tue, Oct 29, 2019 at 9:42 AM Ethean @.***> wrote: Dear Ethean, I think your instruction to run the code could be : python main.py --dirdata 'dataset' … <#m-2568193457645604824_> thanks for replay! i ran this code in pycharm and i did change the parameter '--dir_data', but still i got this.again thank u! — You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub <#2?email_source=notifications&email_token=AG4H5SMZAVRB3I6V67HPV2DQQ6PJVA5CNFSM4G7DYBYKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOECPBLPQ#issuecomment-547231166>, or unsubscribe https://github.com/notifications/unsubscribe-auth/AG4H5SPEKY6PQAN37TLRXMDQQ6PJVANCNFSM4G7DYBYA .

-------- Regards, Muhammad Farooq

Thanks for your help! I change the file name format and it worked! But I found it didnot follow the training details in the paper(the number boundary of the image used to train was confusing), so I am trying to implement it by myself.

MFarooqAit commented 4 years ago

Dear Ethean, Yes i prepared my dataset with specified format.

On Wed, Oct 30, 2019 at 12:49 PM Ethean notifications@github.com wrote:

Have you follows the correct format of dataset. I means images in DIV2K/DIV2K_train_LR_mild/ folder should have the naming format like; 0331x4m.png ??? … <#m8400630024656858216> On Tue, Oct 29, 2019 at 9:42 AM Ethean @.***> wrote: Dear Ethean, I think your instruction to run the code could be : python main.py --dirdata 'dataset' … <#m-2568193457645604824_> thanks for replay! i ran this code in pycharm and i did change the parameter '--dir_data', but still i got this.again thank u! — You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub <#2 https://github.com/Junshk/CinCGAN-pytorch/issues/2?email_source=notifications&email_token=AG4H5SMZAVRB3I6V67HPV2DQQ6PJVA5CNFSM4G7DYBYKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOECPBLPQ#issuecomment-547231166>, or unsubscribe https://github.com/notifications/unsubscribe-auth/AG4H5SPEKY6PQAN37TLRXMDQQ6PJVANCNFSM4G7DYBYA .

-------- Regards, Muhammad Farooq

Thanks for your help! I change the file name format and it worked! But I found it didnot follow the training details in the paper(the number boundary of the image used to train was confusing), so I am trying to implement it by myself.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/Junshk/CinCGAN-pytorch/issues/2?email_source=notifications&email_token=AG4H5SN3FIDJ7JU6MDT3XM3QREN7VA5CNFSM4G7DYBYKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOECS7S6Y#issuecomment-547748219, or unsubscribe https://github.com/notifications/unsubscribe-auth/AG4H5SIS6MGBLX2LYPXIW7TQREN7VANCNFSM4G7DYBYA .

--


Regards, Muhammad Farooq

Ethean commented 4 years ago

Dear Ethean, Yes i prepared my dataset with specified format. On Wed, Oct 30, 2019 at 12:49 PM Ethean @.> wrote: Have you follows the correct format of dataset. I means images in DIV2K/DIV2K_train_LR_mild/ folder should have the naming format like; 0331x4m.png ??? … <#m8400630024656858216> On Tue, Oct 29, 2019 at 9:42 AM Ethean @.> wrote: Dear Ethean, I think your instruction to run the code could be : python main.py --dirdata 'dataset' … <#m-2568193457645604824_> thanks for replay! i ran this code in pycharm and i did change the parameter '--dir_data', but still i got this.again thank u! — You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub <#2 <#2>?email_source=notifications&email_token=AG4H5SMZAVRB3I6V67HPV2DQQ6PJVA5CNFSM4G7DYBYKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOECPBLPQ#issuecomment-547231166>, or unsubscribe https://github.com/notifications/unsubscribe-auth/AG4H5SPEKY6PQAN37TLRXMDQQ6PJVANCNFSM4G7DYBYA . -------- Regards, Muhammad Farooq Thanks for your help! I change the file name format and it worked! But I found it didnot follow the training details in the paper(the number boundary of the image used to train was confusing), so I am trying to implement it by myself. — You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub <#2?email_source=notifications&email_token=AG4H5SN3FIDJ7JU6MDT3XM3QREN7VA5CNFSM4G7DYBYKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOECS7S6Y#issuecomment-547748219>, or unsubscribe https://github.com/notifications/unsubscribe-auth/AG4H5SIS6MGBLX2LYPXIW7TQREN7VANCNFSM4G7DYBYA .

-------- Regards, Muhammad Farooq Dear MFarooqAit, Hi, could you please tell me that the psnr of the results in step one ? I got a very low psnr(18.5±0.3) and ssim(0.46±0.2). yours ethean

MFarooqAit commented 4 years ago

Deat ethean, Currently not remember, but yes it was low.... Have you used the denoising network in LR-> clean LR network of CinCGAN? as in the implementation of CinCGAN author did not used it?

best, Farooq

On Thu, Nov 7, 2019 at 4:10 PM Ethean notifications@github.com wrote:

Dear Ethean, Yes i prepared my dataset with specified format. … <#m-4463626168570523731> On Wed, Oct 30, 2019 at 12:49 PM Ethean @.> wrote: Have you follows the correct format of dataset. I means images in DIV2K/DIV2K_train_LR_mild/ folder should have the naming format like; 0331x4m.png ??? … <#m8400630024656858216> On Tue, Oct 29, 2019 at 9:42 AM Ethean @.> wrote: Dear Ethean, I think your instruction to run the code could be : python main.py --dirdata 'dataset' … <#m-2568193457645604824_> thanks for replay! i ran this code in pycharm and i did change the parameter '--dir_data', but still i got this.again thank u! — You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub <#2 https://github.com/Junshk/CinCGAN-pytorch/issues/2 <#2 https://github.com/Junshk/CinCGAN-pytorch/issues/2>?email_source=notifications&email_token=AG4H5SMZAVRB3I6V67HPV2DQQ6PJVA5CNFSM4G7DYBYKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOECPBLPQ#issuecomment-547231166>, or unsubscribe https://github.com/notifications/unsubscribe-auth/AG4H5SPEKY6PQAN37TLRXMDQQ6PJVANCNFSM4G7DYBYA . -------- Regards, Muhammad Farooq Thanks for your help! I change the file name format and it worked! But I found it didnot follow the training details in the paper(the number boundary of the image used to train was confusing), so I am trying to implement it by myself. — You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub <#2 https://github.com/Junshk/CinCGAN-pytorch/issues/2?email_source=notifications&email_token=AG4H5SN3FIDJ7JU6MDT3XM3QREN7VA5CNFSM4G7DYBYKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOECS7S6Y#issuecomment-547748219>, or unsubscribe https://github.com/notifications/unsubscribe-auth/AG4H5SIS6MGBLX2LYPXIW7TQREN7VANCNFSM4G7DYBYA .

-------- Regards, Muhammad Farooq Dear MFarooqAit, Hi, could you please tell me that the psnr of the results in step one ? I got a very low psnr(18.5±0.3) and ssim(0.46±0.2). yours ethean

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/Junshk/CinCGAN-pytorch/issues/2?email_source=notifications&email_token=AG4H5SJR3MJYZ7VSEQTFXU3QSPLO5A5CNFSM4G7DYBYKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEDLXAZI#issuecomment-550989925, or unsubscribe https://github.com/notifications/unsubscribe-auth/AG4H5SOTNKQEZ2SU56UUMSDQSPLO5ANCNFSM4G7DYBYA .

--


Regards, Muhammad Farooq

Ethean commented 4 years ago

@MFarooqAit I have finished the training process of step one, and I got a pretty low psnr and ssim as claimed above. Despite that psnr is very low, I get visually pleased results. Now I am trying to implement the step two. epoch_16000_index_8

Tianhao318 commented 4 years ago

Dear @Junshk, I have finished the training step1 and step2 with scale=4,but I train with scale=2,RuntimeError :The size of tensor a(32) must match the size of tensor b(64) at non-singleton dimension 3 .And I train with scale=3,RuntimeError:The size of tensor a(126) must match the size of tensor b(128) at non-singleton dimension 3.How can I train the model of scale=2 and scale=3.Thank you!


Namespace(act='relu', batch_size=16, beta1=0.9, beta2=0.999, chop_forward=False, cpu=False, data_test='DIV2K', data_train='DIV2K', debug=False, decay_type='step', dir_data='./dataset', epochs=400, epsilon=1e-08, ext='img', extend='.', gamma=0.5, gpus=0, load='.', loss='1L1', lr=0.0002, lr_decay=40, model='EDSR', momentum=0.9, n_GPUs=0, n_colors=3, n_feats=64, n_resblocks=16, n_threads=3, n_train=400, n_val=10, noise='.', offset_train=0, offset_val=800, optimizer='ADAM', patch_size=128, pre_train='.', print_every=100, print_model=False, quality=[''], res_scale=1, reset=False, resume=-1, rgb_range=255, save='test', save_models=False, save_results=False, scale=[3], seed=1, self_ensemble=False, shift_mean=True, start_epoch=0, template='.', test_every=1000, test_only=False, testpath='../LR/LRBI/', testset='B100') /home/anaconda3/envs/pytorch/lib/python3.6/site-packages/torch/nn/_reduction.py:49: UserWarning: size_average and reduce args will be deprecated, please use reduction='sum' instead. warnings.warn(warning.format(ret)) => use gpu id: '0' Random Seed: 3846 ===> Loading datasets ===> Building model ===> Setting GPU => no checkpoint found at 'model_total_3.pth' ===> Training Step 1. Epoch = 0, lr = 0.0002 Traceback (most recent call last): File "main.py", line 362, in main() File "main.py", line 137, in main train(training_data_loader, training_highloader, model, optimizer, epoch, False) File "main.py", line 278, in train criterion(bi_, target) step_weight File "/home/anaconda3/envs/pytorch/lib/python3.6/site-packages/torch/nn/modules/module.py", line 489, in call result = self.forward(*input, **kwargs) File "/home/anaconda3/envs/pytorch/lib/python3.6/site-packages/torch/nn/modules/loss.py", line 435, in forward return F.mse_loss(input, target, reduction=self.reduction) File "/home/anaconda3/envs/pytorch/lib/python3.6/site-packages/torch/nn/functional.py", line 2155, in mse_loss expanded_input, expanded_target = torch.broadcast_tensors(input, target) File "/home/anaconda3/envs/pytorch/lib/python3.6/site-packages/torch/functional.py", line 50, in broadcast_tensors return torch._C._VariableFunctions.broadcast_tensors(tensors) RuntimeError: The size of tensor a (126) must match the size of tensor b (128) at non-singleton dimension 3

hyjjj1015 commented 2 years ago

hello '_MSDataLoaderIter' object has no attribute 'index_queue' how can I solve this problem