Skip to content

Commit

Permalink
fix a bug
Browse files Browse the repository at this point in the history
  • Loading branch information
j-otsuki committed Apr 23, 2024
1 parent dea66aa commit 88233d5
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/dcore/interaction.py
Original file line number Diff line number Diff line change
Expand Up @@ -418,7 +418,7 @@ def _generate_umat_file(p: Dict):
try:
if os.path.splitext(file)[1] == ".npy":
umat = numpy.load(file)
assert umat.shape == u_shape
assert umat.shape == u_shape, f"inconsistent shape: require {u_shape}, but {umat.shape} is given"
else:
umat_1d = numpy.loadtxt(file)
umat = umat_1d.reshape(u_shape)
Expand All @@ -433,7 +433,7 @@ def _generate_umat_file(p: Dict):
umat_so = to_spin_full_U_matrix(umat)
assert umat_so.shape == (2*norb, 2*norb, 2*norb, 2*norb)

u_mat_so_sh.append(umat)
u_mat_so_sh.append(umat_so)

return u_mat_so_sh

Expand Down

0 comments on commit 88233d5

Please sign in to comment.