ants.plotting.movie

movie(image, filename=None, writer=None, fps=30)[source]

Create and save a movie - mp4, gif, etc - of the various 2D slices of a 3D ants image

Try this:

conda install -c conda-forge ffmpeg

Example

>>> import ants
>>> mni = ants.image_read(ants.get_data('mni'))
>>> ants.movie(mni, filename='~/desktop/movie.mp4')