<html><div style='background-color:'><DIV></DIV>
<P>Dear Friends,</P>
<P>I am using Numeric 23.0 version&nbsp;and python 2.3 on a windows XP machine. I have build GDAL from MS VC++ and Visual Studio .net and installed on my machine. The GDAL version is 1.1.9.<BR></P>
<P>Basic Problem : I am trying to save a Numpy array(infact the primary issue is to save any 2d array (not just NUMPY)&nbsp;to a "TIF" file) to a TIF file. When I run the following commands, I get an error stating that it cannot access Numpy array of typecode "@"&nbsp; (weird..??)<BR></P>
<P>DUMP OF PYTHON INTERPRETER.</P>
<P>&gt;&gt;&gt; k = Numeric.zeros((2,2),"f")</P>
<P>&gt;&gt;&gt; k<BR>array([[ 0.,&nbsp; 0.],<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; [ 0.,&nbsp; 0.]],'f')&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; // I have tried with array k = array([[1.2, 2.3], [2.5,1.7]],"f")</P>
<P><BR>&gt;&gt;&gt; import gdalnumeric</P>
<P>&gt;&gt;&gt; gdalnumeric.SaveArray(k,"k.tif")<BR>ERROR 1: Unable to access numpy arrays of typecode <A href="mailto:`@'">`@'</A>.</P>
<P>Traceback (most recent call last):<BR>&nbsp; File "&lt;stdin&gt;", line 1, in ?<BR>&nbsp; File "C:\GDAL\pymod\gdalnumeric.py", line 97, in SaveArray<BR>&nbsp;&nbsp;&nbsp; return driver.CreateCopy( filename, OpenArray(src_array,prototype) )<BR>&nbsp; File "C:\GDAL\pymod\gdal.py", line 330, in CreateCopy<BR>&nbsp;&nbsp;&nbsp; target_ds = _gdal.GDALCreateCopy( self._o, filename, source_ds._o,<BR>AttributeError: 'NoneType' object has no attribute '_o'</P>
<P>---- END OF PYTHON INTERPRETER</P>
<P>I am wondering whether this is a version problem with Numeric python or is it a problem with the building of GDAL using MS VC++ 7.0&nbsp; or is it something else. I would be delighted if any one can give me&nbsp;clues on how to save a 2d array to a TIF file, since thats&nbsp;the primary problem.</P>
<P>Thanks</P>
<P>Gagan Tandon</P>
<DIV>
<P></P></DIV>
<HR>

<DIV></DIV>
<DIV></DIV>
<HR>

<DIV></DIV>
<P></P>
<DIV></DIV>
<P>Gagan Tandon<BR>Research Assistant<BR>GIS and Remote Sensing<BR>Colorado State University&nbsp;</P>
<DIV></DIV>
<DIV></DIV>
<P>
<DIV></DIV>
<HR>

<DIV></DIV>
<DIV></DIV>
<HR></div><br clear=all><hr>Attention all artisans! Sell Diwali creations online. <a href="http://g.msn.com/8HMAENIN/2734??PS=">Register now!</a> </html>