Skip to content

Commit

Permalink
examples: fix metaballs creation from file
Browse files Browse the repository at this point in the history
float division, leftover from python 2
  • Loading branch information
tfarago committed Jul 7, 2021
1 parent e7cd67e commit 4f24122
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion examples/metaballs.py
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@ def main():
elif args.method == "file":
# 1e6 because packing converts to meters
values = np.fromfile(args.input, dtype=np.float32) * 1e6
metaballs, objects_all = create_metaballs(values.reshape(len(values) / 4, 4), pixel_size)
metaballs, objects_all = create_metaballs(values.reshape(len(values) // 4, 4), pixel_size)
else:
distance = args.distance or args.n / 4
positions = [
Expand Down

0 comments on commit 4f24122

Please sign in to comment.