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
Hello
I am trying to reproduce the code for power scheduling. But I don't have access to GPU , so I am running codes on a windows system with CPU.In your code,I have removed cuda() wherever it was written.But I am getting errors which I am not able to resolve.Your support in solving issues will be highly appreciated.
I have attached modified main.py and nets.py files.
For power scheduling,I am getting error in main file as model_rmse = nets.run_rmse_net(model_rmse, variables_rmse, X_train, Y_train)
c:\users\appdata\local\programs\python\python37\lib\site-packages\torch\nn\modules\module.py in _call_impl(self, *input, **kwargs)
720 result = self._slow_forward(*input, **kwargs)
721 else:
--> 722 result = self.forward(*input, **kwargs)
723 for hook in itertools.chain(
724 _global_forward_hooks.values(),
c:\users\appdata\local\programs\python\python37\lib\site-packages\torch\nn\functional.py in mse_loss(input, target, size_average, reduce, reduction)
2633 mse_loss, tens_ops, input, target, size_average=size_average, reduce=reduce,
2634 reduction=reduction)
-> 2635 if not (target.size() == input.size()):
2636 warnings.warn("Using a target size ({}) that is different to the input size ({}). "
2637 "This will likely lead to incorrect results due to broadcasting. "
AttributeError: 'tuple' object has no attribute 'size'
`
The text was updated successfully, but these errors were encountered:
Hello
I am trying to reproduce the code for power scheduling. But I don't have access to GPU , so I am running codes on a windows system with CPU.In your code,I have removed cuda() wherever it was written.But I am getting errors which I am not able to resolve.Your support in solving issues will be highly appreciated.
I have attached modified main.py and nets.py files.
For power scheduling,I am getting error in main file as
model_rmse = nets.run_rmse_net(model_rmse, variables_rmse, X_train, Y_train)
files.zip
`AttributeError Traceback (most recent call last)
in
----> 1 model_rmse = nets.run_rmse_net(model_rmse, variables_rmse, X_train, Y_train)
~\Untitled Folder 1\nets.py in run_rmse_net(model, variables, X_train, Y_train)
42 model.train()
43 train_loss = nn.MSELoss()(
---> 44 model(variables['X_train_']), variables['Y_train_'])
45 train_loss.backward()
46 opt.step()
c:\users\appdata\local\programs\python\python37\lib\site-packages\torch\nn\modules\module.py in _call_impl(self, *input, **kwargs)
720 result = self._slow_forward(*input, **kwargs)
721 else:
--> 722 result = self.forward(*input, **kwargs)
723 for hook in itertools.chain(
724 _global_forward_hooks.values(),
c:\users\appdata\local\programs\python\python37\lib\site-packages\torch\nn\modules\loss.py in forward(self, input, target)
443
444 def forward(self, input: Tensor, target: Tensor) -> Tensor:
--> 445 return F.mse_loss(input, target, reduction=self.reduction)
446
447
c:\users\appdata\local\programs\python\python37\lib\site-packages\torch\nn\functional.py in mse_loss(input, target, size_average, reduce, reduction)
2633 mse_loss, tens_ops, input, target, size_average=size_average, reduce=reduce,
2634 reduction=reduction)
-> 2635 if not (target.size() == input.size()):
2636 warnings.warn("Using a target size ({}) that is different to the input size ({}). "
2637 "This will likely lead to incorrect results due to broadcasting. "
AttributeError: 'tuple' object has no attribute 'size'
`
The text was updated successfully, but these errors were encountered: