summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
...
* Fixes something I broke in r13329. Didn't realize that siphdr was the ↵embray2011-07-111-4/+4
| | | | | | CardList and not a Header. Another example of the Header API being not great... git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@13332 fe389314-cf27-0410-b35b-8c050e845b92
* Forgot to update the other setup.cfgs when I change the version numbers in ↵embray2011-07-071-1/+1
| | | | | | pydrizzle and stsci.tools. I ought to write a tool for managing this. However, if we start using zest.releaser to do our releases it should be easier to manage... git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@13330 fe389314-cf27-0410-b35b-8c050e845b92
* Updated the headerlet module to work with the new version of pyfits in ↵embray2011-07-071-106/+73
| | | | | | trunk. Some additional minor cleanup. git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@13329 fe389314-cf27-0410-b35b-8c050e845b92
* Updated packages to use the svn_info hooks, and to get their version numbers ↵embray2011-07-072-11/+33
| | | | | | from pkg_resources. I only did this with packages that were already using __svn_version__, __full_svn_info__, etc. to begin with. git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@13327 fe389314-cf27-0410-b35b-8c050e845b92
* don't use private attributesdencheva2011-06-271-3/+3
| | | | git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@13266 fe389314-cf27-0410-b35b-8c050e845b92
* I'm not exactly sure where these temp dirs come from (they're generated at ↵embray2011-06-270-0/+0
| | | | | | some point during installation), but adding them to svn:ignore to get rid of 'svn status' noise. git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@13262 fe389314-cf27-0410-b35b-8c050e845b92
* Futher modified the main './setup.py install' command to use easy_install to ↵embray2011-06-271-1/+2
| | | | | | install each sub-distribution. This allows us to use the --no-deps option to skip dependency checking by each package, which eliminates a lot of installation noise. Instead, dependency checking is done just once at the very end of the process. Also explicitly added zip_safe=False to each distribution. This was already the case for most of them anyways, but making it explicit eliminates still more noise, and ensures that all our distributions are installed in a consistent manner. git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@13261 fe389314-cf27-0410-b35b-8c050e845b92
* Bumped the d2to1 version requirement. Also modified setup.py to run each ↵embray2011-06-231-1/+1
| | | | | | 'setup.py install' in its own process, which ends up working better when, for example, an older version of d2to1 or stsci.distutils is being replaced. git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@13242 fe389314-cf27-0410-b35b-8c050e845b92
* Redoing the r13221-13223 merge in the actual trunk now. This updates trunk ↵embray2011-06-2227-88/+617
| | | | | | to the setup_refactoring branch (however, coords, pysynphot, and pywcs are still being pulled from the astrolib setup_refactoring branch. Will have to do that separately then update the svn:externals) git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@13225 fe389314-cf27-0410-b35b-8c050e845b92
* Relatively minor update to wcsutil.altwcs to allow the alternate WCS methods ↵hack2011-06-161-6/+23
| | | | | | to work on simple FITS images as well as MEF files. WJH git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@13141 fe389314-cf27-0410-b35b-8c050e845b92
* Print statement in stwcs.distortion.mutil.readIDCtab() has been modified to ↵hack2011-06-141-2/+15
| | | | | | only print the names of non-CLEAR filters, for all instruments. This addresses concerns from the WFC3 team where this code reported finding an IDCTAB row for 'F606W and CLEAR'. These print statements may eventually be moved to only be printed to a log file, but for now, these format changes would still be used even after that move. git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@13125 fe389314-cf27-0410-b35b-8c050e845b92
* Headerlet.apply was not removing kw with reference files from the primary ↵dencheva2011-06-031-2/+14
| | | | | | header which resulted in kw duplication after the headerlet was applied. Added code which cleans the primary header before applying the headerlet. git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@13052 fe389314-cf27-0410-b35b-8c050e845b92
* Added a boolena keyword parameter 'createsummary' to Headerlet.apply to ↵dencheva2011-06-031-10/+15
| | | | | | allow applying a headerlet without creating and updating a wcscorr table. May be useful not only for testing ... git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@13051 fe389314-cf27-0410-b35b-8c050e845b92
* Addresses #713dencheva2011-06-031-7/+22
| | | | git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@13049 fe389314-cf27-0410-b35b-8c050e845b92
* Raise an error if input to HSTWCS is not a file name or a file objectdencheva2011-06-031-0/+3
| | | | git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@13048 fe389314-cf27-0410-b35b-8c050e845b92
* Added vafactor to SIPWCS headerlet extensions. Thi scompletes #710dencheva2011-06-031-0/+2
| | | | git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@13047 fe389314-cf27-0410-b35b-8c050e845b92
* Fixed r710dencheva2011-06-031-9/+17
| | | | git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@13046 fe389314-cf27-0410-b35b-8c050e845b92
* Make headerlets logging actually workdencheva2011-06-022-68/+80
| | | | git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@13000 fe389314-cf27-0410-b35b-8c050e845b92
* Initially the log file was defined at the top level. Moved it to updatewcs ↵dencheva2011-06-022-10/+6
| | | | | | to avoid creating an empty file when logging is not requested. git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@12996 fe389314-cf27-0410-b35b-8c050e845b92
* Minor update to wcscorr module to not try to create a WCSCORR table when ↵hack2011-05-111-0/+4
| | | | | | updating a simple FITS file. git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@12801 fe389314-cf27-0410-b35b-8c050e845b92
* Very minor change to the logic for determining when to add new rows to the ↵hack2011-05-041-1/+1
| | | | | | WCSCORR table to (try to) insure that the last row will always be blank for use in initializing the new empty rows which get added to the old table. git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@12718 fe389314-cf27-0410-b35b-8c050e845b92
* Further refinements to the WCSCORR code in STWCS to reduce the number of new ↵hack2011-05-031-6/+10
| | | | | | rows that gets added each time, and to maintain the same header information from one update to the next. git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@12715 fe389314-cf27-0410-b35b-8c050e845b92
* This update to STWCS includes the following revisions:hack2011-05-032-15/+18
| | | | | | | | | | | | | | - add EXTVER keyword to WCSCORR table extension in 'init_wcscorr()' - revised how pad rows are defined when creating a WCSCORR table - added logic to only work with NPOLFILE and D2IMFILE related keywords in input files that have been updated to use those reference files - added logic to only delete WCS's from IMAGE extensions to avoid problems of trying to delete a WCS from a table extension git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@12710 fe389314-cf27-0410-b35b-8c050e845b92
* A couple of small updates to STWCS.UPDATEWCS which avoid problems when ↵hack2011-04-292-1/+16
| | | | | | working with NICMOS and WFPC2 data; specifically, avoiding applying TDD correction to non-ACS data and updating the header with the UPWCSVER keyword when no HISTORY keywords are present. The changes were tested manually against ACS/WFC data (with and without TDD corrections), WFPC2 image, and a NICMOS image. git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@12684 fe389314-cf27-0410-b35b-8c050e845b92
* This update to the 'wcscorr' modele in STWCS.WCSUTIL fixes a problem with ↵hack2011-04-231-4/+4
| | | | | | initializing the WCSCORR table, and in fact, the entire header by archiving the original WCS values if no WCS with wcskey='O' has already been created. This affects the usage of the 'init_wcscorr()' function. git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@12589 fe389314-cf27-0410-b35b-8c050e845b92
* Updated the 'wcscorr' module in stwcs.wcsutil to define the number of new ↵hack2011-04-211-1/+1
| | | | | | rows (pad_rows) to add to the table when there are not enough to record the new WCS solutions. git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@12529 fe389314-cf27-0410-b35b-8c050e845b92
* Turn out pyfits doesn't really do anything helpful to automatically manage ↵embray2011-04-131-1/+6
| | | | | | extension version numbers (I should look into fixing that). This makes sure that each headerlet HDU appended to a file is given a sensible extension version by default. git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@12459 fe389314-cf27-0410-b35b-8c050e845b92
* Added explanation of the basic Headerlet API's current implementationembray2011-04-131-0/+125
| | | | git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@12458 fe389314-cf27-0410-b35b-8c050e845b92
* The logic for finding an empty (matching) row in ↵hack2011-04-121-3/+5
| | | | | | 'wcscorr.find_wcscorr_row()' was modified to strip blank characters from the end of each element before comparing. This allows the '==' comparison to actually match a blank string and find the rows to be filled. The fix allows the WFC3/IR demo datasets (8 WFC3/IR images) to be processed by betadrizzle. git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@12456 fe389314-cf27-0410-b35b-8c050e845b92
* Fixes `applyHeaderlet` and `Headerlet.apply()` use the hdrname keyword argembray2011-04-111-17/+11
| | | | | | | | | | sensibly. It allows users to specify a name for the headerlet generated from a file, but if hdrname is not specified a sensible default is still used. Removed support for the destim arg from `applyHeaderlet()`, as it was not used anywhere. git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@12446 fe389314-cf27-0410-b35b-8c050e845b92
* Corrected a syntax problem with one of the new exception calls in ↵hack2011-04-071-1/+1
| | | | | | 'update_wcscorr'. git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@12402 fe389314-cf27-0410-b35b-8c050e845b92
* `Headerlet.apply()` now appends the headerlet of the original WCS to the *end*embray2011-04-062-13/+28
| | | | | | | | | | | | of the file's HDU list. And it now also applies the new headerlet to the HDU list under that, and update's the WCSCORR table with rows for the WCSs in the new headerlet. This should achieve most of the basic requirements for headerlet functionality, though I still need to look into reversing the application of a headerlet... git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@12398 fe389314-cf27-0410-b35b-8c050e845b92
* Updated `update_wcscorr()` to be more flexible and general-purpose. It canembray2011-04-064-127/+196
| | | | | | | | | now apply WCS keywords to the WCSCORR table even from extensions in a different file from the one containing the WCSCORR table. This might break any existing code using either it, or `archive_wcs_file()`.` git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@12397 fe389314-cf27-0410-b35b-8c050e845b92
* Various cleanup and small bug fixes. In particular, init_wcscorr() now ↵embray2011-04-054-245/+305
| | | | | | works what I believe to be 'correctly'--it applies all existing WCSs from the SCI extension headers to the new WCSCORR table in the correct order (wcs_key w/ 'O' first; extver). git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@12393 fe389314-cf27-0410-b35b-8c050e845b92
* The HSTWCS method 'wcs2header' was modified to append the SIP and IDC ↵hack2011-04-052-16/+15
| | | | | | | | | | | | distortion model keywords to the header using the '.update()' method instead of extending the header with a CardList. This corrected a problem with the CardList not fully updating the original header making the appended cards unaccessible using the dictionary lookup syntax. The logic for using the 'readModel()' method of HSTWCS was also improved to not try and read the IDCModel when no 'idctab' had been specified in the header. Finally, a small bug was fixed in the 'wcscorr' module for recognizing what rows are available for being updated so that the update will actually occur. git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@12392 fe389314-cf27-0410-b35b-8c050e845b92
* Per Warren's suggestion, moved the wcscorr and convertwcs modules out of ↵embray2011-04-012-0/+454
| | | | | | betadrizzle and moved them into the stwcs.wcsutil package. Also cleaned up some imports and cleaned up some whitespace--might want to view this diff with ignore-whitespace. git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@12388 fe389314-cf27-0410-b35b-8c050e845b92
* * Added compression supportembray2011-04-011-26/+58
| | | | | | | | | | | * Had to add the standard NAXIS, BITPIX, etc. header keywords in order for pyfits to correctly determine the HeaderletHDU data size. * Added a monkey patch so that pyfits can recognize the HeaderletHDU type when opening a FITS file; naturally this module has to be imported for headerlet support to be available. git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@12387 fe389314-cf27-0410-b35b-8c050e845b92
* Headerlet work:embray2011-03-311-202/+355
| | | | | | | | | | | | | | | * Moved several functions into the Headerlet class * Started work on the HeaderletHDU class--this is a non-standard extension HDU type for representing the tarred headerlet file that is appended to a file that has that headerlet applied to it. I originally wanted the `HeaderletHDU.data` attribute to transparently return the Headerlet object itself (rather than a long binary string), but that doesn't work due to the way pyfits currently writes files. So instead the Headerlet object can be accessed from the `HeaderletHDU.headerlet` attribute. * Other miscellaneous cleanup git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@12346 fe389314-cf27-0410-b35b-8c050e845b92
* Some mostly trivial PEP8 pedantry.embray2011-03-291-158/+211
| | | | git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@12320 fe389314-cf27-0410-b35b-8c050e845b92
* Revised how 'output_wcs' computes the new WCS, specifically, correctly ↵hack2011-03-181-5/+6
| | | | | | accounting for the fact that the center computed on the sky is a zero-based computation, not a 1-based computation as assumed before. This eliminates the 1 pixel offset introduced when creating an output WCS with an input WCS which has no distortion model. git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@12260 fe389314-cf27-0410-b35b-8c050e845b92
* This update to the HSTWCS class in STWCS attempts to address a couple of ↵hack2011-03-171-4/+10
| | | | | | issues: namely, makes recognition of non-HST data more general (slightly) and only applies distortion model in all_sky2pix when it is present. The first change should allow HSTWCS to be run on data created with IRAF's artdata package/task. git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@12216 fe389314-cf27-0410-b35b-8c050e845b92
* Fixed a problem with TDDCorr handling in the 'zero_point_corr()' classmethod ↵hack2011-03-171-1/+2
| | | | | | in updatewcs.makewcs to allow WFC3 data (at least) process successfully. git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@12214 fe389314-cf27-0410-b35b-8c050e845b92
* revert r12062: put back all idc model keywords in the science headerdencheva2011-03-151-2/+1
| | | | git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@12194 fe389314-cf27-0410-b35b-8c050e845b92
* Added logging to headerletdencheva2011-03-141-19/+70
| | | | git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@12193 fe389314-cf27-0410-b35b-8c050e845b92
* temporary work around pyfits problem #48dencheva2011-03-141-7/+18
| | | | git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@12192 fe389314-cf27-0410-b35b-8c050e845b92
* Adding logging to updatewcsdencheva2011-03-118-43/+102
| | | | git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@12183 fe389314-cf27-0410-b35b-8c050e845b92
* Fixed a bug - wcskey was not defined when archiving a WCS and an alternate ↵dencheva2011-03-091-0/+1
| | | | | | WCS with this key already exists. git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@12134 fe389314-cf27-0410-b35b-8c050e845b92
* No code changes, only name changes - all occurences of 'dgeo' changed to 'npol'dencheva2011-03-075-359/+48
| | | | git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@12119 fe389314-cf27-0410-b35b-8c050e845b92
* Renamed dgeo to npoldencheva2011-03-071-0/+311
| | | | git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@12118 fe389314-cf27-0410-b35b-8c050e845b92
* revised tsrdencheva2011-03-031-1/+0
| | | | git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@12077 fe389314-cf27-0410-b35b-8c050e845b92