NWChemEx / TensorWrapper

A type-erased wrapper around various tensor backends
https://nwchemex.github.io/TensorWrapper/
Apache License 2.0
0 stars 0 forks source link

Tensor Class "Works" #180

Closed ryanmrichard closed 2 months ago

ryanmrichard commented 2 months ago

Is this pull request associated with an issue(s)? No.

Description This PR gets a "working" Tensor class in place. The quotes are because at this point the Tensor class is basically a sophisticated mechanism for type-erasure. The only real feature that is implemented is the fact that users can create an Eigen tensor, wrap it in a buffer, and wrap that buffer in a Tensor (the reverse process is also possible, though it currently requires downcasting the buffer).

This PR has gotten quite large (most of the machinery is just to process inputs in what is hopefully a scalable way) and I wanted to merge this PR before adding more features (like reversing the type-erasure process and enabling tensor initialization through TensorWrapper directly).

TODOs None. R2g.