Skip to content
murmot

Results for “python numpy array example problem error java site:mail.python.org failed”

  • mail.python.org

    [Image-SIG] 16bit to 8bit conversion with a lut - mail.python.org

    Feb 7, 2007 · Here is the code that I am using to perform a look up table conversion from 16 bit imagery to 8 bit imagery. tif_image = "in.tif" #16 bit tiff image # create 65536 entry lut. All 255s for demonstration purposes lut = [] lut = [255] * 65536 print len (lut) # 65536, to make sure it is the right length im1 = Image.open (tif_image) print im1.mode # "I;16" im2 = im1.point (lut, "L") im2.save ("out ...

  • mail.python.org

    [Image-SIG] Problem with converting GeoTIFF to Numpy array...

    I am trying to read a GeoTIFF and convert it to a Numpy array. Though, I am > able to open the image with no problem, however I am keep getting > 'ValueError: unrecognised mode' anytime I try to use any methods from PIL's > classes. My lines and results are like this

  • mail.python.org

    [Tutor] Memory error - how to manage large data sets?

    Jul 29, 2008 · All its doing it gobbling up space. > else: > fib.append (i) dispense with the else and just put the fib append outside. ie your code becomes for i in xrange (0,1000000): # xranmge should avoid the extra list if i >= 2: i = fib [i-1] + fib [i-2] fib.append (i) > total = reduce (fibonacci,even) You could use the sum () function in Python 2.5 but ...

  • mail.python.org

    [Numpy-discussion] ragged array implimentation

    [Numpy-discussion] ragged array implimentation. Christopher Barker Chris.Barker at noaa.gov Mon Mar 7 13:42:00 EST 2011.In your example, the 'ragged' array would be a 1d numpy array with > dtype='O', and the individual elements would be 1d numpy arrays with > dtype=int.

  • mail.python.org

    [Python-Dev] Change in file () behavior in 2.5

    Sep 7, 2006 · This actually caught a bug in an application I work with, which used an explicit 'wU', that will currently stop working when people upgrade Python but not our application.

  • mail.python.org

    [Numpy-discussion] ValueError: objects are not aligned

    Previous message (by thread): [Numpy-discussion] ValueError: objects are not aligned.examples are in docstring for np.cov >. as for "stacking rf1 rf1 into a single array first" how would I do this? >>> np.column_stack([np.arange(3)[:,None], np.arange(3)[:,None]]) array([[0, 0]

  • mail.python.org

    [Python-3000] PySys_SetObject () crashes in secondary sub ...

    For early Python 3.0 alpha versions I had mod_wsgi working no problems. When I tried b3 it breaks for secondary sub interpreters. In particular, a call to PySys_SetObject () crashes. > From what I can tell so far the problem is that 'interp->sysdict' is NULL after calling Py_NewInterpreter () to create a secondary sub interpreter.

  • mail.python.org

    Mailman 3 Search results for "closing csv file in numpy ...

    I ran the tests using the `runtests.py` script: *seed+1000, using 'python runtests.py -n' in the source directory:* 236 failed, 12881 passed, 1248 skipped, 585 deselected, 84 xfailed, 7 xpassed Most of the failures are in scipy.stats: *seed+1000, using 'python runtests.py -n -s stats' in the source directory:* 203 failed, 1034 passed, 4 skipped ...