Skip to content

Fix ValueError when structure.selective_dynamics has type np.array - #3012

Merged
janosh merged 5 commits into
masterfrom
fix-gh-3011
May 24, 2023
Merged

janosh merged 5 commits into
masterfrom
fix-gh-3011

Conversation

@janosh

@janosh janosh commented May 24, 2023

Copy link
Copy Markdown
Member

Closes #3011.

71e888d refactor LammpsData.get_string()
a1d3509 refactor ase import, AseAtomsAdaptor.get_atoms() check is_struct
a21543c fix ValueError: The truth value of an array with more than one element is ambiguous. Use a.any() or a.all() when structure.selective_dynamics has type np.array
bf56232 add cases testing selective_dynamics as list and array to test_get_structure_dyn()

@janosh janosh added io Input/output functionality fix Bug fix PRs labels May 24, 2023
…cs in only some dimensions. Remove the selective_dynamics=[False, False, False]

ignore mypy assignment error
@janosh
janosh enabled auto-merge (squash) May 24, 2023 17:21
@janosh
janosh merged commit ae3197d into master May 24, 2023
@janosh
janosh deleted the fix-gh-3011 branch May 24, 2023 17:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

fix Bug fix PRs io Input/output functionality

Projects

None yet

Development

Successfully merging this pull request may close these issues.

AseAtomsAdaptor.get_atoms(structure, **kwargs) compares numpy boolean array wtith python nested list.

1 participant