| | |
- astro.main.ProcessTarget.ProcessTarget(common.database.DBMeta.DBMixin, astro.main.OnTheFly.OnTheFly)
-
- AstrometricParameters(common.database.DBMain.DBObject, astro.main.ProcessTarget.ProcessTarget)
- common.database.DBMain.DBObject(__builtin__.object)
-
- AstrometricParameters(common.database.DBMain.DBObject, astro.main.ProcessTarget.ProcessTarget)
- AstrometricParametersParameters
- exceptions.Exception(exceptions.BaseException)
-
- AstrometricParametersError
class AstrometricParameters(common.database.DBMain.DBObject, astro.main.ProcessTarget.ProcessTarget) |
| |
This class represents the calfile used in the astrometric calibration
of the science images.
The details of the steps performed in the derive_astrometry() method
which derives the formal astrometric solution with LDAC are as
follows:
Steps: Sextractor.sex - creates original catalog from source
frame
LDAC.ldacconv - converts SExtractor catalog to cat_name
LDAC.preastrom - determines linear affine parameters and
creates USNO catalog to be associated
LDAC.aplastrom - applies affine prameters from AFFINE
table created by preastrom
LDAC.filter - filters out most non-stellar-like
sources from OBJECTS table
LDAC.associate - associates modified catalog from
aplastrom after preatrom to the USNO
catlog output from preatrom
LDAC.make_ssc - makes a pairs catalog from individual
catalogs output from associate
LDAC.astrom - runs the astrometric solution on the
unmodified catalog output from
preastrom using the pairs catalog
output from make_ssc
LDAC.aplastrom - applies the OBJECTS table of the
astrom output catalog with the values
from the ASTROM table added by astrom
LDAC.make_distort - adds the DISTORTIONS table, converting
back to world coordinates
Files: cat_name - input LDAC catalog to preastrom as
converted from the SExtractor catalog by
ldacconv (contains first OBJECTS table)
refcat - environmental pointer to USNO input
reference catalog (input to preastrom)
*.cat1 - output catalog of preastrom (contains
unaltered OBJECTS table and the addition
of the AFFINE table containing the linear
solution from preastrom) and input catalog
to aplastrom and astrom
*.cat2 - output reference catalog from preastrom
(contains a copy of the applicable portion
of the USNO catalog) and input catalog to
associate
distances_file - output distances catalog from preastrom
*.cat3 - output catalog of aplastrom (has had
OBJECTS table modified by values in AFFINE
table) and input catalog to filter
*.cat3a - output catalog of filter (OBJECTS table
filtered to retain only most stellar-like
sources, i.e., most circular sources)
input catalog to associate
*.cat4 - output catalog of associate (contains
pairing information from extracted sources)
and input catalog to make_ssc
*.cat5 - output catalog of associate (contains
pairing information from reference sources)
and input catalog to make_ssc
*.cat6 - output catalog of make_ssc (contains
contents of associated catalogs filtered to
single occurance of sources) and input
pairs catalog to astrom
*.cat7 - output catalog of astrom (contains
unmodified OBJECTS table and AFFINE table
from preastrom, and ASTROM table from
astrom) and input to aplastrom
residuals_file - output residuals catalog from astrom
self.residuals - name of final residuals catalog (derived
from residuals_file separately)
*.cat8 - output of aplastrom (has had OBJECTS table
modified by values in ASTROM table) and
input to make_distort
astcat_file - output catalog of make_distort (has had
DISTORTIONS table added) containing the
final solution information |
| |
- Method resolution order:
- AstrometricParameters
- common.database.DBMain.DBObject
- astro.main.ProcessTarget.ProcessTarget
- common.database.DBMeta.DBMixin
- __builtin__.object
- astro.main.OnTheFly.OnTheFly
Methods defined here:
- __init__(self, pathname='', refsl=None)
- after_do_make(self, switches=None)
- After the (OnTheFly) make of an AstrometricParameters object a SourceList should
be made, which will/can be used by the Gastrometric.
- check_preconditions(self)
- commit(self)
- compare(self, exact=False)
- Compare method for AstrometricParameters
Checks values tested in verify to see how they compare to the
previous version derived from the same RawFrame and only warns if
they are out of tolerence. Flag setting may eventually be enforced.
exact: if True, query only for versions with the same ReducedFrame
- compare_residuals_to_regrid(self, derived_type='sextractor', detect_thresh=10.0, filter_stellar=True, inter_color_tol=1.0, filter_closest=True)
- Compare the derived astrometric solution made or stored in this
object to the solution as applied to a RegriddedFrame.
derived_type: type of method to use for creating catalog
detect_thresh: SExtractor DETECT_THRESH value
filter_stellar: filter out most non-stellar sources from input
catalogs prior to association
inter_color_tol: LDAC.associate INTER_COLOR_TOL value
filter_closest: toggle filtering of closest pairs when creating
residuals catalog (does not affect existing
catalogs)
The applied solution is represented by a catalog extracted from
a RegriddedFrame created by applying the astrometric solution to
the source ReducedScienceFrame. The derived (predicted) solution
can be represented in one of three ways:
1. the catalog that the solution parameters are derived from as
created by LDAC during the AstrometricParameters make (requires
that the make was just run in the same directory so the catalog
is available)
2. a catalog extracted from the source ReducedScienceFrame using
the astrometric solution parameters stored in the
AstrometricParameters object
3. a catalog extracted from the source ReducedScienceFrame using
the original parameters stored in the frame header with the
astrometric solution parameters stored in the
AstrometricParameters object applied by LDAC
The selection of the type of the derived catalog used in the
comparison is done with the 'derived_type' parameter and is one of
'solution', 'sextractor', or 'ldac' and are related to the above
methods in the following way:
solution: use catalog from method 1.
sextractor: use catalog from method 2.
ldac: use catalog from method 3.
- copy_attributes(self)
- derive_and_set_seeing(self, astcat_file)
- derive_astrometry(self)
- Derive astrometric solution with LDAC.
Steps: Sextractor.sex - creates original catalog from source
frame
LDAC.ldacconv - converts SExtractor catalog to cat_name
LDAC.preastrom - determines linear affine parameters and
creates USNO catalog to be associated
LDAC.aplastrom - applies affine prameters from AFFINE
table created by preastrom
LDAC.filter - filters out most non-stellar-like
sources from OBJECTS table
LDAC.associate - associates modified catalog from
aplastrom after preatrom to the USNO
catlog output from preatrom
LDAC.make_ssc - makes a pairs catalog from individual
catalogs output from associate
LDAC.astrom - runs the astrometric solution on the
unmodified catalog output from
preastrom using the pairs catalog
output from make_ssc
LDAC.aplastrom - applies the OBJECTS table of the
astrom output catalog with the values
from the ASTROM table added by astrom
LDAC.make_distort - adds the DISTORTIONS table, converting
back to world coordinates
Files: cat_name - input LDAC catalog to preastrom as
converted from the SExtractor catalog by
ldacconv (contains first OBJECTS table)
refcat - environmental pointer to USNO input
reference catalog (input to preastrom)
*.cat1 - output catalog of preastrom (contains
unaltered OBJECTS table and the addition
of the AFFINE table containing the linear
solution from preastrom) and input catalog
to aplastrom and astrom
*.cat2 - output reference catalog from preastrom
(contains a copy of the applicable portion
of the USNO catalog) and input catalog to
associate
distances_file - output distances catalog from preastrom
*.cat3 - output catalog of aplastrom (has had
OBJECTS table modified by values in AFFINE
table) and input catalog to filter
*.cat3a - output catalog of filter (OBJECTS table
filtered to retain only most stellar-like
sources, i.e., most circular sources)
input catalog to associate
*.cat4 - output catalog of associate (contains
pairing information from extracted sources)
and input catalog to make_ssc
*.cat5 - output catalog of associate (contains
pairing information from reference sources)
and input catalog to make_ssc
*.cat6 - output catalog of make_ssc (contains
contents of associated catalogs filtered to
single occurance of sources) and input
pairs catalog to astrom
*.cat7 - output catalog of astrom (contains
unmodified OBJECTS table and AFFINE table
from preastrom, and ASTROM table from
astrom) and input to aplastrom
residuals_file - output residuals catalog from astrom
self.residuals - name of final residuals catalog (derived
from residuals_file separately)
*.cat8 - output of aplastrom (has had OBJECTS table
modified by values in ASTROM table) and
input to make_distort
astcat_file - output catalog of make_distort (has had
DISTORTIONS table added) containing the
final solution information
- derive_timestamp(self)
- get_canonical_name_for_residuals(self)
- Generate the unique filename for the associated residuals file.
- get_fixed_config(self)
- Return the fixed sextractor configuration parameters.
- get_fixed_params_list(self)
- Return the fixed sextractor parameters.
- get_pixelarea(self)
- Calculate area of a pixel from the CDm_n matrix
Given the CD matrix, which defines the scale and rotation from grid
coordinates to physical coordinates:
|CD11 CD12|
|CD21 CD22|
Then the area of a pixel in physical coordinates is roughly
PIXELAREA = ABS(CD11*CD22 - CD21*CD12)
The units of "pixelarea" are CTYPE1*CTYPE2, which should be
arcsec-squared for most - if not all - widefield imaging instruments.
- get_refcat_location(self)
- Return the name of the reference catalog reference catalog
created from the SourceList self.refsl, or the USNO-A2.0
directory or URL if the reference SourceList does not exist.
- inspect(self, kappa=3.0, range=None, domain=None, verbose=2)
- Inspect method for AstrometricParameters
kappa: clipping factor for plot data (iterative clipping at
kappa*sigma of DRA/DDEC level)
range: a tuple defining (xmin, xmax) of DRA, overriding automatic
width determination (does not affect RA, DEC, Xpos, Ypos)
domain: a tuple defining (ymin, ymax) of DDEC, overriding automatic
height determination (does not affect RA, DEC, Xpos, Ypos)
verbose: set the verbosity of the plotting routines
Plots DRA (delta RA) versus DDEC (delta DEC) residuals; DRA versus
RA and XPOS (x position); and DDEC versus DEC and YPOS (y position).
By default, all plots are saved as PNG (.png) for later inspection.
To change this behavior, set plot_params.EXTENSION to another format
(.ps, .eps, etc.) or to None to save nothing.
See the AstromResidualsPlot class for more detailed information:
awe> from astro.plot.AstrometryPlot import AstromResidualsPlot
awe> help(AstromResidualsPlot)
To retrieve and inspect the residuals file, use:
awe> DataObject(pathname=aps.residuals).retrieve()
awe> aps.inspect()
where 'aps' is an AstrometricParameters object.
- load(self)
- make(self)
- make_from_header_values(self)
- make_residuals_catalog(self)
- make_residual_catalog creates a (Transient) DataObject containing
the residuals from the catalog generated by the astrometry routines.
- plot_residuals_to_regrid(self, derived_type='sextractor', detect_thresh=10.0, filter_stellar=True, inter_color_tol=1.0, filter_closest=True, range=None, domain=None, verbose=2)
- Plot the derived astrometric solution made or stored in this
object to the solution as applied to a RegriddedFrame.
derived_type: type of method to use for creating catalog
detect_thresh: SExtractor DETECT_THRESH value
filter_stellar: filter out most non-stellar sources from input
catalogs prior to association
inter_color_tol: LDAC.associate INTER_COLOR_TOL value
filter_closest: toggle filtering of closest pairs when creating
residuals catalog (does not affect existing
catalogs)
range: a tuple defining (xmin, xmax) of DRA,
overriding automatic width determination (does
not affect RA, DEC, Xpos, Ypos)
domain: a tuple defining (ymin, ymax) of DDEC,
overriding automatic height determination (does
not affect RA, DEC, Xpos, Ypos)
verbose: set the verbosity of the plotting routines
The applied solution is represented by a catalog extracted from
a RegriddedFrame created by applying the astrometric solution to
the source ReducedScienceFrame. The derived (predicted) solution
can be represented in one of two ways:
1. the catalog that the solution parameters are derived from as
created by LDAC during the AstrometricParameters make (requires
that the make was just run in the same directory so the catalog
is available)
2. a catalog extracted from the source ReducedScienceFrame using
the astrometric solution parameters stored in the
AstrometricParameters object
The selection of the type of the derived catalog used in the
comparison is done with the 'derived_type' parameter and is one of
'solution' or 'sextractor' and are related to the above methods in
the following way:
solution: use catalog from method 1.
sextractor: use catalog from method 2.
- plot_residuals_to_usno(self, source='applied', range=None, domain=None, verbose=2)
- Plot residuals of a catalog with respect to USNO-A2.0.
source: which catalog to use (solution for astcat_file, applied
for RegriddedFrame catalog)
range: a tuple defining (xmin, xmax) of DRA, overriding automatic
width determination (does not affect RA, DEC, Xpos, Ypos)
domain: a tuple defining (ymin, ymax) of DDEC, overriding automatic
height determination (does not affect RA, DEC, Xpos, Ypos)
verbose: set the verbosity of the plotting routines
Find residuals with respect to either the astcat_file of this
AstrometricParameters object (requires that the solution be run
first) or a catalog extracted from a RegriddedFrame that this
solution has been applied to create.
- save(self)
- set_astrometric_parameters(self, distortion_data, astrom_data, statistics_data)
- update_header(self, header)
- update_sex_config(self)
- Update the sexconf with the fixed configuration parameters.
- update_sex_params(self)
- Update the sexparams with the fixed parameters.
- verify(self)
- Verify method for AstrometricParameters
Checks limits defined under AstrometricParametersParameters and
sets flags if they are out of tolerence.
- write_headerfile(self, headerfile_name='astrom.head')
Class methods defined here:
- exist(cls, date_time=None, chip=None, filter=None, object_id=None, template=None, **args) from common.database.DBMeta.DBObjectMeta
- The exist method searches for the object using the provided
parameters, this is a customized version of the exist in
method in OnTheFly.
A customized version is needed because AstrometricParameters
does not have a DATE_OBS but the RegriddedScienceFrame
dependency does.
- select(cls, **searchterms) from common.database.DBMeta.DBObjectMeta
- Polymorphs the standard select() found in ProcessTarget (it is
extended by adding a filter to remove older AstrometricParameters
derived from the same RawScienceFrame).
Data descriptors defined here:
- CD1_1
- Linear transformation matrix parameter at i,j=1,1 (a1) [None]
- CD1_2
- Linear transformation matrix parameter at i,j=1,2 (a2) [None]
- CD2_1
- Linear transformation matrix parameter at i,j=2,1 (b1) [None]
- CD2_2
- Linear transformation matrix parameter at i,j=2,2 (b2) [None]
- CRPIX1
- Reference pixel in X [pixel]
- CRPIX2
- Reference pixel in Y [pixel]
- CRVAL1
- Physical value of the reference pixel X [deg]
- CRVAL2
- Physical value of the reference pixel Y [deg]
- CTYPE1
- Pixel coordinate system and projection of first axis (X) [None]
- CTYPE2
- Pixel coordinate system and projection of second axis (Y) [None]
- FITERRS
- Errors on fitted parameters [(deg, arcsec, pixel), None]
- FITPARMS
- Degrees of freedom of fitted parameters [None]
- MEAN_DDEC
- Average residual w.r.t. reference catalog: DEC [arcsec]
- MEAN_DDEC_OVERLAP
- Average residual w.r.t. overlap positions: DEC [arcsec]
- MEAN_DRA
- Average residual w.r.t. reference catalog: RA [arcsec]
- MEAN_DRA_OVERLAP
- Average residual w.r.t. overlap positions: RA [arcsec]
- NFITPARM
- Number of fitted parameters [None]
- NO_SOLUTION_FOUND
- No formal solution found, using original astrometric values.
- NREF
- Number of matched pairs of reference stars [None]
- NREF_TOO_HIGH
- There are too many reference stars.
- NREF_TOO_LOW
- There are too few reference stars.
- N_OVERLAP
- Number of matched pairs of overlapping stars [None]
- N_OVERLAP_TOO_HIGH
- There are too many overlap stars.
- N_OVERLAP_TOO_LOW
- There are too few overlap stars.
- PREASTROM_FAILED
- Preastrom failed with default settings and less stringent settings had to be used.
- PV1_0
- Non-linear transformation matrix Parameter value a0 [None]
- PV1_1
- Non-linear transformation matrix Parameter value b11 [None]
- PV1_10
- Non-linear transformation matrix Parameter value b110 [None]
- PV1_2
- Non-linear transformation matrix Parameter value b12 [None]
- PV1_3
- Non-linear transformation matrix Parameter value b13 [None]
- PV1_4
- Non-linear transformation matrix Parameter value b14 [None]
- PV1_5
- Non-linear transformation matrix Parameter value b15 [None]
- PV1_6
- Non-linear transformation matrix Parameter value b16 [None]
- PV1_7
- Non-linear transformation matrix Parameter value b17 [None]
- PV1_8
- Non-linear transformation matrix Parameter value b18 [None]
- PV1_9
- Non-linear transformation matrix Parameter value b19 [None]
- PV2_0
- Non-linear transformation matrix Parameter value c0 [None]
- PV2_1
- Non-linear transformation matrix Parameter value d11 [None]
- PV2_10
- Non-linear transformation matrix Parameter value d110 [None]
- PV2_2
- Non-linear transformation matrix Parameter value d12 [None]
- PV2_3
- Non-linear transformation matrix Parameter value d13 [None]
- PV2_4
- Non-linear transformation matrix Parameter value d14 [None]
- PV2_5
- Non-linear transformation matrix Parameter value d15 [None]
- PV2_6
- Non-linear transformation matrix Parameter value d16 [None]
- PV2_7
- Non-linear transformation matrix Parameter value d17 [None]
- PV2_8
- Non-linear transformation matrix Parameter value d18 [None]
- PV2_9
- Non-linear transformation matrix Parameter value d19 [None]
- RMS
- Two-dimensional Root-Mean-Square (RMS) of the RA/DEC residuals [arcsec]
- RMS_HAS_INCREASED
- RMS increased compared to previous version.
- RMS_OVERLAP
- Two-dimensional Root-Mean-Square (RMS) of the RA/DEC overlap residuals [arcsec]
- RMS_OVERLAP_HAS_INCREASED
- RMS_OVERLAP has increased compared to previous version.
- RMS_OVERLAP_TOO_HIGH
- Overlap RMS too high.
- RMS_TOO_HIGH
- RMS too high.
- SEEING
- The derived seeing [arcsec]
- SIGMA_HAS_INCREASED
- SIG_DRA or SIG_DDEC have increased compared to previous version.
- SIGMA_OVERLAP_HAS_INCREASED
- SIG_DRA_OVERLAP or SIG_DDEC_OVERLAP have increased compared to previous version.
- SIGMA_OVERLAP_TOO_HIGH
- SIG_DRA_OVERLAP or SIG_DDEC_OVERLAP is too high.
- SIGMA_TOO_HIGH
- SIG_DRA or SIG_DDEC is too high.
- SIG_DDEC
- Standard deviation of DEC residuals [arcsec]
- SIG_DDEC_OVERLAP
- Standard deviation of DEC residuals [arcsec]
- SIG_DRA
- Standard deviation of RA residuals [arcsec]
- SIG_DRA_OVERLAP
- Standard deviation of RA residuals [arcsec]
- associateconf
- The associate configuration [None]
- astromconf
- The astrom configuration [None]
- chip
- Information about the chip [None]
- creation_date
- Date this object was created [None]
- field_err
- Global position error [arcsec]
- filter
- Information about the filter [None]
- gastrom
- The Global Astrometric solution [None]
- instrument
- Information about the instrument [None]
- is_valid
- Manual/external flag to disqualify bad data (SuperFlag) [None]
- object_id
- The object identifier
The object identifier is an attribute shared by all persistent
instances. It is the prime key, by which object identity is established
- observing_block
- Information about the observing block [None]
- preastromconf
- The preastrom configuration [None]
- process_params
- Processing parameters [None]
- process_status
- A flag indicating the processing status [None]
- quality_flags
- Automatic/internal quality flag [None]
- reduced
- The input reduced science frame [None]
- refcat_slid
- The SLID of the SourceList used for the reference catalog [None]
- residuals
- Filename of residuals catalog [None]
- sexconf
- The SExtractor configuration [None]
- template
- Information about the template [None]
- x_err
- Error in polynomial x coefficient [arcsec]
- xx_err
- Error in polynomial xx coefficient [arcsec]
- xy_err
- Error in polynomial xy coefficient [arcsec]
- y_err
- Error in polynomial y coefficient [arcsec]
- yy_err
- Error in polynomial yy coefficient [arcsec]
Data and other attributes defined here:
- PROCESS_TIME = 40
- mandatory_dependencies = (('reduced', 1),)
Methods inherited from common.database.DBMain.DBObject:
- __del__(self)
- Destructor for the DBObject
This destructor is called by the garbage collector for the transient
part of the DBObject. When it is called it calls the gc_transient()
method of the DBProxy implementation. The implementation of the
gc_transient() method can then decide what to do with the persistent
counterpart.
E.g. the database can be synchronized with its transient counterpart.
Another possibility is that the gc_transient() implementation checks
whether any attributes of a read-only object have changed since an
object was fetched from the database. If there are differences an
exception can be raised.
- __reduce__(self)
- Method necessary to create picklable objects
This mehod return a tuple containg a function object used for
unpickling and a picklable state tuple, to be used as argument
to the unpickle function. If necessary this object is registered
in the pickle cache
- as_dict(self, seqnr=1, dependency_name='', dictionary={}, allow_lazy_typed_list=False)
- Method much like the info method, but returns a dictionary.
Dictionary looks like:
{'<classname>.<property1_name>.<property2_name>': value,
'<classname>.<property2_name>.<property3_name>': value}
Problem: infinite loops for cold/flat dependencies. It seems a maximum
recursion depth limits the problem.
- get_creator(self)
- Returns the name of the user who created this object.
- get_persistent(self)
- get_project(self)
- Returns the name of the project to which this object belongs.
- info(self, level=0, doc=False, _indent=0, _printclass=True)
- Print the values of all persistent properties of the object.
level : level of introspection
doc : display docstrings for attributes
_indent : internal parameter used for formatting
_printclass : internal parameter used for formatting
- inverse_objects(self, max_results=100)
- Iterate through and return all objects that use the current object
max_results The maximum number of objects returned per query
- inverse_query(self)
- go through all inverse properties to see if this object is used
- persists(self)
- Returns whether an object is already made persistent or transient.
- recommit(self)
- Commits changes to an object, without following links.
Class methods inherited from common.database.DBMain.DBObject:
- get_inverse_properties(cls, props=None) from common.database.DBMeta.DBObjectMeta
- return all inverse properties
that are all the properties that point to this class
Data descriptors inherited from common.database.DBMain.DBObject:
- __dict__
- dictionary for instance variables (if defined)
- __weakref__
- list of weak references to the object (if defined)
Data and other attributes inherited from common.database.DBMain.DBObject:
- __metaclass__ = <class 'common.database.DBMeta.DBObjectMeta'>
- This is the metaclass for persistent classes
Provides:
__new__ -- manages class construction
__call__ -- manages object instantiation
- database = <common.database.DBOracle.DBProxy instance at 0xe73d88>
- pickle_id = None
Methods inherited from astro.main.ProcessTarget.ProcessTarget:
- check_mandatory_dependencies(self)
- check if all the mandatory dependencies are set
- check_observing_blocks(self, childs)
- check if all childs have the same observing_block
- check_templates(self, childs)
- check if all childs have the same template
- get_dependencies(self)
- Return a list of names of attributes that are required for make()
- get_qcflags_set(self)
- Return a list of names of flags that have been set.
- get_qcflags_set_dict(self)
- Return a dictionary of flags that have been set. The key is the
name, the value is a tuple of (index, docstring).
- is_compared(self)
- Return true if the object has been compared
- is_inspected(self)
- Return true if the object has been inspected
- is_made(self)
- Return true if the object has been made
- is_ok(self)
- Return true if no quality control flags have been set.
- is_verified(self)
- Return true if the object has been verified
- set_compared(self)
- Set the process status to indicate that the object has been
compared.
- set_inspected(self)
- Set the process status to indicate that the object has been
inspected.
- set_made(self)
- Set the process tatus to indicate that the object has been made
- set_process_parameters_from_dict(self, pars={})
- pars is a dictionary of the type e.g.:
{'BiasFrame.process_params.SIGMA_CLIP':8}
- set_user_config(self, user_config_dict)
- Store the user specified configuration (as produced e.g. by the
util.Pars tool) in a transient attribute.
- set_verified(self)
- Set the process status to indicate that the object has been
verified.
Class methods inherited from astro.main.ProcessTarget.ProcessTarget:
- get_qcflags(cls) from common.database.DBMeta.DBObjectMeta
- Return a list of attribute names of QCflag() objects.
- is_cal(cls) from common.database.DBMeta.DBObjectMeta
- Test for being cal, derived raw classes should set _IS_CAL to 1
- is_config(cls) from common.database.DBMeta.DBObjectMeta
- Test for being config, derived raw classes should set _IS_CONFIG
to 1
- is_raw(cls) from common.database.DBMeta.DBObjectMeta
- Test for being raw, derived raw classes should set _IS_RAW to 1
- is_science(cls) from common.database.DBMeta.DBObjectMeta
- Test for being science, derived raw classes should set _IS_SCIENCE
to 1
- is_seq(cls) from common.database.DBMeta.DBObjectMeta
- Test for being seq, derived raw classes should set _IS_SEQ to 1
- is_support(cls) from common.database.DBMeta.DBObjectMeta
- Test for being config, derived raw classes should set _IS_SUPPORT
to 1
- select_for_raw(cls, raw, overscan=None, check_quality=1, check_validity=1) from common.database.DBMeta.DBObjectMeta
- Class method to select the most recent valid calfile for the
provided raw frame from the database.
- select_for_reduced(cls, reduced, overscan=None, check_quality=1, check_validity=1) from common.database.DBMeta.DBObjectMeta
- Synonym for the select_for_raw method; the implementation should
be identical.
Data and other attributes inherited from astro.main.ProcessTarget.ProcessTarget:
- STATUS_COMPARE = 2
- STATUS_INSPECT = 3
- STATUS_MAKE = 0
- STATUS_VERIFY = 1
Class methods inherited from common.database.DBMeta.DBMixin:
- get_persistent_attributes(cls) from common.database.DBMeta.DBObjectMeta
- return a list of persistent attributes
Methods inherited from astro.main.OnTheFly.OnTheFly:
- Flagged(self)
- Check if any flag is set
return 1 for flag is set
return 0 no flag
- after_set_onthefly_dependencies(self, switches, advanced)
- this method is called after the onthefly method set_onthefly_dependencies
derived classes can implement this method to customize the dependencies
setting after this has been done automatically by onthefly
- after_uptodate_object(self, dependencies_missing, dependencies_new, dependencies_obsolete)
- The uptodate_object method determines if the object is uptodate, and will result in three listings :
dependencies_missing - missing mandatory dependencies
dependencies_new - new dependencies
dependencies_obsolete - current dependencies that are obsolete
Derived classes can override this method to tweak the listings
- check_for_mandatory(self, dep_str, dep_new)
- check if dependency is mandatory and present
dep_str is the name of the attribute, dep_new is the (attribute) object
- get_onthefly_dependencies(self, advanced=None)
- Method retrieves a list of all dependencies used for
on-the-fly processing
Return: [dependency, dependency class, dependency name]
- uptodate(self, date_time=None, template=None, switches=None, advanced=None)
- This method checks if the object is up-to-date, for the given datetime.
OnTheFly_uptodate class has the functionality for checking uptodate
Class methods inherited from astro.main.OnTheFly.OnTheFly:
- get_onthefly(cls, date_time=None, filter=None, chip=None, object_id=None, advanced=None, switches=None, template=None, parent=None, parent_attr=None) from common.database.DBMeta.DBObjectMeta
- For the given parameters and class get the object,
if the object does not exist -> make it.
This is done recursively for all dependencies.
The object can only be made if there are raws
|
class AstrometricParametersParameters(common.database.DBMain.DBObject) |
| |
Processing parameters for AstrometricParameters
Procecessing parameters determine how the object is to be created
and the quality control (QC) limits for the newly created object. |
| |
- Method resolution order:
- AstrometricParametersParameters
- common.database.DBMain.DBObject
- __builtin__.object
Data descriptors defined here:
- MAX_NREF
- QC: Maximum number of reference star pairs [None]
- MAX_N_OVERLAP
- QC: Maximum number of reference star pairs [None]
- MAX_RMS
- QC: Maximum internal RMS of residuals [arcsec]
- MAX_RMS_OVERLAP
- QC: Maximum internal RMS of overlap residuals [arcsec]
- MAX_SIGMA
- QC: Maximum value of SIG_DRA or SIG_DDEC [arcsec]
- MAX_SIGMA_OVERLAP
- QC: Maximum value of SIG_DRA or SIG_DDEC for overlaps [arcsec]
- MIN_NREF
- QC: Minimum number of reference star pairs [None]
- MIN_N_OVERLAP
- QC: Minimum number of overlap star pairs [None]
- SOURCE_CODE_VERSION
- The version of the source code [None]
- object_id
- The object identifier
The object identifier is an attribute shared by all persistent
instances. It is the prime key, by which object identity is established
Methods inherited from common.database.DBMain.DBObject:
- __del__(self)
- Destructor for the DBObject
This destructor is called by the garbage collector for the transient
part of the DBObject. When it is called it calls the gc_transient()
method of the DBProxy implementation. The implementation of the
gc_transient() method can then decide what to do with the persistent
counterpart.
E.g. the database can be synchronized with its transient counterpart.
Another possibility is that the gc_transient() implementation checks
whether any attributes of a read-only object have changed since an
object was fetched from the database. If there are differences an
exception can be raised.
- __reduce__(self)
- Method necessary to create picklable objects
This mehod return a tuple containg a function object used for
unpickling and a picklable state tuple, to be used as argument
to the unpickle function. If necessary this object is registered
in the pickle cache
- as_dict(self, seqnr=1, dependency_name='', dictionary={}, allow_lazy_typed_list=False)
- Method much like the info method, but returns a dictionary.
Dictionary looks like:
{'<classname>.<property1_name>.<property2_name>': value,
'<classname>.<property2_name>.<property3_name>': value}
Problem: infinite loops for cold/flat dependencies. It seems a maximum
recursion depth limits the problem.
- commit(self)
- Commits object including objects that are referenced and have been changed.
If this object refers to other persistent object a commit() ensures that
1. ALL changes to the object and referred objects are made persistent.
2. NONE of the changed object and referred objects are made persistent.
Under normal circumstances only the first thing should ever happen.
If the second case occurs it is almost certainly because of some bug in
the routine that implements the DBProxy interface.
- get_creator(self)
- Returns the name of the user who created this object.
- get_persistent(self)
- get_project(self)
- Returns the name of the project to which this object belongs.
- info(self, level=0, doc=False, _indent=0, _printclass=True)
- Print the values of all persistent properties of the object.
level : level of introspection
doc : display docstrings for attributes
_indent : internal parameter used for formatting
_printclass : internal parameter used for formatting
- inverse_objects(self, max_results=100)
- Iterate through and return all objects that use the current object
max_results The maximum number of objects returned per query
- inverse_query(self)
- go through all inverse properties to see if this object is used
- persists(self)
- Returns whether an object is already made persistent or transient.
- recommit(self)
- Commits changes to an object, without following links.
Class methods inherited from common.database.DBMain.DBObject:
- get_inverse_properties(cls, props=None) from common.database.DBMeta.DBObjectMeta
- return all inverse properties
that are all the properties that point to this class
Data descriptors inherited from common.database.DBMain.DBObject:
- __dict__
- dictionary for instance variables (if defined)
- __weakref__
- list of weak references to the object (if defined)
Data and other attributes inherited from common.database.DBMain.DBObject:
- __metaclass__ = <class 'common.database.DBMeta.DBObjectMeta'>
- This is the metaclass for persistent classes
Provides:
__new__ -- manages class construction
__call__ -- manages object instantiation
- database = <common.database.DBOracle.DBProxy instance at 0xe73d88>
- pickle_id = None
| |