tomtang110 / Multitask

The project including MMOE, SNR_trans, SNR_avg, PLE, etc implemented by pytorch.
127 stars 21 forks source link

PLE训练效果 #4

Open zoe218 opened 3 years ago

zoe218 commented 3 years ago

hello,Tom 很棒的工作! 请问PLE训练的效果和论文里的一致么?我训练时差的挺多(loss没有用论文里的loss)

wuzuowuyou commented 2 years ago

ple 直接训练报错咋解决的啊
model = x.Model(config).to(config.device) 执行这句话的时候好慢啊 需要等5min?

Epoch [1/100] /media/algo/data_1/project_others/202205-MTL/github/Multitask-master/train_eval_snr.py:49: UserWarning: Using a target size (torch.Size([2048])) that is different to the input size (torch.Size([1])) is deprecated. Please ensure they have the same size. loss1 = config.loss_fn(outputs1,label1,reduction='mean') Traceback (most recent call last): File "run.py", line 34, in train(config,model,train_iter,dev_iter,test_iter) File "/media/algo/data_1/project_others/202205-MTL/github/Multitask-master/train_eval_snr.py", line 49, in train loss1 = config.loss_fn(outputs1,label1,reduction='mean') File "/media/algo/data_1/software/anconda_install/envs/amba_sparsification/lib/python3.7/site-packages/torch/nn/functional.py", line 2058, in binary_cross_entropy "!= input nelement ({})".format(target.numel(), input.numel())) ValueError: Target and input must have the same number of elements. target nelement (2048) != input nelement (1)