Introduction
pywcs is a set of routines for handling the FITS World Coordinate System (WCS) standard. It is a thin wrapper around the high- and mid-level interfaces of Dr. Mark Calabretta’s WCSLIB available here:
In addition, there are extensions (written in C) to support Spitzer Simple Imaging Polynomial (SIP) convention keywords and Paper IV table lookup distortion.
Please direct any questions to:
Build instructions
pywcs includes its own copy of WCSLIB.
pywcs requires:
Numpy 1.3 or later
pyfits 1.4 or later
pywcs uses the standard Python distutils system to build and install itself. From the command line run:
python setup.py install
to install pywcs.
Building documentation
Optionally, the documentation can be built using Sphinx (http://sphinx.pocoo.org).
After installing pywcs, ‘cd’ into the ‘doc’ directory and:
make html
The documentation is also available online at:
Version 1.11
NEW FEATURES:
Updated to wcslib version 4.8.2, which gives much more detailed error messages. Exceptions raised due to invalid WCS keywords should now be more informative.
Undefined values that are the result of p2s and s2p are now set to NaN. Previously, one had to examine the stat result vector to determine which results were invalid.
Added functions get_pc() and get_cdelt(). These provide a way to always get the canonical representation of the linear transformation matrix, whether the header specified it in PC, CD or CROTA form.
BROADER COMPATIBILITY:
Supports Python 3.x
Long-running process will now release the Python GIL to better support Python multithreading.
Builds on Microsoft Windows using mingw32, mingw64 and Visual Studio 9.0 and 10.0 without severely patching wcslib.
pywcs will now run without pyfits, though the SIP and distortion lookup table functionality is unavailable.
BUG FIXES:
The dimensions of the cd and pc matrices were formerly always returned as 2x2. They now are sized according to naxis.
MISCELLANEOUS:
Lots of new unit tests
Setting wcs.wcs.cunit will now verify that the values are valid unit strings.
Version 1.10
Adds a UnitConversion class, which gives access to wcslib’s unit conversion functionality. Given two convertible unit strings, pywcs can convert arrays of values from one to the other.
Now uses wcslib 4.7
Changes to some wcs values would not always calculate secondary values.
Version 1.9
Support binary image arrays and pixel list format WCS by presenting a way to call wcslib’s wcsbth()
Updated underlying wcslib to version 4.5, which fixes the following:
Fixed the interpretation of VELREF when translating AIPS-convention spectral types. Such translation is now handled by a new special- purpose function, spcaips(). The wcsprm struct has been augmented with an entry for velref which is filled by wcspih() and wcsbth(). Previously, selection by VELREF of the radio or optical velocity convention for type VELO was not properly handled.
BUGS:
The “pc” member is now available with a default “raw” Wcsprm object.
Make properties that return arrays read-only, since modifying a (mutable) array could result in secondary values not being recomputed based on those changes.
float properties can now be set using int values
Version 1.3a1
Earlier versions of pywcs had two versions of every conversion method:
X(…) – treats the origin of pixel coordinates at (0, 0) X_fits(…) – treats the origin of pixel coordinates at (1, 1)
From version 1.3 onwards, there is only one method for each conversion, with an ‘origin’ argument:
0: places the origin at (0, 0), which is the C/Numpy convention.
1: places the origin at (1, 1), which is the Fortran/FITS convention.
Metadata
Release files for pywcs 1.12
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distributions (sdists)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| pywcs-1.12.zip | 2.4 MB | Without provenance | Details for pywcs-1.12.zip | |
| pywcs-1.12.tar.gz | 2.0 MB | Without provenance | Details for pywcs-1.12.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| pywcs-1.12-py2.7-win32.egg | Legacy Egg format | - | - | Details for pywcs-1.12-py2.7-win32.egg |
Total release size: 4.9 MB
Release files / pywcs-1.12.zip
| Download URL | pywcs-1.12.zip |
|---|---|
| Size | 2.4 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
2e03507db144d5de97ea16a2ffa542314bf54034de9b81e9e056eb7ef852d85a
|
|
BLAKE2b-256 checksum How to use checksums |
b55cd80095a2a912892fb69cab93ad55148b21a12e9fec9f05b8d84b35aa5914
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Release files / pywcs-1.12.tar.gz
| Download URL | pywcs-1.12.tar.gz |
|---|---|
| Size | 2.0 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
fcd4a2ac9db4d1be6fe108f8d3bf2f0f1d6087e2dfa593ec112a6e207acbc1f4
|
|
BLAKE2b-256 checksum How to use checksums |
63a67b510ed55c68384731caa2411faf8dfed47b05cb46d9b1b4ba99e3b06587
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Release files / pywcs-1.12-py2.7-win32.egg
| Download URL | pywcs-1.12-py2.7-win32.egg |
|---|---|
| Size | 467.1 kB |
| Tags | Egg |
|
SHA-256 checksum How to use checksums |
037161bae2f4da4266c45b6ea9e6858a2073c5a08dce2ef19a8c5aafe3da75b5
|
|
BLAKE2b-256 checksum How to use checksums |
d493943c3b1a87c07e2aaa5e66e0b4c93bfb6a225f2481cbc954f07a71521af1
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for pywcs 1.12
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.