Skip to content

Commit

Permalink
RF containers, better exc msg
Browse files Browse the repository at this point in the history
  • Loading branch information
albertz committed Nov 9, 2023
1 parent 40c7aa4 commit e5a5d90
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion returnn/frontend/container.py
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ def _convert_to_module(obj: _ModT) -> rf.Module:
elif callable(obj):
return rf.Functional(obj)
else:
raise TypeError(f"did not expect {obj!r}")
raise TypeError(f"Expected rf.Module or callable, did not expect {obj!r} ({type(obj)})")


def _is_iterable(obj) -> bool:
Expand Down

0 comments on commit e5a5d90

Please sign in to comment.