add requires_package for pygraphviz

This commit is contained in:
Alyssa Travitz
2026-02-03 16:14:13 -08:00
parent a4292b3e16
commit 85d4d41cec
2 changed files with 2 additions and 3 deletions

View File

@@ -1,9 +1,7 @@
import importlib.resources
import inspect
from unittest import mock
import matplotlib
import matplotlib.figure
import pytest
from matplotlib import pyplot as plt

View File

@@ -10,7 +10,7 @@ from gufe.visualization.mapping_visualization import (
from rdkit import Chem
from openfe import LigandNetwork, SmallMoleculeComponent
from openfe.utils.custom_typing import MPL_MouseEvent
from openfe.utils import requires_package
from openfe.utils.network_plotting import Edge, GraphDrawing, Node
@@ -156,6 +156,7 @@ class AtomMappingNetworkDrawing(GraphDrawing):
EdgeCls = AtomMappingEdge
@requires_package("pygraphviz")
def plot_atommapping_network(network: LigandNetwork):
"""Convenience method for plotting the atom mapping network