Skip to content

Commit

Permalink
fix bad rebase that i did
Browse files Browse the repository at this point in the history
  • Loading branch information
nabobalis authored and DanRyanIrish committed Apr 27, 2024
1 parent 45b7f7e commit fa61199
Show file tree
Hide file tree
Showing 5 changed files with 17 additions and 23 deletions.
2 changes: 1 addition & 1 deletion changelog/7592.removal.rst
Original file line number Diff line number Diff line change
@@ -1 +1 @@
Deprecates several data methods on map in favour of `sunpy.map.GenericMap.data.method()`.
Deprecated several data methods on map in favour of ``sunpy.map.GenericMap.data.<method_name>``.
22 changes: 11 additions & 11 deletions docs/how_to/create_custom_map.rst
Original file line number Diff line number Diff line change
Expand Up @@ -157,18 +157,18 @@ From these header MetaDict's that are generated, we can now create a custom map:
<sunpy.map.mapbase.GenericMap object at ...>
SunPy Map
---------
Observatory: Test case
Instrument: UV detector
Observatory: Test case
Instrument: UV detector
Detector:
Measurement: 1000.0 Angstrom
Wavelength: 1000.0 Angstrom
Observation Date: 2013-10-28 00:00:00
Exposure Time: Unknown
Dimension: [10. 10.] pix
Coordinate System: helioprojective
Scale: [2. 2.] arcsec / pix
Reference Pixel: [5. 5.] pix
Reference Coord: [0. 0.] arcsec
Measurement: 1000.0 Angstrom
Wavelength: 1000.0 Angstrom
Observation Date: 2013-10-28 00:00:00
Exposure Time: Unknown
Pixel Dimensions: [10. 10.]
Coordinate System: helioprojective
Scale: [2. 2.] arcsec / pix
Reference Pixel: [5. 5.] pix
Reference Coord: [0. 0.] arcsec
array([[ 0, 1, 2, 3, 4, 5, 6, 7, 8, 9],
[10, 11, 12, 13, 14, 15, 16, 17, 18, 19],
[20, 21, 22, 23, 24, 25, 26, 27, 28, 29],
Expand Down
9 changes: 2 additions & 7 deletions sunpy/map/mapbase.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
import astropy.wcs
from astropy.coordinates import BaseCoordinateFrame, SkyCoord, UnitSphericalRepresentation
from astropy.utils.metadata import MetaData
from astropy.visualization import AsymmetricPercentileInterval, HistEqStretch, ImageNormalize
from astropy.visualization import HistEqStretch, ImageNormalize
from astropy.visualization.wcsaxes import WCSAxes

import sunpy
Expand All @@ -46,15 +46,10 @@
from sunpy.map.mixins.mapmeta import MapMetaMixin
from sunpy.util import MetaDict
from sunpy.util.decorators import add_common_docstring, cached_property_based_on
from sunpy.util.decorators import (
add_common_docstring,
cached_property_based_on,
check_arithmetic_compatibility,
)
from sunpy.util.exceptions import warn_user
from sunpy.util.functools import seconddispatch
from sunpy.util.util import _figure_to_base64, fix_duplicate_notes
from sunpy.visualization.plotter import MapPlotter
from sunpy.visualization.plotter.mpl_plotter import MapPlotter

TIME_FORMAT = config.get("general", "time_format")
_NUMPY_COPY_IF_NEEDED = False if np.__version__.startswith("1.") else None
Expand Down
3 changes: 2 additions & 1 deletion sunpy/map/mixins/__init__.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
from .mapdeprecate import MapDeprecateMixin
from .mapmeta import MapMetaMixin, MapMetaValidationError

__all__ = ['MapMetaValidationError', 'MapMetaMixin']
__all__ = ['MapMetaValidationError', 'MapMetaMixin', 'MapDeprecateMixin']
4 changes: 1 addition & 3 deletions sunpy/map/mixins/mapdeprecate.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,9 @@

class MapDeprecateMixin:
"""
This class contains the deprecated attributes on map
This class contains the deprecated attributes on map.
"""

# Some numpy extraction

@property
@deprecated(since="6.1", message=".dimensions will be removed in 6.1. Use sunpy.map.GenericMap.shape instead")
def dimensions(self):
Expand Down

0 comments on commit fa61199

Please sign in to comment.