You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Traceback (most recent call last):
File "/home/nlp/.pycharm_helpers/pydev/pydevd.py", line 1496, in _exec
pydev_imports.execfile(file, globals, locals) # execute the script
File "/home/nlp/.pycharm_helpers/pydev/_pydev_imps/_pydev_execfile.py", line 18, in execfile
exec(compile(contents+"\n", file, 'exec'), glob, loc)
File "/home/nlp/code/AdaSeq/examples/MoRe/train.py", line 37, in
train_model_from_args(args)
File "/home/nlp/code/AdaSeq/adaseq/commands/train.py", line 93, in train_model_from_args
checkpoint_path=args.checkpoint_path,
File "/home/nlp/code/AdaSeq/adaseq/commands/train.py", line 164, in train_model
trainer.train(checkpoint_path)
File "/home/nlp/code/AdaSeq/adaseq/training/default_trainer.py", line 146, in train
return super().train(checkpoint_path=checkpoint_path, *args, **kwargs)
File "/home/nlp/anaconda3/envs/MoRe/lib/python3.7/site-packages/modelscope/trainers/trainer.py", line 676, in train
self.train_loop(self.train_dataloader)
File "/home/nlp/anaconda3/envs/MoRe/lib/python3.7/site-packages/modelscope/trainers/trainer.py", line 1171, in train_loop
self.train_step(self.model, data_batch, **kwargs)
File "/home/nlp/anaconda3/envs/MoRe/lib/python3.7/site-packages/modelscope/trainers/trainer.py", line 841, in train_step
train_outputs = model.forward(**inputs)
File "/home/nlp/code/AdaSeq/adaseq/models/sequence_labeling_model.py", line 129, in forward
loss = self._calculate_loss(logits, label_ids, crf_mask)
File "/home/nlp/code/AdaSeq/adaseq/models/sequence_labeling_model.py", line 176, in _calculate_loss
targets = targets * mask
RuntimeError: The size of tensor a (269) must match the size of tensor b (270) at non-singleton dimension 1
Traceback (most recent call last):
File "/home/nlp/.pycharm_helpers/pydev/pydevd.py", line 1496, in _exec
pydev_imports.execfile(file, globals, locals) # execute the script
File "/home/nlp/.pycharm_helpers/pydev/_pydev_imps/_pydev_execfile.py", line 18, in execfile
exec(compile(contents+"\n", file, 'exec'), glob, loc)
File "/home/nlp/code/AdaSeq/examples/MoRe/train.py", line 37, in
train_model_from_args(args)
File "/home/nlp/code/AdaSeq/adaseq/commands/train.py", line 93, in train_model_from_args
checkpoint_path=args.checkpoint_path,
File "/home/nlp/code/AdaSeq/adaseq/commands/train.py", line 164, in train_model
trainer.train(checkpoint_path)
File "/home/nlp/code/AdaSeq/adaseq/training/default_trainer.py", line 146, in train
return super().train(checkpoint_path=checkpoint_path, *args, **kwargs)
File "/home/nlp/anaconda3/envs/MoRe/lib/python3.7/site-packages/modelscope/trainers/trainer.py", line 676, in train
self.train_loop(self.train_dataloader)
File "/home/nlp/anaconda3/envs/MoRe/lib/python3.7/site-packages/modelscope/trainers/trainer.py", line 1171, in train_loop
self.train_step(self.model, data_batch, **kwargs)
File "/home/nlp/anaconda3/envs/MoRe/lib/python3.7/site-packages/modelscope/trainers/trainer.py", line 841, in train_step
train_outputs = model.forward(**inputs)
File "/home/nlp/code/AdaSeq/adaseq/models/sequence_labeling_model.py", line 129, in forward
loss = self._calculate_loss(logits, label_ids, crf_mask)
File "/home/nlp/code/AdaSeq/adaseq/models/sequence_labeling_model.py", line 176, in _calculate_loss
targets = targets * mask
RuntimeError: The size of tensor a (299) must match the size of tensor b (300) at non-singleton dimension 1
请问这个问题如何解决
What's your environment?
AdaSeq Version (e.g., 1.0 or master):
ModelScope Version (e.g., 1.0 or master):
PyTorch Version (e.g., 1.12.1):
OS (e.g., Ubuntu 20.04):
Python version:
CUDA/cuDNN version:
GPU models and configuration:
Any other relevant information:
Code of Conduct
I agree to follow this project's Code of Conduct
The text was updated successfully, but these errors were encountered:
What is your question?
运行twitter-17-txt.yaml和twitter-17-img.yaml出错
What have you tried?
No response
Code (if necessary)
Traceback (most recent call last):
File "/home/nlp/.pycharm_helpers/pydev/pydevd.py", line 1496, in _exec
pydev_imports.execfile(file, globals, locals) # execute the script
File "/home/nlp/.pycharm_helpers/pydev/_pydev_imps/_pydev_execfile.py", line 18, in execfile
exec(compile(contents+"\n", file, 'exec'), glob, loc)
File "/home/nlp/code/AdaSeq/examples/MoRe/train.py", line 37, in
train_model_from_args(args)
File "/home/nlp/code/AdaSeq/adaseq/commands/train.py", line 93, in train_model_from_args
checkpoint_path=args.checkpoint_path,
File "/home/nlp/code/AdaSeq/adaseq/commands/train.py", line 164, in train_model
trainer.train(checkpoint_path)
File "/home/nlp/code/AdaSeq/adaseq/training/default_trainer.py", line 146, in train
return super().train(checkpoint_path=checkpoint_path, *args, **kwargs)
File "/home/nlp/anaconda3/envs/MoRe/lib/python3.7/site-packages/modelscope/trainers/trainer.py", line 676, in train
self.train_loop(self.train_dataloader)
File "/home/nlp/anaconda3/envs/MoRe/lib/python3.7/site-packages/modelscope/trainers/trainer.py", line 1171, in train_loop
self.train_step(self.model, data_batch, **kwargs)
File "/home/nlp/anaconda3/envs/MoRe/lib/python3.7/site-packages/modelscope/trainers/trainer.py", line 841, in train_step
train_outputs = model.forward(**inputs)
File "/home/nlp/code/AdaSeq/adaseq/models/sequence_labeling_model.py", line 129, in forward
loss = self._calculate_loss(logits, label_ids, crf_mask)
File "/home/nlp/code/AdaSeq/adaseq/models/sequence_labeling_model.py", line 176, in _calculate_loss
targets = targets * mask
RuntimeError: The size of tensor a (269) must match the size of tensor b (270) at non-singleton dimension 1
Traceback (most recent call last):
File "/home/nlp/.pycharm_helpers/pydev/pydevd.py", line 1496, in _exec
pydev_imports.execfile(file, globals, locals) # execute the script
File "/home/nlp/.pycharm_helpers/pydev/_pydev_imps/_pydev_execfile.py", line 18, in execfile
exec(compile(contents+"\n", file, 'exec'), glob, loc)
File "/home/nlp/code/AdaSeq/examples/MoRe/train.py", line 37, in
train_model_from_args(args)
File "/home/nlp/code/AdaSeq/adaseq/commands/train.py", line 93, in train_model_from_args
checkpoint_path=args.checkpoint_path,
File "/home/nlp/code/AdaSeq/adaseq/commands/train.py", line 164, in train_model
trainer.train(checkpoint_path)
File "/home/nlp/code/AdaSeq/adaseq/training/default_trainer.py", line 146, in train
return super().train(checkpoint_path=checkpoint_path, *args, **kwargs)
File "/home/nlp/anaconda3/envs/MoRe/lib/python3.7/site-packages/modelscope/trainers/trainer.py", line 676, in train
self.train_loop(self.train_dataloader)
File "/home/nlp/anaconda3/envs/MoRe/lib/python3.7/site-packages/modelscope/trainers/trainer.py", line 1171, in train_loop
self.train_step(self.model, data_batch, **kwargs)
File "/home/nlp/anaconda3/envs/MoRe/lib/python3.7/site-packages/modelscope/trainers/trainer.py", line 841, in train_step
train_outputs = model.forward(**inputs)
File "/home/nlp/code/AdaSeq/adaseq/models/sequence_labeling_model.py", line 129, in forward
loss = self._calculate_loss(logits, label_ids, crf_mask)
File "/home/nlp/code/AdaSeq/adaseq/models/sequence_labeling_model.py", line 176, in _calculate_loss
targets = targets * mask
RuntimeError: The size of tensor a (299) must match the size of tensor b (300) at non-singleton dimension 1
请问这个问题如何解决
What's your environment?
Code of Conduct
The text was updated successfully, but these errors were encountered: