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

Reload tf_indices outside while in get_tensor #57

Merged
merged 4 commits into from
Oct 2, 2018
Merged

Conversation

drasmuss
Copy link
Member

@drasmuss drasmuss commented Sep 10, 2018

TensorSignal indices are loaded on-demand during the build process (since we may never need them, depending on how signals are merged). This means that, depending on when a Signal is first accessed, the indices may be initialized inside or outside the Simulation while loop. Normally that doesn't matter, unless we want to access that Signal through tensor_graph.get_signal. That accesses the signal value statically, outside of the while loop, so the indices also need to be created outside the while loop. This makes sure that is the case.

Fixes #56

@drasmuss drasmuss merged commit 42e0416 into master Oct 2, 2018
@drasmuss drasmuss deleted the signal_fix branch October 2, 2018 18:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant