Google Summer of Code 2020’s first evaluation is completed. I passed!!! Hurray! Now we are in the mid way of the second evaluation. This post discusses about the progress so far in the first two weeks of the second coding period from 30 June to 12 July 2020.

Completion of the matplotlib_baseline_images package#

We successfully created the matplotlib_baseline_images package. It contains the matplotlib and the matplotlib toolkit baseline images. Symlinking is done for the baseline images, related changes for Travis, appvoyer, azure pipelines etc. are functional and tests/test_data is created as discussed in the previous blog. PR is reviewed and suggested work is done.

Modular approach towards removal of matplotlib baseline images#

We have divide the work in two parts. The first part is the generation of the baseline images discussed below. The second part is the modification of the baseline images which happens when some baseline images gets modified due to git push or git merge. 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. This will be discussed in the second half of the second phase of the Google Summer of Code 2020.

Generation of the matplotlib baseline images#

After the changes proposed in the previous PR, the developer will have no baseline images on fresh install of matplotlib. The developer would need to install the sub-wheel matplotlib_baseline_images package to get started with the testing part of the mpl. Now, we have started removing the use of the matplotlib_baseline_images package. It will require two steps as discussed above. The images can be generated by the image comparison tests. 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. The images are first created in the result_images directory. Then they will be moved to the lib/matplotlib/tests/baseline_images directory. Later on, running the pytests will start the image comparison.

Created commandline flags for baseline images creation#

I learned about the pytest hooks and fixtures. I build a command line flag matplotlib_baseline_image_generation which will create the baseline images in the result_images directory. The full command will be python3 pytest --matplotlib_baseline_image_generation. In order to do this, we have done changes in the and also added markers to the image_comparison decorator.

Learning more about the Git and virtual environments#

I came to know about the git worktree and the scenarios in which we can use it. I also know more about virtual environments and their need in different scenarios.

Future Goals#

Once the generation of the baseline images is completed in the current PR, we will move to the modification of the baseline images in the second half of the second coding phase.

Daily Meet-ups#

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.