[Motmot] change in usage of imops.mono8_to_rgb8?

Andrew Straw astraw at caltech.edu
Tue Jul 21 17:59:42 UTC 2009


I have no time at this instant, but I just uploaded a new version of 
imops that should helpfully fix the problem. The upload went to PyPI and 
my ubuntu hardy i386 repo. I haven't uploaded the amd64 arch yet.

John Bender wrote:
> I've replicated this bug on Hardy 32-bit, but it ironically doesn't
> appear to be in Jaunty 64-bit. I recompiled imops from SVN revision
> 394 (on Mosca) the error went away. However, I had to mess around with
> the import statements and maybe the sys.path to get the compiled
> rather than the packaged imops. HTH!
>
> JB
>
> On Fri, Jul 17, 2009 at 1:09 PM, Floris van Breugel<florisvb at gmail.com> wrote:
>   
>> I can't claim to know much at all, but Andrew has been slowly adding color
>> support for his code, so perhaps that's why you're getting this now?
>>
>> - Floris
>>
>>
>>
>> On Fri, Jul 17, 2009 at 8:19 AM, Kristin Branson
>> <kristin at vision.caltech.edu> wrote:
>>     
>>> I'm getting an error using imops.mono_to_rgb8 that I hadn't been getting
>>> before.
>>>
>>> Here is code that reproduces the error:
>>>
>>> import numpy
>>> import motmot.imops.imops as imops
>>> image = numpy.zeros((100,200),dtype='uint8')
>>> out = imops.mono8_to_rgb8(image)
>>>
>>> Gives the error message:
>>>
>>> Traceback (most recent call last):
>>>   File "<stdin>", line 1, in <module>
>>>   File "imops.pyx", line 95, in imops.mono8_to_rgb8 (src/imops.c:1138)
>>> TypeError: must be uint8 arrays
>>>
>>> The original error appeared in Ctrax:
>>>
>>> Traceback (most recent call last):
>>>   File "/home/kristin/FLIES/code/Ctrax/Ctrax/settings.py", line 372, in
>>> OnSettingsBG
>>>     self.bg_imgs.DoSub()
>>>   File "/home/kristin/FLIES/code/Ctrax/Ctrax/bg.py", line 1284, in DoSub
>>>     self.img_wind.update_image_and_drawings('bg',img_8,format='MONO8')
>>>   File "/var/lib/python-support/python2.5/motmot/wxvideo/wxvideo.py", line
>>> 69, in update_image_and_drawings
>>>     rgb8 = imops.to_rgb8(format,image)
>>>   File "imops.pyx", line 356, in imops.to_rgb8 (src/imops.c:4147)
>>>   File "imops.pyx", line 95, in imops.mono8_to_rgb8 (src/imops.c:1138)
>>> TypeError: must be uint8 arrays
>>>
>>> This did not used to give an error. Am I using to_rgb8 incorrectly?
>>>
>>> Thanks!
>>> Kristin
>>>
>>> _______________________________________________
>>> Motmot mailing list
>>> Motmot at code.astraw.com
>>> http://code.astraw.com/cgi-bin/mailman/listinfo/motmot
>>>
>>>       
>>
>> --
>> Floris van Breugel
>> Caltech Graduate Student
>> Control and Dynamical Systems
>> (925) 963 8280
>>
>> Wildlife and Landscape Photographer
>> Galleries: http://www.ArtInNaturePhotography.com/
>> Blog: http://ArtInNature.wordpress.com/
>> 2010 CALENDARS! Now available on my website!
>>
>>
>> _______________________________________________
>> Motmot mailing list
>> Motmot at code.astraw.com
>> http://code.astraw.com/cgi-bin/mailman/listinfo/motmot
>>
>>
>>     
> _______________________________________________
> Motmot mailing list
> Motmot at code.astraw.com
> http://code.astraw.com/cgi-bin/mailman/listinfo/motmot
>
>   


-- 
Andrew D. Straw, Ph.D.
California Institute of Technology
http://www.its.caltech.edu/~astraw/



More information about the Motmot mailing list