From 8007ff6562f2dfedaad7de92625e04e7b64381a7 Mon Sep 17 00:00:00 2001 From: HarshGamerZ-28 Date: Tue, 3 Mar 2026 23:03:59 +0530 Subject: [PATCH 1/3] Fix CALISTO coordinate logic and improve docstring grammar --- radiospectra/spectrogram/sources/callisto.py | 4 ++-- radiospectra/spectrogram/spectrogrambase.py | 8 ++++---- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/radiospectra/spectrogram/sources/callisto.py b/radiospectra/spectrogram/sources/callisto.py index 1baef81b..d8cf028b 100644 --- a/radiospectra/spectrogram/sources/callisto.py +++ b/radiospectra/spectrogram/sources/callisto.py @@ -31,8 +31,8 @@ def __init__(self, data, meta, **kwargs): @property def observatory_location(self): - lat = self.meta["fits_meta"]["OBS_LAT"] * u.deg * 1.0 if self.meta["fits_meta"]["OBS_LAC"] == "N" else -1.0 - lon = self.meta["fits_meta"]["OBS_LON"] * u.deg * 1.0 if self.meta["fits_meta"]["OBS_LOC"] == "E" else -1.0 + lat = self.meta["fits_meta"]["OBS_LAT"] * u.deg * (1.0 if self.meta["fits_meta"]["OBS_LAC"] == "N" else -1.0) + lon = self.meta["fits_meta"]["OBS_LON"] * u.deg * (1.0 if self.meta["fits_meta"]["OBS_LOC"] == "E" else -1.0) height = self.meta["fits_meta"]["OBS_ALT"] * u.m return EarthLocation(lat=lat, lon=lon, height=height) diff --git a/radiospectra/spectrogram/spectrogrambase.py b/radiospectra/spectrogram/spectrogrambase.py index f1cb2b3f..d37cc343 100644 --- a/radiospectra/spectrogram/spectrogrambase.py +++ b/radiospectra/spectrogram/spectrogrambase.py @@ -11,9 +11,9 @@ class GenericSpectrogram(PcolormeshPlotMixin, NonUniformImagePlotMixin): Attributes ---------- meta : `dict-like` - Meta data for the spectrogram. + Metadata for the spectrogram. data : `numpy.ndarray` - The spectrogram data itself a 2D array. + The spectrogram data itself is a 2D array. """ _registry = {} @@ -90,8 +90,8 @@ def _validate_meta(self): This method includes very basic validation checks which apply to all of the kinds of files that radiospectra can read. - Datasource-specific validation should be handled in the relevant - file in the radiospectra.spectrogram.sources. + Datasource-specific validation should be handled in the relevant + file in radiospectra.spectrogram.sources. """ msg = "Spectrogram coordinate units for {} axis not present in metadata." err_message = [] From 850e85dbd72e919b92e5785b8d1950780c0307ad Mon Sep 17 00:00:00 2001 From: HarshGamerZ-28 Date: Tue, 3 Mar 2026 23:15:36 +0530 Subject: [PATCH 2/3] Include missing updates to conf.py --- docs/conf.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/conf.py b/docs/conf.py index 44427a11..7caefbdc 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -2,7 +2,7 @@ # # This file does only contain a selection of the most common options. For a # full list see the documentation: -# http://www.sphinx-doc.org/en/master/config +# https://www.sphinx-doc.org/en/master/config # flake8: NOQA: E402 @@ -20,7 +20,7 @@ os.environ["HOME"] = "/home/docs/" os.environ["LANG"] = "C" os.environ["LC_ALL"] = "C" - os.environ["HIDE_PARFIVE_PROGESS"] = "True" + os.environ["HIDE_PARFIVE_PROGRESS"] = "True" # -- Project information ----------------------------------------------------- From cd5a19ff2233c60b229058aeb34c04a104c6d744 Mon Sep 17 00:00:00 2001 From: HarshGamerZ-28 Date: Wed, 4 Mar 2026 15:52:45 +0530 Subject: [PATCH 3/3] Apply automated styling fixes and add changelog --- changelog/169.bugfix.rst | 0 radiospectra/spectrogram/spectrogrambase.py | 2 +- 2 files changed, 1 insertion(+), 1 deletion(-) create mode 100644 changelog/169.bugfix.rst diff --git a/changelog/169.bugfix.rst b/changelog/169.bugfix.rst new file mode 100644 index 00000000..e69de29b diff --git a/radiospectra/spectrogram/spectrogrambase.py b/radiospectra/spectrogram/spectrogrambase.py index d37cc343..fd3f4395 100644 --- a/radiospectra/spectrogram/spectrogrambase.py +++ b/radiospectra/spectrogram/spectrogrambase.py @@ -90,7 +90,7 @@ def _validate_meta(self): This method includes very basic validation checks which apply to all of the kinds of files that radiospectra can read. - Datasource-specific validation should be handled in the relevant + Datasource-specific validation should be handled in the relevant file in radiospectra.spectrogram.sources. """ msg = "Spectrogram coordinate units for {} axis not present in metadata."