@@ -1333,7 +1333,7 @@ build_cntr_list_v(long *np, double *xp, double *yp, int nparts, long ntotal)
13331333{
13341334 PyObject * point , * all_contours ;
13351335 PyArrayObject * xv , * yv ;
1336- int dims [1 ];
1336+ npy_intp dims [1 ];
13371337 int i ;
13381338 long j , k ;
13391339
@@ -1343,8 +1343,8 @@ build_cntr_list_v(long *np, double *xp, double *yp, int nparts, long ntotal)
13431343 for (i = 0 ; i < nparts ; i ++ )
13441344 {
13451345 dims [0 ] = np [i ];
1346- xv = (PyArrayObject * ) PyArray_FromDims (1 , dims , PyArray_DOUBLE );
1347- yv = (PyArrayObject * ) PyArray_FromDims (1 , dims , PyArray_DOUBLE );
1346+ xv = (PyArrayObject * ) PyArray_SimpleNew (1 , dims , PyArray_DOUBLE );
1347+ yv = (PyArrayObject * ) PyArray_SimpleNew (1 , dims , PyArray_DOUBLE );
13481348 if (xv == NULL || yv == NULL ) goto error ;
13491349 for (j = 0 ; j < dims [0 ]; j ++ )
13501350 {
@@ -1370,7 +1370,7 @@ build_cntr_list_v2(long *np, double *xp, double *yp, int nparts, long ntotal)
13701370{
13711371 PyObject * all_contours ;
13721372 PyArrayObject * xyv ;
1373- int dims [2 ];
1373+ npy_intp dims [2 ];
13741374 int i ;
13751375 long j , k ;
13761376
@@ -1381,7 +1381,7 @@ build_cntr_list_v2(long *np, double *xp, double *yp, int nparts, long ntotal)
13811381 {
13821382 dims [0 ] = np [i ];
13831383 dims [1 ] = 2 ;
1384- xyv = (PyArrayObject * ) PyArray_FromDims (2 , dims , PyArray_DOUBLE );
1384+ xyv = (PyArrayObject * ) PyArray_SimpleNew (2 , dims , PyArray_DOUBLE );
13851385 if (xyv == NULL ) goto error ;
13861386 for (j = 0 ; j < dims [0 ]; j ++ )
13871387 {
0 commit comments