Skip to content

fix(show-smooth-structure): image and gif saved to cwd (+1 more) - #98

Open
andrewwhitecdw wants to merge 2 commits into
NVlabs:masterfrom
andrewwhitecdw:bugfix/show-smooth-structure-assorted-5298373d
Open

fix(show-smooth-structure): image and gif saved to cwd (+1 more)#98
andrewwhitecdw wants to merge 2 commits into
NVlabs:masterfrom
andrewwhitecdw:bugfix/show-smooth-structure-assorted-5298373d

Conversation

@andrewwhitecdw

@andrewwhitecdw andrewwhitecdw commented Jul 27, 2026

Copy link
Copy Markdown

Small fixes in visual_tools/show_smooth_structure.py:

fix: image and gif saved to cwd, ignoring output_folder

Fix: Replace:

pic.save('smooth-s.jpg')

# save gif
imageio.mimsave('./smooth-s.gif', gif)

with:

pic.save(os.path.join(opts.output_folder, 'smooth-s.jpg'))

# save gif
imageio.mimsave(os.path.join(opts.output_folder, 'smooth-s.gif'), gif)

fix: GIF writer receives float images instead of uint8

Fix: Replace:

# save gif
imageio.mimsave('./smooth-s.gif', gif)

with:

# save gif
imageio.mimsave('./smooth-s.gif', [frame.astype(np.uint8) for frame in gif])

Files changed

  • visual_tools/show_smooth_structure.py

andrewwhitecdw and others added 2 commits July 27, 2026 07:25
Auditor: The diff only fixes the output path for the JPG and GIF, but the second stated problem (GIF frames are floats instead of uint8) is not addressed. The `imageio.mimsave` call still passes `gif` unchanged. The PR is incomplete relative to its own description.
@andrewwhitecdw
andrewwhitecdw marked this pull request as ready for review August 3, 2026 22:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant