GenericMappingTools / GenericMappingTools/gmt
Movie creation. Improving/acceleratin processing
- Dominant language
- C
- Stars
- 979
- Forks
- 414
- Avg merge
- 17h 26m
- Merged PRs (30d)
- 54
Description
Hi @PaulWessel
Just a bit of context first. In the first versions of animation 14 I was using @earth_relief_15s but them decided to prove with @earth_relief_03s. As you can see below, it is worthwhile to use the 03s grid.


However, when I make the full movie (with 435 frames) I was surprised that it took like an hour to do it when previously it took just about 5 minutes. The only difference was the grid. To make it short, I modified the original script. I remove the commands to create the map from the background shell (pre.sh) and put it before and then I use psimage in pre.sh to include the png of the map. It took 5 minutes to create the mp4!!! Below are the scripts so you can test them and check.
Then, I realized that the difference of time processing was due to the size of movie_background.ps. In the original script is too big (144 MB) while in the modified script was 7.1 MB. So most of the time was spent dealing that the big file that then is reduced to a 2 MB png for each frame. Below are the two animation put together. I don't see any difference.
In conclusion I think if you reduce the size of movie_background.ps (by just converting it to a raster image) the processing can be reduced. BTW I run the same test for the 15s and in that case both scripts took about the same time as expected because the movie_background.ps are very similar (7.1 vs 6.1 MB).
Hope to be clear.
Shell Scripts (in txt):
Original: [anim14.txt](https://github.com/GenericMappingTools/gmt/files/6322496/anim14.txt)
Modified: [anim14_Image.txt](https://github.com/GenericMappingTools/gmt/files/6322485/anim14_Image.txt)
Original script:
Date of Master frame: 23∶56∶44
Date of Mp4 : 00∶43∶43
Time processing duration : 47:00
Size movie_background.ps : 144,0 MB
Modified script:
Date of the Master frame: 23∶50∶15
Date of the Mp4 : 23∶55∶02
Duration : 05:00
Size of movie_background.ps : 7,1 MB
https://user-images.githubusercontent.com/17908951/114970886-adc76e80-9e51-11eb-9dad-4f51e6806f5b.mp4
Contributor guide
Assessment
This issue has not been assessed yet.