<p dir="auto"><em>Original ticket <a href="http://projects.scipy.org/numpy/ticket/772" rel="nofollow">http://projects.scipy.org/numpy/ticket/772</a> on 2008-05-07 by <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/alberts/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/alberts">@alberts</a>, assigned to unknown.</em></p>
<p dir="auto">Valgrind warning when running test for compress2d:</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="==14758== Conditional jump or move depends on uninitialised value(s)
==14758==    at 0x4330DB6: PyArray_MapIterReset (arrayobject.c:10190)
==14758==    by 0x437D85E: array_subscript (arrayobject.c:2549)
==14758==    by 0x437E491: array_subscript_nice (arrayobject.c:3173)
==14758==    by 0x80CC7BD: PyEval_EvalFrameEx (ceval.c:1207)
==14758==    by 0x80D0CA5: PyEval_EvalCodeEx (ceval.c:2908)
==14758==    by 0x80CF002: PyEval_EvalFrameEx (ceval.c:3741)
==14758==    by 0x80D04A2: PyEval_EvalFrameEx (ceval.c:3731)
==14758==    by 0x80D0CA5: PyEval_EvalCodeEx (ceval.c:2908)
==14758==    by 0x81235D5: function_call (funcobject.c:524)
==14758==    by 0x805BE24: PyObject_Call (abstract.c:2490)
==14758==    by 0x80CB503: PyEval_EvalFrameEx (ceval.c:3944)
==14758==    by 0x80D0CA5: PyEval_EvalCodeEx (ceval.c:2908)
==14758==    by 0x812350B: function_call (funcobject.c:524)
==14758==    by 0x805BE24: PyObject_Call (abstract.c:2490)
==14758==    by 0x8062C76: instancemethod_call (classobject.c:2558)
==14758==    by 0x805BE24: PyObject_Call (abstract.c:2490)
==14758==    by 0x80CBE34: PyEval_EvalFrameEx (ceval.c:3856)
==14758==    by 0x80D0CA5: PyEval_EvalCodeEx (ceval.c:2908)
==14758==    by 0x812350B: function_call (funcobject.c:524)
==14758==    by 0x805BE24: PyObject_Call (abstract.c:2490)"><pre class="notranslate"><code class="notranslate">==14758== Conditional jump or move depends on uninitialised value(s)
==14758==    at 0x4330DB6: PyArray_MapIterReset (arrayobject.c:10190)
==14758==    by 0x437D85E: array_subscript (arrayobject.c:2549)
==14758==    by 0x437E491: array_subscript_nice (arrayobject.c:3173)
==14758==    by 0x80CC7BD: PyEval_EvalFrameEx (ceval.c:1207)
==14758==    by 0x80D0CA5: PyEval_EvalCodeEx (ceval.c:2908)
==14758==    by 0x80CF002: PyEval_EvalFrameEx (ceval.c:3741)
==14758==    by 0x80D04A2: PyEval_EvalFrameEx (ceval.c:3731)
==14758==    by 0x80D0CA5: PyEval_EvalCodeEx (ceval.c:2908)
==14758==    by 0x81235D5: function_call (funcobject.c:524)
==14758==    by 0x805BE24: PyObject_Call (abstract.c:2490)
==14758==    by 0x80CB503: PyEval_EvalFrameEx (ceval.c:3944)
==14758==    by 0x80D0CA5: PyEval_EvalCodeEx (ceval.c:2908)
==14758==    by 0x812350B: function_call (funcobject.c:524)
==14758==    by 0x805BE24: PyObject_Call (abstract.c:2490)
==14758==    by 0x8062C76: instancemethod_call (classobject.c:2558)
==14758==    by 0x805BE24: PyObject_Call (abstract.c:2490)
==14758==    by 0x80CBE34: PyEval_EvalFrameEx (ceval.c:3856)
==14758==    by 0x80D0CA5: PyEval_EvalCodeEx (ceval.c:2908)
==14758==    by 0x812350B: function_call (funcobject.c:524)
==14758==    by 0x805BE24: PyObject_Call (abstract.c:2490)
</code></pre></div>
<p dir="auto">Found by Python 2.6 buildbot.</p>
<p dir="auto"><em>Original ticket <a href="http://projects.scipy.org/numpy/ticket/338" rel="nofollow">http://projects.scipy.org/numpy/ticket/338</a> on 2006-10-12 by <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/alberts/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/alberts">@alberts</a>, assigned to unknown.</em></p>
<p dir="auto">When running the following code:</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="#!python
import numpy as np
import scipy as sp
from scipy.interpolate import interp1d
print np.__version__                  
print sp.__version__
x10 = np.arange(10.)
y210 = np.arange(20.).reshape((2, 10))
interp210 = interp1d(x10, y210)
interp210(1.5)"><pre class="notranslate"><code class="notranslate">#!python
import numpy as np
import scipy as sp
from scipy.interpolate import interp1d
print np.__version__                  
print sp.__version__
x10 = np.arange(10.)
y210 = np.arange(20.).reshape((2, 10))
interp210 = interp1d(x10, y210)
interp210(1.5)
</code></pre></div>
<p dir="auto">Valgrind emits the following warning on 32-bit Linux:</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="==1076== Conditional jump or move depends on uninitialised value(s)
==1076==    at 0x4433E14: PyArray_MapIterReset (arrayobject.c:9684)
==1076==    by 0x44679F3: array_ass_sub (arrayobject.c:2442)
==1076==    by 0x4A1EA6B: PyObject_SetItem (in /usr/lib/libpython2.4.so.1.0)
==1076==    by 0x4A7D92C: PyEval_EvalFrame (in /usr/lib/libpython2.4.so.1.0)
==1076==    by 0x4A81757: PyEval_EvalCodeEx (in /usr/lib/libpython2.4.so.1.0)
..."><pre class="notranslate"><code class="notranslate">==1076== Conditional jump or move depends on uninitialised value(s)
==1076==    at 0x4433E14: PyArray_MapIterReset (arrayobject.c:9684)
==1076==    by 0x44679F3: array_ass_sub (arrayobject.c:2442)
==1076==    by 0x4A1EA6B: PyObject_SetItem (in /usr/lib/libpython2.4.so.1.0)
==1076==    by 0x4A7D92C: PyEval_EvalFrame (in /usr/lib/libpython2.4.so.1.0)
==1076==    by 0x4A81757: PyEval_EvalCodeEx (in /usr/lib/libpython2.4.so.1.0)
...
</code></pre></div>
<p dir="auto">Similar warning on 64-bit Linux:</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="==31596== Conditional jump or move depends on uninitialised value(s)
==31596==    at 0x571ACD0: PyArray_MapIterReset (arrayobject.c:9650)
==31596==    by 0x575CED0: array_ass_sub (arrayobject.c:2433)
==31596==    by 0x474080: PyEval_EvalFrame (in /usr/bin/python2.4)
==31596==    by 0x4783FE: PyEval_EvalCodeEx (in /usr/bin/python2.4)
..."><pre class="notranslate"><code class="notranslate">==31596== Conditional jump or move depends on uninitialised value(s)
==31596==    at 0x571ACD0: PyArray_MapIterReset (arrayobject.c:9650)
==31596==    by 0x575CED0: array_ass_sub (arrayobject.c:2433)
==31596==    by 0x474080: PyEval_EvalFrame (in /usr/bin/python2.4)
==31596==    by 0x4783FE: PyEval_EvalCodeEx (in /usr/bin/python2.4)
...
</code></pre></div>
<p dir="auto">Tested with Valgrind 3.1.0 and 3.2.1. Used !NumPy 1.0.dev3217 and !SciPy 0.5.2.dev2254 on 64-bit system. Used  !NumPy 1.0.dev3315 and !SciPy 0.5.2.dev2241 on 32-bit system.</p>