Google Summer of Code 2020’s second evaluation is about to complete. Now we are about to start with the final coding phase. This post discusses about the progress so far in the last two weeks of the second coding period from 13 July to 26 July 2020.
Modular approach towards removal of matplotlib baseline images#
We have divided the work in two parts as discussed in the previous blog. The first part is the generation of the baseline images discussed below. The second part is the modification of the baseline images. The modification part will be implemented in the last phase of the Google Summer of Code 2020.
Generation of the matplotlib baseline images#
Now, we have started removing the use of the
matplotlib_baseline_images package. After the changes proposed in the previous PR, the developer will have no baseline images on fresh install of matplotlib. So, the developer would need to generate matplotlib baseline images locally to get started with the testing part of the mpl.
The images can be generated by the image comparison tests with use of
matplotlib_baseline_image_generation flag from the command line. Once these images are generated for the first time, then they can be used as the baseline images for the later times for comparison. This is the main principle adopted.
Completion of the generation of images for the matplotlib directory#
We successfully created the
matplotlib_baseline_image_generation flag in the beginning of the second evaluation but images were not created in the
baseline images directory inside the
mpl_toolkits directories, instead they were created in the
result_images directory. So, we implemented this functionality. The images are created in the
lib/matplotlib/tests/baseline_images directory directly now in the baseline image generation step. The baseline image generation step uses
python3 -mpytest lib/matplotlib --matplotlib_baseline_image_generation command. Later on, running the pytests with
python3 -mpytest lib/matplotlib will start the image comparison.
Right now, the matplotlib_baseline_image_generation flag works for the matplotlib directory. We are trying to achieve the same functionality for the mpl_toolkits directory.
Once the generation of the baseline images for
mpl_toolkits directory is completed in the current PR, we will move to the modification of the baseline images in the third coding phase. The addition of new baseline image and deletion of the old baseline image will also be implemented in the last phase of GSoC. Modification of baseline images will be further divided into two sub tasks: addition of new baseline image and the deletion of the previous baseline image.
Monday to Thursday meeting initiated at 11:00pm IST via Zoom. Meeting notes are present at HackMD.
I am grateful to be part of such a great community. Project is really interesting and challenging :) Thanks Thomas, Antony and Hannah for helping me so far.