Skip to content

Commit

Permalink
upd version 0.4.3 (bugfix with .astype(np.int32))
Browse files Browse the repository at this point in the history
  • Loading branch information
Yury Lysogorskiy committed Nov 18, 2024
1 parent b5d9112 commit 9a0338c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

setup(
name="tensorpotential",
version="0.4.2",
version="0.4.3",
packages=find_packages(include=["tensorpotential", "tensorpotential.*"]),
url="https://github.com/ICAMS/grace-tensorpotential",
license="Academic Software License (ASL)",
Expand Down
4 changes: 3 additions & 1 deletion tensorpotential/data/databuilder.py
Original file line number Diff line number Diff line change
Expand Up @@ -413,7 +413,9 @@ def pad_batch(self, batch, max_pad_dict):
pad_nat, pad_nneigh, pad_nstruct = get_padding_dims(batch, max_pad_dict)

max_nat = np.array(max_pad_dict[constants.PAD_MAX_N_ATOMS]).astype(np.int32)
max_structs = max_pad_dict[constants.PAD_MAX_N_STRUCTURES].astype(np.int32)
max_structs = np.array(max_pad_dict[constants.PAD_MAX_N_STRUCTURES]).astype(
np.int32
)

batch[constants.N_ATOMS_BATCH_TOTAL] = max_nat
batch[constants.N_STRUCTURES_BATCH_TOTAL] = max_structs
Expand Down

0 comments on commit 9a0338c

Please sign in to comment.