Package gavo :: Package stc :: Module syslib
[frames] | no frames]

Module syslib

source code

Arnold Rots' "library" of standard systems.

There's a dictionary of STC-S definitions of the systems that are compiled and memoized on demand. Thus, use the getLibrarySystem function below exclusively to access this content.

If and when there are additional library systems, you need to amend sysdefs.

Functions
 
getLibrarySystem(*args)
returns a dm.CoordSys instance for sysId.
source code
 
stripIVOID(sysId)
returns sysId with the STC IVOID root removed.
source code
Variables
  STC_IVOID = 'ivo://STClib/CoordSys'
  SYSDEFS = {'TDB-FK5-BARY': 'Time TDB BARYCENTER Position FK5 B...
  __package__ = 'gavo.stc'
Function Details

getLibrarySystem(*args)

source code 

returns a dm.CoordSys instance for sysId.

sysId may be the full IVOID or just the fragment. Unknown sysIds result in NotFoundErrors. Results are memoized, so make sure you do not mess with what you are returned.

Decorators:
  • @utils.memoized

stripIVOID(sysId)

source code 

returns sysId with the STC IVOID root removed.

If sysId does not start with the STC IVOID, it is returned unchanged.


Variables Details

SYSDEFS

Value:
{'TDB-FK5-BARY': 'Time TDB BARYCENTER Position FK5 BARYCENTER',
 'TDB-ICRS-BARY': 'Time TDB BARYCENTER Position ICRS BARYCENTER',
 'TT-FK5-GEO': 'Time TT GEOCENTER Position FK5 GEOCENTER',
 'TT-FK5-TOPO': 'Time TT TOPOCENTER Position FK5 TOPOCENTER',
 'TT-ICRS-BARY': 'Time TT BARYCENTER Position ICRS BARYCENTER',
 'TT-ICRS-GEO': 'Time TT GEOCENTER Position ICRS GEOCENTER',
 'TT-ICRS-HZ-TOPO': 'Time TT TOPOCENTER Position ICRS TOPOCENTER SPHER\
2 Spectral TOPOCENTER unit Hz',
...