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

Add Scalar backend #306

Open
wants to merge 7 commits into
base: dev-master
Choose a base branch
from
Open

Add Scalar backend #306

wants to merge 7 commits into from

Conversation

jeffry1829
Copy link
Collaborator

@jeffry1829 jeffry1829 commented Oct 14, 2023

Not fully tested, at least compile passed.

It's important to review SProxy, since we're not using straightforward way to write into memory.
Instead, we first convert memory to at::Tensor, then use tn[loc] = elem;

@codecov
Copy link

codecov bot commented Oct 14, 2023

Codecov Report

Merging #306 (230a6b8) into dev-master (dd0fdbb) will increase coverage by 3.61%.
Report is 38 commits behind head on dev-master.
The diff coverage is n/a.

@@              Coverage Diff               @@
##           dev-master     #306      +/-   ##
==============================================
+ Coverage       13.75%   17.37%   +3.61%     
==============================================
  Files             282      274       -8     
  Lines           55158    57728    +2570     
  Branches        24712    26747    +2035     
==============================================
+ Hits             7588    10030    +2442     
+ Misses          41574    39143    -2431     
- Partials         5996     8555    +2559     

see 70 files with indirect coverage changes

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@kaihsin
Copy link
Member

kaihsin commented Oct 15, 2023

This need to be careful to not mess-up the gradient part.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is it possible to not using switch? I think torch must have their own function you can call?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since we're dealing with cytnx types. I think we cannot use pytorch.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants