[Numpy-discussion] Numpy-discussion Digest, Vol 24, Issue 32

Catherine Moroney Catherine.M.Moroney@jpl.nasa....
Thu Sep 11 17:01:02 CDT 2008

I'm able to remove the file using python's "os" module, but
I still get an error when trying to create the file using
pyhdf, this time specifiying "SD.SDC.CREATE|SD.SDC.WRITE"
on the file-create line.

It's still complaining that it can't open the path, even though
the specified filename is valid.


On Sep 11, 2008, at 2:42 PM, numpy-discussion-request@scipy.org wrote:

>> What is the correct way to create an SD file (if it doesn't already
>> exist),
>> or truncate and then rewrite an existing one?
> I would suggest testing with os.path.exists() first, then deciding
> whether to use TRUNC or not based on that.
>> Does it matter which
>> order
>> the file-access options are set?
> No, the | operator is commutative.

More information about the Numpy-discussion mailing list