LSST Applications  21.0.0+75b29a8a7f,21.0.0+e70536a077,21.0.0-1-ga51b5d4+62c747d40b,21.0.0-10-gbfb87ad6+3307648ee3,21.0.0-15-gedb9d5423+47cba9fc36,21.0.0-2-g103fe59+fdf0863a2a,21.0.0-2-g1367e85+d38a93257c,21.0.0-2-g45278ab+e70536a077,21.0.0-2-g5242d73+d38a93257c,21.0.0-2-g7f82c8f+e682ffb718,21.0.0-2-g8dde007+d179fbfa6a,21.0.0-2-g8f08a60+9402881886,21.0.0-2-ga326454+e682ffb718,21.0.0-2-ga63a54e+08647d4b1b,21.0.0-2-gde069b7+26c92b3210,21.0.0-2-gecfae73+0445ed2f95,21.0.0-2-gfc62afb+d38a93257c,21.0.0-27-gbbd0d29+ae871e0f33,21.0.0-28-g5fc5e037+feb0e9397b,21.0.0-3-g21c7a62+f4b9c0ff5c,21.0.0-3-g357aad2+57b0bddf0b,21.0.0-3-g4be5c26+d38a93257c,21.0.0-3-g65f322c+3f454acf5d,21.0.0-3-g7d9da8d+75b29a8a7f,21.0.0-3-gaa929c8+9e4ef6332c,21.0.0-3-ge02ed75+4b120a55c4,21.0.0-4-g3300ddd+e70536a077,21.0.0-4-g591bb35+4b120a55c4,21.0.0-4-gc004bbf+4911b9cd27,21.0.0-4-gccdca77+f94adcd104,21.0.0-4-ge8fba5a+2b3a696ff9,21.0.0-5-gb155db7+2c5429117a,21.0.0-5-gdf36809+637e4641ee,21.0.0-6-g00874e7+c9fd7f7160,21.0.0-6-g4e60332+4b120a55c4,21.0.0-7-gc8ca178+40eb9cf840,21.0.0-8-gfbe0b4b+9e4ef6332c,21.0.0-9-g2fd488a+d83b7cd606,w.2021.05
LSST Data Management Base Package
Public Member Functions | Static Public Member Functions | Public Attributes | Static Public Attributes | List of all members
lsst.obs.base.test.baseMapper.BaseMapper Class Reference
Inheritance diagram for lsst.obs.base.test.baseMapper.BaseMapper:
lsst.obs.base.cameraMapper.CameraMapper lsst.daf.persistence.mapper.Mapper

Public Member Functions

def __init__ (self, root)
 
def getPackageDir (cls)
 
def backup (self, datasetType, dataId)
 
def keys (self)
 
def getKeys (self, datasetType, level)
 
def getDefaultLevel (self)
 
def getDefaultSubLevel (self, level)
 
def getCameraName (cls)
 
def getPackageName (cls)
 
def getGen3Instrument (cls)
 
def map_camera (self, dataId, write=False)
 
def bypass_camera (self, datasetType, pythonType, butlerLocation, dataId)
 
def map_expIdInfo (self, dataId, write=False)
 
def bypass_expIdInfo (self, datasetType, pythonType, location, dataId)
 
def std_bfKernel (self, item, dataId)
 
def std_raw (self, item, dataId)
 
def map_skypolicy (self, dataId)
 
def std_skypolicy (self, item, dataId)
 
def getRegistry (self)
 
def getImageCompressionSettings (self, datasetType, dataId)
 
def __new__ (cls, *args, **kwargs)
 
def __getstate__ (self)
 
def __setstate__ (self, state)
 
def queryMetadata (self, datasetType, format, dataId)
 
def getDatasetTypes (self)
 
def map (self, datasetType, dataId, write=False)
 
def canStandardize (self, datasetType)
 
def standardize (self, datasetType, item, dataId)
 
def validate (self, dataId)
 

Static Public Member Functions

def getShortCcdName (ccdName)
 

Public Attributes

 log
 
 root
 
 levels
 
 defaultLevel
 
 defaultSubLevels
 
 rootStorage
 
 registry
 
 calibRegistry
 
 keyDict
 
 cameraDataLocation
 
 camera
 
 filters
 
 makeRawVisitInfo
 
 mappings
 

Static Public Attributes

string packageName = 'base'
 
