Traceback (most recent call last):


 "test_models.py", line 128, in <module>

rst = eval_video((i, data, label))


 "test_models.py", line 116, in eval_video

rst = net(input_var).data.cpu().numpy().copy()


 "/home/mohamad/anaconda2/lib/python2.7/site-packages/torch/nn/modules/module.py", line 357, in __call__

result = self.forward(*input, **kwargs)


 "/home/mohamad/anaconda2/lib/python2.7/site-packages/torch/nn/parallel/data_parallel.py", line 69, in forward

inputs, kwargs = self.scatter(inputs, kwargs, self.device_ids)


 "/home/mohamad/anaconda2/lib/python2.7/site-packages/torch/nn/parallel/data_parallel.py", line 80, in scatter

return scatter_kwargs(inputs, kwargs, device_ids, dim=self.dim)


 "/home/mohamad/anaconda2/lib/python2.7/site-packages/torch/nn/parallel/scatter_gather.py", line 38, in scatter_kwargs

inputs = scatter(inputs, target_gpus, dim) if inputs else []


 "/home/mohamad/anaconda2/lib/python2.7/site-packages/torch/nn/parallel/scatter_gather.py", line 31, in scatter

return scatter_map(inputs)


 "/home/mohamad/anaconda2/lib/python2.7/site-packages/torch/nn/parallel/scatter_gather.py", line 18, in scatter_map

return list(zip(*map(scatter_map, obj)))


 "/home/mohamad/anaconda2/lib/python2.7/site-packages/torch/nn/parallel/scatter_gather.py", line 15, in scatter_map

return Scatter.apply(target_gpus, None, dim, obj)


 "/home/mohamad/anaconda2/lib/python2.7/site-packages/torch/nn/parallel/_functions.py", line 73, in forward

streams = [_get_stream(device) for device in ctx.target_gpus]


 "/home/mohamad/anaconda2/lib/python2.7/site-packages/torch/nn/parallel/_functions.py", line 100, in _get_stream

if _streams[device] is None:
IndexError: list index out of range`
Traceback (most recent call last):


 "<input>", line 1, in <module>


 "/home/pbc/.local/share/JetBrains/Toolbox/apps/PyCharm-P/ch-0/202.7660.27/plugins/python/helpers/pydev/_pydev_bundle/pydev_umd.py", line 197, in runfile

pydev_imports.execfile(filename, global_vars, local_vars)
# execute the script


 "/home/pbc/.local/share/JetBrains/Toolbox/apps/PyCharm-P/ch-0/202.7660.27/plugins/python/helpers/pydev/_pydev_imps/_pydev_execfile.py", line 18, in execfile

exec(compile(contents+"\n", file, 'exec'), glob, loc)


 "/home/pbc/Documents/PycharmProjects/bert/longformer_github.py", line 34, in <module>

output = model(input_ids, attention_mask=attention_mask)[0]


 "/home/pbc/anaconda3/envs/dnabert/lib/python3.6/site-packages/torch/nn/modules/module.py", line 722, in _call_impl

result = self.forward(*input, **kwargs)


 "/home/pbc/anaconda3/envs/dnabert/lib/python3.6/site-packages/transformers/modeling_bert.py", line 825, in forward

input_ids=input_ids, position_ids=position_ids, token_type_ids=token_type_ids, inputs_embeds=inputs_embeds


 "/home/pbc/anaconda3/envs/dnabert/lib/python3.6/site-packages/torch/nn/modules/module.py", line 722, in _call_impl

result = self.forward(*input, **kwargs)


 "/home/pbc/anaconda3/envs/dnabert/lib/python3.6/site-packages/transformers/modeling_roberta.py", line 82, in forward

input_ids, token_type_ids=token_type_ids, position_ids=position_ids, inputs_embeds=inputs_embeds


 "/home/pbc/anaconda3/envs/dnabert/lib/python3.6/site-packages/transformers/modeling_bert.py", line 208, in forward

position_embeddings = self.position_embeddings(position_ids)


 "/home/pbc/anaconda3/envs/dnabert/lib/python3.6/site-packages/torch/nn/modules/module.py", line 722, in _call_impl

result = self.forward(*input, **kwargs)


 "/home/pbc/anaconda3/envs/dnabert/lib/python3.6/site-packages/torch/nn/modules/sparse.py", line 126, in forward

self.norm_type, self.scale_grad_by_freq, self.sparse)


 "/home/pbc/anaconda3/envs/dnabert/lib/python3.6/site-packages/torch/nn/functional.py", line 1814, in embedding

return torch.embedding(weight, input, padding_idx, scale_grad_by_freq, sparse)
IndexError: index out of range in self
