Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update mul(self, other): in _tt_base.py to allow multiplication with complex scalars and fix multiplication with torch.Tensor scalars #23

Merged
merged 1 commit into from
Jul 9, 2024

Commits on Jul 5, 2024

  1. Update _tt_base.py

    Changes to
    def __mul__(self, other):
    
    for multiplication with scalar:
    
    - torch.tensor changed to torch.Tensor which is correct as a type. ( isinstance does not work with torch.tensor but does with torch.Tensor)
    
    - added complex scalars as a valid option
    
    - adjusted description and error message accordingly
    ausstein authored Jul 5, 2024
    Configuration menu
    Copy the full SHA
    3f7fa20 View commit details
    Browse the repository at this point in the history