dictionary policy
 
 MakeRawVisitInfoClass = MakeRawVisitInfo
 
 PupilFactoryClass = afwCameraGeom.PupilFactory
 
 translatorClass = None
 

Detailed Description

Definition at line 28 of file baseMapper.py.

Constructor & Destructor Documentation

◆ __init__()

def lsst.obs.base.test.baseMapper.BaseMapper.__init__ (   self,
  root 
)

Definition at line 41 of file baseMapper.py.

41  def __init__(self, root):
42  CameraMapper.__init__(self, policy=dafPersist.Policy(BaseMapper.policy),
43  repositoryDir=root, root=root)
44 

Member Function Documentation

◆ __getstate__()

def lsst.daf.persistence.mapper.Mapper.__getstate__ (   self)
inherited

Definition at line 101 of file mapper.py.

101  def __getstate__(self):
102  return self._arguments
103 

◆ __new__()

def lsst.daf.persistence.mapper.Mapper.__new__ (   cls,
args,
**  kwargs 
)
inherited
Create a new Mapper, saving arguments for pickling.

This is in __new__ instead of __init__ to save the user
from having to save the arguments themselves (either explicitly,
or by calling the super's __init__ with all their
*args,**kwargs.  The resulting pickling system (of __new__,
__getstate__ and __setstate__ is similar to how __reduce__
is usually used, except that we save the user from any
responsibility (except when overriding __new__, but that
is not common).

Definition at line 82 of file mapper.py.

82  def __new__(cls, *args, **kwargs):
83  """Create a new Mapper, saving arguments for pickling.
84 
85  This is in __new__ instead of __init__ to save the user
86  from having to save the arguments themselves (either explicitly,
87  or by calling the super's __init__ with all their
88  *args,**kwargs. The resulting pickling system (of __new__,
89  __getstate__ and __setstate__ is similar to how __reduce__
90  is usually used, except that we save the user from any
91  responsibility (except when overriding __new__, but that
92  is not common).
93  """
94  self = super().__new__(cls)
95  self._arguments = (args, kwargs)
96  return self
97 

◆ __setstate__()

def lsst.daf.persistence.mapper.Mapper.__setstate__ (   self,
  state 
)
inherited

Definition at line 104 of file mapper.py.

104  def __setstate__(self, state):
105  self._arguments = state
106  args, kwargs = state
107  self.__init__(*args, **kwargs)
108 

◆ backup()

def lsst.obs.base.cameraMapper.CameraMapper.backup (   self,
  datasetType,
  dataId 
)
inherited
Rename any existing object with the given type and dataId.

The CameraMapper implementation saves objects in a sequence of e.g.:

- foo.fits
- foo.fits~1
- foo.fits~2

All of the backups will be placed in the output repo, however, and will
not be removed if they are found elsewhere in the _parent chain.  This
means that the same file will be stored twice if the previous version
was found in an input repo.

Reimplemented from lsst.daf.persistence.mapper.Mapper.

Definition at line 623 of file cameraMapper.py.

623  def backup(self, datasetType, dataId):
624  """Rename any existing object with the given type and dataId.
625 
626  The CameraMapper implementation saves objects in a sequence of e.g.:
627 
628  - foo.fits
629  - foo.fits~1
630  - foo.fits~2
631 
632  All of the backups will be placed in the output repo, however, and will
633  not be removed if they are found elsewhere in the _parent chain. This
634  means that the same file will be stored twice if the previous version
635  was found in an input repo.
636  """
637 
638  # Calling PosixStorage directly is not the long term solution in this
639  # function, this is work-in-progress on epic DM-6225. The plan is for
640  # parentSearch to be changed to 'search', and search only the storage
641  # associated with this mapper. All searching of parents will be handled
642  # by traversing the container of repositories in Butler.
643 
644  def firstElement(list):
645  """Get the first element in the list, or None if that can't be
646  done.
647  """
648  return list[0] if list is not None and len(list) else None
649 
650  n = 0
651  newLocation = self.map(datasetType, dataId, write=True)
652  newPath = newLocation.getLocations()[0]
653  path = dafPersist.PosixStorage.search(self.root, newPath, searchParents=True)
654  path = firstElement(path)
655  oldPaths = []
656  while path is not None:
657  n += 1
658  oldPaths.append((n, path))
659  path = dafPersist.PosixStorage.search(self.root, "%s~%d" % (newPath, n), searchParents=True)
660  path = firstElement(path)
661  for n, oldPath in reversed(oldPaths):
662  self.rootStorage.copyFile(oldPath, "%s~%d" % (newPath, n))
663 

◆ bypass_camera()

def lsst.obs.base.cameraMapper.CameraMapper.bypass_camera (   self,
  datasetType,
  pythonType,
  butlerLocation,
  dataId 
)
inherited
Return the (preloaded) camera object.

Definition at line 775 of file cameraMapper.py.

775  def bypass_camera(self, datasetType, pythonType, butlerLocation, dataId):
776  """Return the (preloaded) camera object.
777  """
778  if self.camera is None:
779  raise RuntimeError("No camera dataset available.")
780  return self.camera
781 

◆ bypass_expIdInfo()

def lsst.obs.base.cameraMapper.CameraMapper.bypass_expIdInfo (   self,
  datasetType,
  pythonType,
  location,
  dataId 
)
inherited
Hook to retrieve an lsst.obs.base.ExposureIdInfo for an exposure

Definition at line 793 of file cameraMapper.py.

793  def bypass_expIdInfo(self, datasetType, pythonType, location, dataId):
794  """Hook to retrieve an lsst.obs.base.ExposureIdInfo for an exposure"""
795  expId = self.bypass_ccdExposureId(datasetType, pythonType, location, dataId)
796  expBits = self.bypass_ccdExposureId_bits(datasetType, pythonType, location, dataId)
797  return ExposureIdInfo(expId=expId, expBits=expBits)
798 

◆ canStandardize()

def lsst.daf.persistence.mapper.Mapper.canStandardize (   self,
  datasetType 
)
inherited
Return true if this mapper can standardize an object of the given
dataset type.

Definition at line 165 of file mapper.py.

165  def canStandardize(self, datasetType):
166  """Return true if this mapper can standardize an object of the given
167  dataset type."""
168 
169  return hasattr(self, 'std_' + datasetType)
170 

◆ getCameraName()

def lsst.obs.base.cameraMapper.CameraMapper.getCameraName (   cls)
inherited
Return the name of the camera that this CameraMapper is for.

Definition at line 718 of file cameraMapper.py.

718  def getCameraName(cls):
719  """Return the name of the camera that this CameraMapper is for."""
720  className = str(cls)
721  className = className[className.find('.'):-1]
722  m = re.search(r'(\w+)Mapper', className)
723  if m is None:
724  m = re.search(r"class '[\w.]*?(\w+)'", className)
725  name = m.group(1)
726  return name[:1].lower() + name[1:] if name else ''
727 

◆ getDatasetTypes()

def lsst.daf.persistence.mapper.Mapper.getDatasetTypes (   self)
inherited
Return a list of the mappable dataset types.

Definition at line 126 of file mapper.py.

126  def getDatasetTypes(self):
127  """Return a list of the mappable dataset types."""
128 
129  list = []
130  for attr in dir(self):
131  if attr.startswith("map_"):
132  list.append(attr[4:])
133  return list
134 

◆ getDefaultLevel()

def lsst.obs.base.cameraMapper.CameraMapper.getDefaultLevel (   self)
inherited

Definition at line 709 of file cameraMapper.py.

709  def getDefaultLevel(self):
710  return self.defaultLevel
711 

◆ getDefaultSubLevel()

def lsst.obs.base.cameraMapper.CameraMapper.getDefaultSubLevel (   self,
  level 
)
inherited

Definition at line 712 of file cameraMapper.py.

712  def getDefaultSubLevel(self, level):
713  if level in self.defaultSubLevels:
714  return self.defaultSubLevels[level]
715  return None
716 

◆ getGen3Instrument()

def lsst.obs.base.cameraMapper.CameraMapper.getGen3Instrument (   cls)
inherited
Return the gen3 Instrument class equivalent for this gen2 Mapper.

Returns
-------
instr : `type`
    A `~lsst.obs.base.Instrument` class.

Definition at line 736 of file cameraMapper.py.

736  def getGen3Instrument(cls):
737  """Return the gen3 Instrument class equivalent for this gen2 Mapper.
738 
739  Returns
740  -------
741  instr : `type`
742  A `~lsst.obs.base.Instrument` class.
743  """
744  if cls._gen3instrument is None:
745  raise NotImplementedError("Please provide a specific implementation for your instrument"
746  " to enable conversion of this gen2 repository to gen3")
747  if isinstance(cls._gen3instrument, str):
748  # Given a string to convert to an instrument class
749  cls._gen3instrument = doImport(cls._gen3instrument)
750  if not issubclass(cls._gen3instrument, Instrument):
751  raise ValueError(f"Mapper {cls} has declared a gen3 instrument class of {cls._gen3instrument}"
752  " but that is not an lsst.obs.base.Instrument")
753  return cls._gen3instrument
754 

◆ getImageCompressionSettings()

def lsst.obs.base.cameraMapper.CameraMapper.getImageCompressionSettings (   self,
  datasetType,
  dataId 
)
inherited
Stuff image compression settings into a daf.base.PropertySet

This goes into the ButlerLocation's "additionalData", which gets
passed into the boost::persistence framework.

Parameters
----------
datasetType : `str`
    Type of dataset for which to get the image compression settings.
dataId : `dict`
    Dataset identifier.

Returns
-------
additionalData : `lsst.daf.base.PropertySet`
    Image compression settings.

Definition at line 1327 of file cameraMapper.py.

1327  def getImageCompressionSettings(self, datasetType, dataId):
1328  """Stuff image compression settings into a daf.base.PropertySet
1329 
1330  This goes into the ButlerLocation's "additionalData", which gets
1331  passed into the boost::persistence framework.
1332 
1333  Parameters
1334  ----------
1335  datasetType : `str`
1336  Type of dataset for which to get the image compression settings.
1337  dataId : `dict`
1338  Dataset identifier.
1339 
1340  Returns
1341  -------
1342  additionalData : `lsst.daf.base.PropertySet`
1343  Image compression settings.
1344  """
1345  mapping = self.mappings[datasetType]
1346  recipeName = mapping.recipe
1347  storageType = mapping.storage
1348  if storageType not in self._writeRecipes:
1349  return dafBase.PropertySet()
1350  if recipeName not in self._writeRecipes[storageType]:
1351  raise RuntimeError("Unrecognized write recipe for datasetType %s (storage type %s): %s" %
1352  (datasetType, storageType, recipeName))
1353  recipe = self._writeRecipes[storageType][recipeName].deepCopy()
1354  seed = hash(tuple(dataId.items())) % 2**31
1355  for plane in ("image", "mask", "variance"):
1356  if recipe.exists(plane + ".scaling.seed") and recipe.getScalar(plane + ".scaling.seed") == 0:
1357  recipe.set(plane + ".scaling.seed", seed)
1358  return recipe
1359 
Class for storing generic metadata.
Definition: PropertySet.h:67

◆ getKeys()

def lsst.obs.base.cameraMapper.CameraMapper.getKeys (   self,
  datasetType,
  level 
)
inherited
Return a dict of supported keys and their value types for a given
dataset type at a given level of the key hierarchy.

Parameters
----------
datasetType :  `str`
    Dataset type or None for all dataset types.
level :  `str` or None
    Level or None for all levels or '' for the default level for the
    camera.

Returns
-------
`dict`
    Keys are strings usable in a dataset identifier, values are their
    value types.

Definition at line 674 of file cameraMapper.py.

674  def getKeys(self, datasetType, level):
675  """Return a dict of supported keys and their value types for a given
676  dataset type at a given level of the key hierarchy.
677 
678  Parameters
679  ----------
680  datasetType : `str`
681  Dataset type or None for all dataset types.
682  level : `str` or None
683  Level or None for all levels or '' for the default level for the
684  camera.
685 
686  Returns
687  -------
688  `dict`
689  Keys are strings usable in a dataset identifier, values are their
690  value types.
691  """
692 
693  # not sure if this is how we want to do this. what if None was
694  # intended?
695  if level == '':
696  level = self.getDefaultLevel()
697 
698  if datasetType is None:
699  keyDict = copy.copy(self.keyDict)
700  else:
701  keyDict = self.mappings[datasetType].keys()
702  if level is not None and level in self.levels:
703  keyDict = copy.copy(keyDict)
704  for lev in self.levels[level]:
705  if lev in keyDict:
706  del keyDict[lev]
707  return keyDict
708 

◆ getPackageDir()

def lsst.obs.base.test.baseMapper.BaseMapper.getPackageDir (   cls)
Return the base directory of this package

Reimplemented from lsst.obs.base.cameraMapper.CameraMapper.

Definition at line 46 of file baseMapper.py.

46  def getPackageDir(cls):
47  return "/path/to/nowhere"
std::string getPackageDir(std::string const &packageName)
return the root directory of a setup package
Definition: packaging.cc:33

◆ getPackageName()

def lsst.obs.base.cameraMapper.CameraMapper.getPackageName (   cls)
inherited
Return the name of the package containing this CameraMapper.

Definition at line 729 of file cameraMapper.py.

729  def getPackageName(cls):
730  """Return the name of the package containing this CameraMapper."""
731  if cls.packageName is None:
732  raise ValueError('class variable packageName must not be None')
733  return cls.packageName
734 

◆ getRegistry()

def lsst.obs.base.cameraMapper.CameraMapper.getRegistry (   self)
inherited
Get the registry used by this mapper.

Returns
-------
Registry or None
    The registry used by this mapper for this mapper's repository.

Reimplemented from lsst.daf.persistence.mapper.Mapper.

Definition at line 1317 of file cameraMapper.py.

1317  def getRegistry(self):
1318  """Get the registry used by this mapper.
1319 
1320  Returns
1321  -------
1322  Registry or None
1323  The registry used by this mapper for this mapper's repository.
1324  """
1325  return self.registry
1326 

◆ getShortCcdName()

def lsst.obs.base.cameraMapper.CameraMapper.getShortCcdName (   ccdName)
staticinherited
Convert a CCD name to a form useful as a filename

The default implementation converts spaces to underscores.

Definition at line 987 of file cameraMapper.py.

987  def getShortCcdName(ccdName):
988  """Convert a CCD name to a form useful as a filename
989 
990  The default implementation converts spaces to underscores.
991  """
992  return ccdName.replace(" ", "_")
993 

◆ keys()

def lsst.obs.base.cameraMapper.CameraMapper.keys (   self)
inherited
Return supported keys.

Returns
-------
iterable
    List of keys usable in a dataset identifier

Reimplemented from lsst.daf.persistence.mapper.Mapper.

Definition at line 664 of file cameraMapper.py.

664  def keys(self):
665  """Return supported keys.
666 
667  Returns
668  -------
669  iterable
670  List of keys usable in a dataset identifier
671  """
672  return iter(self.keyDict.keys())
673 

◆ map()

def lsst.daf.persistence.mapper.Mapper.map (   self,
  datasetType,
  dataId,
  write = False 
)
inherited
Map a data id using the mapping method for its dataset type.

Parameters
----------
datasetType : string
    The datasetType to map
dataId : DataId instance
    The dataId to use when mapping
write : bool, optional
    Indicates if the map is being performed for a read operation
    (False) or a write operation (True)

Returns
-------
ButlerLocation or a list of ButlerLocation
    The location(s) found for the map operation. If write is True, a
    list is returned. If write is False a single ButlerLocation is
    returned.

Raises
------
NoResults
    If no locaiton was found for this map operation, the derived mapper
    class may raise a lsst.daf.persistence.NoResults exception. Butler
    catches this and will look in the next Repository if there is one.

Definition at line 135 of file mapper.py.

135  def map(self, datasetType, dataId, write=False):
136  """Map a data id using the mapping method for its dataset type.
137 
138  Parameters
139  ----------
140  datasetType : string
141  The datasetType to map
142  dataId : DataId instance
143  The dataId to use when mapping
144  write : bool, optional
145  Indicates if the map is being performed for a read operation
146  (False) or a write operation (True)
147 
148  Returns
149  -------
150  ButlerLocation or a list of ButlerLocation
151  The location(s) found for the map operation. If write is True, a
152  list is returned. If write is False a single ButlerLocation is
153  returned.
154 
155  Raises
156  ------
157  NoResults
158  If no locaiton was found for this map operation, the derived mapper
159  class may raise a lsst.daf.persistence.NoResults exception. Butler
160  catches this and will look in the next Repository if there is one.
161  """
162  func = getattr(self, 'map_' + datasetType)
163  return func(self.validate(dataId), write)
164 

◆ map_camera()

def lsst.obs.base.cameraMapper.CameraMapper.map_camera (   self,
  dataId,
  write = False 
)
inherited
Map a camera dataset.

Definition at line 760 of file cameraMapper.py.

760  def map_camera(self, dataId, write=False):
761  """Map a camera dataset."""
762  if self.camera is None:
763  raise RuntimeError("No camera dataset available.")
764  actualId = self._transformId(dataId)
766  pythonType="lsst.afw.cameraGeom.CameraConfig",
767  cppType="Config",
768  storageName="ConfigStorage",
769  locationList=self.cameraDataLocation or "ignored",
770  dataId=actualId,
771  mapper=self,
772  storage=self.rootStorage
773  )
774 

◆ map_expIdInfo()

def lsst.obs.base.cameraMapper.CameraMapper.map_expIdInfo (   self,
  dataId,
  write = False 
)
inherited

Definition at line 782 of file cameraMapper.py.

782  def map_expIdInfo(self, dataId, write=False):
784  pythonType="lsst.obs.base.ExposureIdInfo",
785  cppType=None,
786  storageName="Internal",
787  locationList="ignored",
788  dataId=dataId,
789  mapper=self,
790  storage=self.rootStorage
791  )
792 

◆ map_skypolicy()

def lsst.obs.base.cameraMapper.CameraMapper.map_skypolicy (   self,
  dataId 
)
inherited
Map a sky policy.

Definition at line 815 of file cameraMapper.py.

815  def map_skypolicy(self, dataId):
816  """Map a sky policy."""
817  return dafPersist.ButlerLocation("lsst.pex.policy.Policy", "Policy",
818  "Internal", None, None, self,
819  storage=self.rootStorage)
820 

◆ queryMetadata()

def lsst.daf.persistence.mapper.Mapper.queryMetadata (   self,
  datasetType,
  format,
  dataId 
)
inherited
Get possible values for keys given a partial data id.

:param datasetType: see documentation about the use of datasetType
:param key: this is used as the 'level' parameter
:param format:
:param dataId: see documentation about the use of dataId
:return:

Definition at line 112 of file mapper.py.

112  def queryMetadata(self, datasetType, format, dataId):
113  """Get possible values for keys given a partial data id.
114 
115  :param datasetType: see documentation about the use of datasetType
116  :param key: this is used as the 'level' parameter
117  :param format:
118  :param dataId: see documentation about the use of dataId
119  :return:
120  """
121  func = getattr(self, 'query_' + datasetType)
122 
123  val = func(format, self.validate(dataId))
124  return val
125 

◆ standardize()

def lsst.daf.persistence.mapper.Mapper.standardize (   self,
  datasetType,
  item,
  dataId 
)
inherited
Standardize an object using the standardization method for its data
set type, if it exists.

Definition at line 171 of file mapper.py.

171  def standardize(self, datasetType, item, dataId):
172  """Standardize an object using the standardization method for its data
173  set type, if it exists."""
174 
175  if hasattr(self, 'std_' + datasetType):
176  func = getattr(self, 'std_' + datasetType)
177  return func(item, self.validate(dataId))
178  return item
179 

◆ std_bfKernel()

def lsst.obs.base.cameraMapper.CameraMapper.std_bfKernel (   self,
  item,
  dataId 
)
inherited
Disable standardization for bfKernel

bfKernel is a calibration product that is numpy array,
unlike other calibration products that are all images;
all calibration images are sent through _standardizeExposure
due to CalibrationMapping, but we don't want that to happen to bfKernel

Definition at line 799 of file cameraMapper.py.

799  def std_bfKernel(self, item, dataId):
800  """Disable standardization for bfKernel
801 
802  bfKernel is a calibration product that is numpy array,
803  unlike other calibration products that are all images;
804  all calibration images are sent through _standardizeExposure
805  due to CalibrationMapping, but we don't want that to happen to bfKernel
806  """
807  return item
808 

◆ std_raw()

def lsst.obs.base.cameraMapper.CameraMapper.std_raw (   self,
  item,
  dataId 
)
inherited
Standardize a raw dataset by converting it to an Exposure instead
of an Image

Reimplemented in lsst.obs.decam.decamMapper.DecamMapper.

Definition at line 809 of file cameraMapper.py.

809  def std_raw(self, item, dataId):
810  """Standardize a raw dataset by converting it to an Exposure instead
811  of an Image"""
812  return self._standardizeExposure(self.exposures['raw'], item, dataId,
813  trimmed=False, setVisitInfo=True)
814 

◆ std_skypolicy()

def lsst.obs.base.cameraMapper.CameraMapper.std_skypolicy (   self,
  item,
  dataId 
)
inherited
Standardize a sky policy by returning the one we use.

Definition at line 821 of file cameraMapper.py.

821  def std_skypolicy(self, item, dataId):
822  """Standardize a sky policy by returning the one we use."""
823  return self.skypolicy
824 

◆ validate()

def lsst.daf.persistence.mapper.Mapper.validate (   self,
  dataId 
)
inherited
Validate a dataId's contents.

If the dataId is valid, return it.  If an invalid component can be
transformed into a valid one, copy the dataId, fix the component, and
return the copy.  Otherwise, raise an exception.

Reimplemented in lsst.obs.test.testMapper.TestMapper.

Definition at line 180 of file mapper.py.

180  def validate(self, dataId):
181  """Validate a dataId's contents.
182 
183  If the dataId is valid, return it. If an invalid component can be
184  transformed into a valid one, copy the dataId, fix the component, and
185  return the copy. Otherwise, raise an exception."""
186 
187  return dataId
188 

Member Data Documentation

◆ calibRegistry

lsst.obs.base.cameraMapper.CameraMapper.calibRegistry
inherited

Definition at line 259 of file cameraMapper.py.

◆ camera

lsst.obs.base.cameraMapper.CameraMapper.camera
inherited

Definition at line 277 of file cameraMapper.py.

◆ cameraDataLocation

lsst.obs.base.cameraMapper.CameraMapper.cameraDataLocation
inherited

Definition at line 276 of file cameraMapper.py.

◆ defaultLevel

lsst.obs.base.cameraMapper.CameraMapper.defaultLevel
inherited

Definition at line 218 of file cameraMapper.py.

◆ defaultSubLevels

lsst.obs.base.cameraMapper.CameraMapper.defaultSubLevels
inherited

Definition at line 219 of file cameraMapper.py.

◆ filters

lsst.obs.base.cameraMapper.CameraMapper.filters
inherited

Definition at line 280 of file cameraMapper.py.

◆ keyDict

lsst.obs.base.cameraMapper.CameraMapper.keyDict
inherited

Definition at line 270 of file cameraMapper.py.

◆ levels

lsst.obs.base.cameraMapper.CameraMapper.levels
inherited

Definition at line 213 of file cameraMapper.py.

◆ log

lsst.obs.base.cameraMapper.CameraMapper.log
inherited

Definition at line 199 of file cameraMapper.py.

◆ makeRawVisitInfo

lsst.obs.base.cameraMapper.CameraMapper.makeRawVisitInfo
inherited

Definition at line 287 of file cameraMapper.py.

◆ MakeRawVisitInfoClass

lsst.obs.base.cameraMapper.CameraMapper.MakeRawVisitInfoClass = MakeRawVisitInfo
staticinherited

Definition at line 181 of file cameraMapper.py.

◆ mappings

lsst.obs.base.cameraMapper.CameraMapper.mappings
inherited

Definition at line 338 of file cameraMapper.py.

◆ packageName

string lsst.obs.base.test.baseMapper.BaseMapper.packageName = 'base'
static

Definition at line 29 of file baseMapper.py.

◆ policy

dictionary lsst.obs.base.test.baseMapper.BaseMapper.policy
static
Initial value:
= {
"camera": "camera",
"defaultLevel": "sensor",
"datasets": {},
"exposures": {},
"calibrations": {},
"images": {}
}

Definition at line 32 of file baseMapper.py.

◆ PupilFactoryClass

lsst.obs.base.cameraMapper.CameraMapper.PupilFactoryClass = afwCameraGeom.PupilFactory
staticinherited

Definition at line 184 of file cameraMapper.py.

◆ registry

lsst.obs.base.cameraMapper.CameraMapper.registry
inherited

Definition at line 251 of file cameraMapper.py.

◆ root

lsst.obs.base.cameraMapper.CameraMapper.root
inherited

Definition at line 202 of file cameraMapper.py.

◆ rootStorage

lsst.obs.base.cameraMapper.CameraMapper.rootStorage
inherited

Definition at line 228 of file cameraMapper.py.

◆ translatorClass

lsst.obs.base.cameraMapper.CameraMapper.translatorClass = None
staticinherited

Definition at line 187 of file cameraMapper.py.


The documentation for this class was generated from the following file: