Skip to content

Commit

Permalink
removed unused variable, and converted to f-string
Browse files Browse the repository at this point in the history
Signed-off-by: Nick Papior <[email protected]>
  • Loading branch information
zerothi committed Oct 30, 2023
1 parent b13b7be commit 7d27f09
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/sisl/geom/_common.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ def geometry_define_nsc(geometry, periodic=(True, True, True)):
"""Define the number of supercells for a geometry based on the periodicity """
if np.all(geometry.maxR(True) > 0.):
geometry.optimize_nsc()
for i, d, per in zip(range(3), "abc", periodic):
for d, per in zip("abc", periodic):
if per:
geometry.lattice.set_boundary_condition(**{d: "Periodic"})
else:
Expand Down
2 changes: 1 addition & 1 deletion src/sisl/geometry.py
Original file line number Diff line number Diff line change
Expand Up @@ -1692,7 +1692,7 @@ def optimize_nsc(self, axis=None, R=None) -> ndarray:
R = self.maxR() + 0.001
if R < 0:
R = 0.00001
warn(self.__class__.__name__ +
warn(f"{self.__class__.__name__}"
".optimize_nsc could not determine the radius from the "
"internal atoms (defaulting to zero radius).")

Expand Down

0 comments on commit 7d27f09

Please sign in to comment.