Discussion:
[Numpy-discussion] Multiarray API size mismatch 301 302?
Sebastian Berg
2015-08-13 18:34:24 UTC
Permalink
Hey,

just for hacking/testing, I tried to add to shape.c:


/*NUMPY_API
*
* Checks if memory overlap exists
*/
NPY_NO_EXPORT int
PyArray_ArraysShareMemory(PyArrayObject *arr1, PyArrayObject *arr2, int
work) {
return solve_may_share_memory(arr1, arr2, work);
}



and to numpy_api.py:

# End 1.10 API
'PyArray_ArraysShareMemory': (301,),


But I am getting the error:

File "numpy/core/code_generators/generate_numpy_api.py", line 230, in
do_generate_api
(len(multiarray_api_dict), len(multiarray_api_index)))
AssertionError: Multiarray API size mismatch 301 302

It is puzzling me, so anyone got a quick idea?

- Sebastian
Benjamin Root
2015-08-13 18:36:31 UTC
Permalink
Did you do a "git clean -fxd" before re-installing?
Post by Sebastian Berg
Hey,
/*NUMPY_API
*
* Checks if memory overlap exists
*/
NPY_NO_EXPORT int
PyArray_ArraysShareMemory(PyArrayObject *arr1, PyArrayObject *arr2, int
work) {
return solve_may_share_memory(arr1, arr2, work);
}
# End 1.10 API
'PyArray_ArraysShareMemory': (301,),
File "numpy/core/code_generators/generate_numpy_api.py", line 230, in
do_generate_api
(len(multiarray_api_dict), len(multiarray_api_index)))
AssertionError: Multiarray API size mismatch 301 302
It is puzzling me, so anyone got a quick idea?
- Sebastian
_______________________________________________
NumPy-Discussion mailing list
http://mail.scipy.org/mailman/listinfo/numpy-discussion
Sebastian Berg
2015-08-13 18:42:17 UTC
Permalink
Post by Benjamin Root
Did you do a "git clean -fxd" before re-installing?
Yup.
Post by Benjamin Root
On Thu, Aug 13, 2015 at 2:34 PM, Sebastian Berg
Hey,
/*NUMPY_API
*
* Checks if memory overlap exists
*/
NPY_NO_EXPORT int
PyArray_ArraysShareMemory(PyArrayObject *arr1, PyArrayObject *arr2, int
work) {
return solve_may_share_memory(arr1, arr2, work);
}
# End 1.10 API
'PyArray_ArraysShareMemory': (301,),
File "numpy/core/code_generators/generate_numpy_api.py", line 230, in
do_generate_api
(len(multiarray_api_dict), len(multiarray_api_index)))
AssertionError: Multiarray API size mismatch 301 302
It is puzzling me, so anyone got a quick idea?
- Sebastian
_______________________________________________
NumPy-Discussion mailing list
http://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
http://mail.scipy.org/mailman/listinfo/numpy-discussion
Sebastian Berg
2015-08-13 20:13:26 UTC
Permalink
So as Julian helped me, it was the wrong style of the function, the
curly bracket has to go on the next line for the API generation to pick
it up.

- Sebastian
Post by Sebastian Berg
Post by Benjamin Root
Did you do a "git clean -fxd" before re-installing?
Yup.
Post by Benjamin Root
On Thu, Aug 13, 2015 at 2:34 PM, Sebastian Berg
Hey,
/*NUMPY_API
*
* Checks if memory overlap exists
*/
NPY_NO_EXPORT int
PyArray_ArraysShareMemory(PyArrayObject *arr1, PyArrayObject *arr2, int
work) {
return solve_may_share_memory(arr1, arr2, work);
}
# End 1.10 API
'PyArray_ArraysShareMemory': (301,),
File "numpy/core/code_generators/generate_numpy_api.py", line 230, in
do_generate_api
(len(multiarray_api_dict), len(multiarray_api_index)))
AssertionError: Multiarray API size mismatch 301 302
It is puzzling me, so anyone got a quick idea?
- Sebastian
_______________________________________________
NumPy-Discussion mailing list
http://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
http://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
http://mail.scipy.org/mailman/listinfo/numpy-discussion
Loading...