Skip to content

Commit

Permalink
Solve mypy variable check
Browse files Browse the repository at this point in the history
  • Loading branch information
Cristobal Pio Garcia committed Jul 5, 2024
1 parent 68b0498 commit 3cfc878
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
6 changes: 5 additions & 1 deletion python/lsst/summit/utils/imageExaminer.py
Original file line number Diff line number Diff line change
Expand Up @@ -497,6 +497,10 @@ def plotContours(self, ax: matplotlib.axes.Axes | None = None, nContours: int =
if plotDirect:
plt.show()

def _create3DPlot(self, figSize: tuple[int, int]) -> tuple[plt.Figure, Axes3D]:
# Support function to create a 3D plot
return plt.subplots(subplot_kw={"projection": "3d"}, figsize=figSize)

def plotSurface(self, ax: Axes3D | None = None, useColor: bool = True) -> None:
"""Make the surface plot.
Expand All @@ -510,7 +514,7 @@ def plotSurface(self, ax: Axes3D | None = None, useColor: bool = True) -> None:
"""
plotDirect = False
if not ax:
fig, ax = plt.subplots(subplot_kw={"projection": "3d"}, figsize=(10, 10))
fig, ax = self._create3DPlot((10, 10))
plotDirect = True

if useColor:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -251,7 +251,7 @@ def plot_torque_data(ax: plt.Axes, dataset: M1M3ICSAnalysis) -> None:

def plot_stable_region(
fig: plt.Figure, begin: Time, end: Time, label: str = "", color: str = "b"
) -> plt.Polygon:
) -> plt.Rectangle:
"""
Highlight a stable region on the plot with a colored span.
Expand Down

0 comments on commit 3cfc878

Please sign in to comment.