| Commit message (Collapse) | Author | Age | Files | Lines |
|\
| |
| | |
BUG: SWIG overloaded long functions on pyfragments.swg will seg fault
|
| |\ |
|
| | | |
|
| | | |
|
| |/
|/| |
|
| | |
|
| | |
|
| | |
|
| |
| |
| | |
https://github.com/numpy/numpy/issues/18521
|
| |
| |
| |
| | |
Replaces ``PyInt_Check`` and ``PyInt_AsLong`` in a few places.
|
| |
| |
| |
| | |
Closes #17398
|
|/
|
|
|
|
| |
Replace the npy_3kcompat PyString_Check with its definition. This is
done separately for the tools/swig/numpy.i file as it might be
problematic.
|
|
|
|
|
| |
resize typemap issue
python 3 bytes vs str issue
|
|
|
|
| |
Signed-off-by: Changqing Li <changqing.li@windriver.com>
|
|
|
|
|
|
|
| |
* Cleanup unused imports (F401) of mostly standard Python modules,
or some internal but unlikely referenced modules
* Where internal imports are potentially used, mark with noqa
* Avoid redefinition of imports (F811)
|
|
|
|
|
|
| |
* For external modules, resolve imported members
* Most internal relative modules were ignored or marked noqa: F403
* Convert a few internal absolute imports to relative imports
|
|\
| |
| | |
MAINT: Cleaning up PY_MAJOR_VERSION/PY_VERSION_HEX
|
| | |
|
|/
|
|
|
| |
As numpy is Python 3 only, these import statements are now unnecessary
and don't alter runtime behavior.
|
| |
|
| |
|
|
|
|
| |
See https://docs.python.org/2/library/unittest.html#deprecated-aliases
|
|
|
|
|
|
|
|
|
|
|
| |
* BUG: Fix memory leak in pyfragments.swg
Make sure to Py_DECREF the Py_ArrayDesc created in the definition of
SWIG_CanCastAsInteger for long and unsigned long.
Fixes #11876
* fixup! BUG: Fix memory leak in pyfragments.swg
|
|
|
|
|
|
|
|
|
|
| |
* MAINT: Replace print statements for Python3.
Updates tools/swig/test/testSuperTensor.py.
* MAINT: Fix deprecated escaped characters for python 3.6+.
Update numpy/linalg/lapack_lite/clapack_scrub.py.
|
| |
|
|
|
|
| |
Leave the flag if there's only one non unit dim
|
|
|
|
|
|
|
| |
Otherwise the returned array has both flags, which creates all sorts of confusing runtime behaviors.
C_CONTIGUOUS : True
F_CONTIGUOUS : True
Doesn't cause a crash, but some functions like copy() works in F_CONTIGUOUS others like element wise operators assume C_CONTIGUOUS, obviously this becomes a nightmare to debug.
|
| |
|
|
|
| |
numpy API < 1.7 does not support NPY_ARRAY_F_CONTIGUOUS.or PyArray_IS_F_CONTIGUOUS. Supporting old APIs is useful as users tend to ship modern numpy.i files to compile against possibly older numpy installations.
|
|
|
|
|
|
|
|
|
|
|
|
| |
are passed to a function accepting "unsigned int".
This a port of a fix in pyprimtype.swg from which several code snippets where copy pasted into swig/pyfragments.swg.
Please see SWIG changes log (2015-12-23) for more details:
http://www.swig.org/Release/CHANGES.current
2015-12-23: ahnolds [Python] Fixes for conversion of signed and unsigned integer types ...
|
| |
|
|
|
|
| |
Closes gh-6863.
|
|
|
|
|
|
|
|
| |
The function was calling PyArray_FromArray with NPY_FORTRANORDER instead
of NPY_ARRAY_F_CONTIGUOUS. The first is of type NPY_ORDER and the second
is a flag.
Closes #6618. [ci skip]
|
|
|
|
|
|
|
|
|
|
| |
PyArray_ISFORTRAN was used to implement array_is_fortran in numpy.i when
what was wanted was PyArray_IS_F_CONTIGUOUS. The difference is that
PyArray_ISFORTRAN will return False if the array is c_contiguous.
Previous to relaxed stride checking this did not matter, but currently
arrays with ndim > 1 may be both C and Fortran contiguous and that
results in errors when PyArray_ISFORTRAN is mistakenly used to check for
Fortran contiguity.
|
| |
|
|
|
|
|
| |
(DATA_TYPE* INPLACE_ARRAY_FLAT, DIM_TYPE DIM_FLAT)
Added unittests, updated documentation.
|
|
|
|
|
|
|
|
|
| |
Reason: numpy.i is supposed to be copied, not used from within an installed
Numpy version.
Closes gh-5690
[ci skip]
|
|
|
|
|
|
|
| |
For example, we had 256 errors (etc.) our process will exit with a
successful error code which is incorrect and/or misleading.
Signed-off-by: Chris Lamb <chris@chris-lamb.co.uk>
|
| |
|
|
|
|
|
|
| |
numpy.i now includes ready-made typemaps for std::complex<float>
and std::complex<double> . Tests were added to testArray using
a newly defined ArrayZ class.
|
|
|
|
|
|
| |
The typemaps with size parameters after the array pointer were correct,
but the typemaps with size parameters before the array pointer created
arrays with C ordering.
|
|
|
|
|
|
|
|
|
|
| |
The argout typemaps of all the ARGOUTVIEWM typemap suites make use of the
free_cap function, defined in the NumPy_Utilities fragment, which was not
listed in the fragment argument of the typemaps.
As a result, the free_cap function is not included in the source generated
code by SWIG, and the code do not compile (unless another typemap including
the missing fragment has been used).
|
| |
|
|
Also update MANIFEST.in and documentation to reflect the move. The
discussion of this change is at #2384.
Closes #2384. Closes #4374.
|