contrailcirrus / pycontrails

Python library for modeling contrails and other aviation climate impacts
https://py.contrails.org/
Apache License 2.0
59 stars 17 forks source link

minor (pseudo-regression) in newer pycontrails releases #226

Closed nickmasson closed 3 months ago

nickmasson commented 3 months ago

Description

Newer releases of pycontrails include an import of matplotlib in the output_formats of models.cocip. See here.

Matplot lib is only referenced in the compare_cocip_with_goes method.

Matplotlib is an optional dependency under vis

Change Request The import matplotlib.pyplot as plt should be localized (moved) inside the code block for this method definition. This will avoid forcing the user to import matplotlib when using any of the other methods in output_formats (i.e. for users who are not making use of the optional vis dependencies and methods).

Details