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

zntrack.apply can not pickle local object #799

Closed
PythonFZ opened this issue May 16, 2024 · 0 comments · Fixed by #800
Closed

zntrack.apply can not pickle local object #799

PythonFZ opened this issue May 16, 2024 · 0 comments · Fixed by #800
Labels
bug Something isn't working p1-important

Comments

@PythonFZ
Copy link
Member

There is a bug with using the Node after zntrack.apply as dependecy, e.g.:

    mapped_md = zn.apply(ips.calculators.ASEMD, method='map')(
        data=md_selection.atoms,
        model=model1,
        thermostat=thermostat,
        checks=[],
        modifiers=[],
        steps=10,
        sampling_rate=1,
        pop_last=True,
        use_momenta=False,
        constraints=[],
        name="mapped_MD"
    )
    
    flat_md = ips.base.Flatten(mapped_md.atoms)
@PythonFZ PythonFZ added bug Something isn't working p1-important labels May 16, 2024
@PythonFZ PythonFZ linked a pull request May 17, 2024 that will close this issue
PythonFZ added a commit that referenced this issue May 17, 2024
* write test for issue with `zntrack.apply` can not pickle local object #799

* add assertions

* more testing

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working p1-important
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant