Skip to content

Commit

Permalink
fixup! STY: manual fixes for newly flagged violations of UP031
Browse files Browse the repository at this point in the history
  • Loading branch information
neutrinoceros committed Nov 26, 2024
1 parent 0988a0e commit 147548d
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 4 deletions.
2 changes: 1 addition & 1 deletion yt/data_objects/construction_data_containers.py
Original file line number Diff line number Diff line change
Expand Up @@ -2612,7 +2612,7 @@ def _export_ply(
)
else:
v = np.empty(self.vertices.shape[1], dtype=vs[:3])
line = f"element face {nv/3}\n"
line = f"element face {int(nv/3)}\n"
f.write(line.encode("latin-1"))
f.write(b"property list uchar int vertex_indices\n")
if color_field is not None and sample_type == "face":
Expand Down
3 changes: 1 addition & 2 deletions yt/frontends/athena/data_structures.py
Original file line number Diff line number Diff line change
Expand Up @@ -297,8 +297,7 @@ def _parse_index(self):
gridread["dimensions"][gridread["dimensions"] == 0] = 1
if np.prod(gridread["dimensions"]) != gridread["ncells"]:
mylog.error(
f"product of dimensions {np.prod(grid['dimensions'])} "
f"not equal to number of cells {grid['ncells']}",
"product of dimensions %i not equal to number of cells %i",
np.prod(gridread["dimensions"]),
gridread["ncells"],
)
Expand Down
2 changes: 1 addition & 1 deletion yt/frontends/enzo/data_structures.py
Original file line number Diff line number Diff line change
Expand Up @@ -574,7 +574,7 @@ def _parse_index(self):
self.grids = np.empty(len(grids), dtype="object")
for i, grid in enumerate(grids):
if (i % 1e4) == 0:
mylog.debug(f"Prepared {i:>7} / {self.num_grids:>7} grids")
mylog.debug("Prepared % 7i / % 7i grids", i, self.num_grids)
grid.filename = f"Inline_processor_{self.grid_procs[i, 0]:07}"
grid._prepare_grid()
grid._setup_dx()
Expand Down

0 comments on commit 147548d

Please sign in to comment.