Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion torchrl/_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -410,7 +410,9 @@ def accept_remote_rref_udf_invocation(decorated_class):
"""Class decorator that applies `accept_remote_rref_invocation` to all public methods."""
# ignores private methods
for name in dir(decorated_class):
method = getattr(decorated_class, name)
method = getattr(decorated_class, name, None)
if method is None:
continue
if callable(method) and not name.startswith("_"):
setattr(decorated_class, name, accept_remote_rref_invocation(method))
return decorated_class
Expand Down
Loading