Comments (13)
I think what I'll likely do now is split up tensornetwork.py
into node.py
, edge.py
and network.py
.
from tensornetwork.
@Thenerdstation are you working on this or is it up for grab?
from tensornetwork.
We need to move some code from internal first before we break it up. That should be done soon so afterwards go for it.
from tensornetwork.
Okay. Will wait for your go on this one.
from tensornetwork.
Once #22 is in you should be good to go.
from tensornetwork.
Ok go for it.
Be sure that Node
, Edge
and TensorNetwork
classes are publicly accessible from import tensornetwork
from tensornetwork.
Hey, thanks for working on this @kshithijiyer. I noticed you still have a tensornetwork.py
. Can we make it network.py
?
from tensornetwork.
Splitting the files is hitting a circular import error. Hence what I feel is that splitting the file into 3 files won't be possible but a split into 2 files would be possible.
from tensornetwork.
Yeah I think you are correct. Basically, what happened is it would start to parse node.py
and then hit from tensornetwork import edge
, continue to parse edge.py
until it hit node.Node
type declaration and raise an undefined error. This only happens because we use pytype.
Dang that sucks.
from tensornetwork.
I think we can get around it by using strings for the typing instead of using the module directly.
from tensornetwork.
I am not sure if that is a proper solution to this. This is what is happening when we split it into 3 files https://stackabuse.com/python-circular-imports/.
I feel a way out would be to have two files:
support.py
-> Having classesNode
andEdge.
network.py
->TensorNetwork
class only
from tensornetwork.
So I started working on this and what is frustrating is that the tests pass by pytype doesn't. I'll be sure to raise a bug on that internally.
from tensornetwork.
@Thenerdstation I think we need to close this now right? As you have completed the and merged the new structure.
from tensornetwork.
Related Issues (20)
- Flaky Test when seed not used HOT 5
- Flaky test (always fails) when seeds are removed HOT 1
- Test `test_gmres_on_larger_random_problem` fails without seeds
- symmetric backend very slow for PEPS tensors HOT 4
- Home Network
- lack sqrt operation in tensornetwork/matrixproductstates/infinite_mps.py
- TensorNetwork backend for QuTiP. HOT 2
- Bug for numpy backend ``sum`` method HOT 3
- SVD on jax backend and thus ``split_node`` cannot be jitted when ``max_truncation_err`` is set
- Bug of setting `center_position` in `apply_two_site_gate` when there's no truncation
- Quantum hardware system integration with TensorNetwork
- Missing code for TensorNetwork Machine Learning HOT 1
- `backend.item` in MPS calculation is incompatible with autograd in jax HOT 2
- The lack of tensor-train RNNs for latest tf/keras HOT 1
- Parallelism Contractors HOT 1
- Question: Vector to FiniteMPS?
- Is there a simple way to multiply a scalar to the tensor values of a node that is part of a network of tensors? HOT 2
- Maintenance of this repository HOT 3
- Tensor
- Pf
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from tensornetwork.