<html>
  <head>
    <meta content="text/html; charset=UTF-8" http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    On 5/8/2012 11:11 AM, Philip Tait wrote:
    <blockquote cite="mid:4fa953d2.4574b60a.76bc.ffffc485@mx.google.com"
      type="cite">Isn't this a known issue, fixed in 3.0.7?<br>
    </blockquote>
    <br>
    Thanks for the quick reply.  It is embarrassing to post a problem
    and not be using the latest release.  So I've downloaded/installed
    3.0.7.  Unfortunately, the same behavior persists (i.e., unwanted,
    silent conversion from 32 to 64 bit floats) as illustrated below:<br>
    <br>
    >>> import os<br>
    >>> import sys<br>
    >>> import pyfits<br>
    >>> sys.version<br>
    '2.6.4 (r264:75708, Oct 26 2009, 08:23:19) [MSC v.1500 32 bit
    (Intel)]'<br>
    >>> pyfits.__version__<br>
    '3.0.7'<br>
    >>> path = ...<br>
    >>> HDUs = pyfits.open (path,mode='readonly')<br>
    >>> HDUs['primary'].header['bitpix']<br>
    32<br>
    >>> HDUs['primary'].data.dtype<br>
    dtype('float64')<br>
    >>> HDUs['primary'].header['bitpix']<br>
    -64<br>
    >>> <br>
    <br>
    Is this a bug that should be reported?<br>
    <br>
    Thanks,<br>
    -- jv<br>
    <br>
    <br>
    <br>
    <br>
    <br>
    <br>
    <blockquote cite="mid:4fa953d2.4574b60a.76bc.ffffc485@mx.google.com"
      type="cite"><br>
      <span style="font-family:Prelude, Verdana, san-serif;"><br>
        <br>
      </span><span id="signature">
        <div style="font-family: arial, sans-serif; font-size:
          12px;color: #999999;">-- Sent from my HP Pre3</div>
        <br>
      </span><span style="color:navy; font-family:Prelude, Verdana,
        san-serif; ">
        <hr style="width:75%" align="left">On May 8, 2012 6:59, Jim
        Vickroy <a class="moz-txt-link-rfc2396E" href="mailto:jim.vickroy@noaa.gov"><jim.vickroy@noaa.gov></a> wrote: <br>
        <br>
      </span>Hi Pyfits users,
      <br>
      <br>
      Consider:
      <br>
      <br>
      >>> import pyfits
      <br>
      >>> pyfits.__version__
      <br>
      '3.0.5'
      <br>
      >>> path = ...
      <br>
      >>> HDUs = pyfits.open (path,mode='readonly')
      <br>
      >>> HDUs['primary'].header['bitpix']
      <br>
      32
      <br>
      >>> HDUs['primary'].data.dtype
      <br>
      dtype('float64')
      <br>
      >>> HDUs['primary'].header['bitpix']
      <br>
      -64
      <br>
      >>>
      <br>
      <br>
      Why is the conversion from 32 to 64 bit floats silently occurring?
      How <br>
      can I prevent it?
      <br>
      <br>
      Thanks,
      <br>
      -- jv
      <br>
      <br>
      _______________________________________________
      <br>
      AstroPy mailing list
      <br>
      <a class="moz-txt-link-abbreviated" href="mailto:AstroPy@scipy.org">AstroPy@scipy.org</a>
      <br>
      <a class="moz-txt-link-freetext" href="http://mail.scipy.org/mailman/listinfo/astropy">http://mail.scipy.org/mailman/listinfo/astropy</a>
      <br>
    </blockquote>
    <br>
  </body>
</html>