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
Right now, the convert_inputs_to_tensors decorator is doing far too much: not only does it convert inputs to tensors and cast them, it can also convert them to shape tensors. The first part of its functionality should be restricted to operator overloads only - we don't want other APIs to do any implicit casting or conversion. The second part can be applied more broadly to make it easy to write ergonomic code.
To achieve this we can split the decorator so that the functionality that converts arguments to shape tensors is provided as a separate decorator.
We will probably also need to update _make_stack_info_message in tripy/tripy/common/exception.py to omit this decorator from the stack information when generating error messages.
The text was updated successfully, but these errors were encountered:
Right now, the
convert_inputs_to_tensors
decorator is doing far too much: not only does it convert inputs to tensors and cast them, it can also convert them to shape tensors. The first part of its functionality should be restricted to operator overloads only - we don't want other APIs to do any implicit casting or conversion. The second part can be applied more broadly to make it easy to write ergonomic code.To achieve this we can split the decorator so that the functionality that converts arguments to shape tensors is provided as a separate decorator.
We will probably also need to update
_make_stack_info_message
intripy/tripy/common/exception.py
to omit this decorator from the stack information when generating error messages.The text was updated successfully, but these errors were encountered: