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
When this is a required arg, it breaks torch.save() and torch.load(). But more importantly, it also breaks code that does copy.deepcopy(model).
One option is to make it an optional keyword arg which defaults to None. When torch.load() de-serializes an object, it will first call __new__ to create a class, then create an instance and populate this with data, such that in this case params=None is justified.
The text was updated successfully, but these errors were encountered:
When this is a required arg, it breaks
torch.save()
andtorch.load()
. But more importantly, it also breaks code that doescopy.deepcopy(model)
.One option is to make it an optional keyword arg which defaults to
None
. Whentorch.load()
de-serializes an object, it will first call__new__
to create a class, then create an instance and populate this with data, such that in this caseparams=None
is justified.The text was updated successfully, but these errors were encountered: