Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ---------------------------------------------------------------------------
- RuntimeError Traceback (most recent call last)
- Cell In[18], line 7
- 5 for data_seq in tqdm(data_loader_train, total=len(data_loader_train), desc="Training", leave=False):
- 6 buffer = torch.zeros(data_seq.shape[0], buffer_size, device=device)
- ----> 7 summary(gps_rnn, [(32,14,2), buffer])
- File D:\ProgramData\Miniconda_3.9\envs\rnn-sample-py3.9\lib\site-packages\torchsummary\torchsummary.py:136, in summary(model, input_data, batch_dim, branching, col_names, col_width, depth, device, dtypes, verbose, *args, **kwargs)
- 133 if device is None:
- 134 device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
- --> 136 x, input_size = process_input_data(input_data, batch_dim, device, dtypes)
- 137 args, kwargs = set_device(args, device), set_device(kwargs, device)
- 138 try:
- File D:\ProgramData\Miniconda_3.9\envs\rnn-sample-py3.9\lib\site-packages\torchsummary\torchsummary.py:215, in process_input_data(input_data, batch_dim, device, dtypes)
- 213 if dtypes is None:
- 214 dtypes = [torch.float] * len(input_data)
- --> 215 input_size = get_correct_input_sizes(input_data)
- 216 x = get_input_tensor(input_size, batch_dim, dtypes, device)
- 218 else:
- File D:\ProgramData\Miniconda_3.9\envs\rnn-sample-py3.9\lib\site-packages\torchsummary\torchsummary.py:261, in get_correct_input_sizes(input_size)
- 258 else:
- 259 yield item
- --> 261 if not input_size or any(size <= 0 for size in flatten(input_size)):
- 262 raise ValueError("Input_data is invalid, or negative size found in input_data.")
- 264 if isinstance(input_size, list) and isinstance(input_size[0], int):
- RuntimeError: Boolean value of Tensor with more than one value is ambiguous
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement