Uploaded image for project: 'Data Management'
  1. Data Management
  2. DM-4140

For registry-free butler, look up information in related data type.

    XMLWordPrintable

Details

    • Story
    • Status: Invalid
    • Resolution: Done
    • None
    • None
    • None
    • Data Access and Database

    Description

      description from DM-3591: Read information (in particular the observation time and length) out of an input dataset's file representation in order to provide rendezvous with calibration data in another repository (that does have a registry). Today, that read is handled by genInputRegistry.py so that the butler doesn't need to look into the dataset itself. If there's no registry, such a read will be necessary.

      Attachments

        Issue Links

          Activity

            WRT DecamMapper.paf,
            the call: butler.get(flat, dataid(visit=n, ccdnum=m)) will look up data in the
            'flat' dataset type. In the case where the information is not available, need
            to consult the 'reference' dataset type, and look it up there, like so:

            1. dataid is used to generate a location using the raw dataset type. (because it
            doesn't exist in flat, and we wish policy:reference was "raw", but actually it's
            raw_visit which is a subset of the raw table that is optimized to go faster but
            is different.

            2. generate the location, it should be a fits file. in this case it has a bracket
            extension. call lsst.afw.image.readmetadata (or similar in astroypy) on the
            location (with brackets or not) and it will get the right fits header.

            3. depending on the camera, the header may need to be converted (numeric to string
            or vice versa). so we need a hook for the mapper subclass to be able to do
            something (transform) the header value.

            4. then it gets fed into the existing calibrationMapping subclass that does the
            query.
            CalibrationMapping gets the data via the registry (that I need to get via
            metadata) in lookup, at line 348:
            lookups = self.refRegistry.executeQuery(columns, self.reference,
            where, None, values)
            it passes it to Mapping.lookup and THAT uses the validity lookup - using
            self.obsTimeName and self.range which is set in the CalibrationMapping ctor,
            based on the policy.

            to create the test:
            1. modify the policy to look more like the obs_decam policy:
            subpolicy needs template, validTime, etc
            policy would ask for the MJD-OBS - the julian date since (a very long time ago),
            it's modified because it's had a (fixed, known) number subtracted from it.

            or, try using https://github.com/lsst/obs_cfht

            npease Nate Pease [X] (Inactive) added a comment - WRT DecamMapper.paf, the call: butler.get(flat, dataid(visit=n, ccdnum=m)) will look up data in the 'flat' dataset type. In the case where the information is not available, need to consult the 'reference' dataset type, and look it up there, like so: 1. dataid is used to generate a location using the raw dataset type. (because it doesn't exist in flat, and we wish policy:reference was "raw", but actually it's raw_visit which is a subset of the raw table that is optimized to go faster but is different. 2. generate the location, it should be a fits file. in this case it has a bracket extension. call lsst.afw.image.readmetadata (or similar in astroypy) on the location (with brackets or not) and it will get the right fits header. 3. depending on the camera, the header may need to be converted (numeric to string or vice versa). so we need a hook for the mapper subclass to be able to do something (transform) the header value. 4. then it gets fed into the existing calibrationMapping subclass that does the query. CalibrationMapping gets the data via the registry (that I need to get via metadata) in lookup, at line 348: lookups = self.refRegistry.executeQuery(columns, self.reference, where, None, values) it passes it to Mapping.lookup and THAT uses the validity lookup - using self.obsTimeName and self.range which is set in the CalibrationMapping ctor, based on the policy. to create the test: 1. modify the policy to look more like the obs_decam policy: subpolicy needs template, validTime, etc policy would ask for the MJD-OBS - the julian date since (a very long time ago), it's modified because it's had a (fixed, known) number subtracted from it. or, try using https://github.com/lsst/obs_cfht

            (oops. this issue should be deleted)

            npease Nate Pease [X] (Inactive) added a comment - (oops. this issue should be deleted)

            duplicate.

            npease Nate Pease [X] (Inactive) added a comment - duplicate.

            People

              npease Nate Pease [X] (Inactive)
              npease Nate Pease [X] (Inactive)
              Nate Pease [X] (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Jenkins

                  No builds found.