numpy 1.9.2__zip → 1.10.0__zip

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of numpy might be problematic. Click here for more details.

Files changed (1593) hide show
  1. numpy-1.10.0.post2/INSTALL.txt +200 -0
  2. numpy-1.10.0.post2/LICENSE.txt +30 -0
  3. numpy-1.10.0.post2/MANIFEST.in +31 -0
  4. numpy-1.10.0.post2/PKG-INFO +47 -0
  5. numpy-1.10.0.post2/cnew.txt +117 -0
  6. numpy-1.10.0.post2/cold.txt +44 -0
  7. numpy-1.10.0.post2/committers.txt +160 -0
  8. numpy-1.10.0.post2/cpre.txt +283 -0
  9. numpy-1.10.0.post2/crel.txt +161 -0
  10. numpy-1.10.0.post2/doc/release/1.10.0-notes.rst +439 -0
  11. numpy-1.10.0.post2/doc/scipy-sphinx-theme/.git +1 -0
  12. numpy-1.10.0.post2/doc/source/conf.py +331 -0
  13. numpy-1.10.0.post2/doc/source/dev/development_environment.rst +211 -0
  14. numpy-1.10.0.post2/doc/source/dev/gitwash/development_workflow.rst +534 -0
  15. numpy-1.10.0.post2/doc/source/dev/gitwash/git_links.inc +95 -0
  16. numpy-1.10.0.post2/doc/source/dev/gitwash/index.rst +14 -0
  17. numpy-1.10.0.post2/doc/source/dev/index.rst +11 -0
  18. numpy-1.10.0.post2/doc/source/reference/arrays.classes.rst +490 -0
  19. numpy-1.10.0.post2/doc/source/reference/arrays.dtypes.rst +536 -0
  20. numpy-1.10.0.post2/doc/source/reference/arrays.indexing.rst +549 -0
  21. numpy-1.10.0.post2/doc/source/reference/arrays.interface.rst +337 -0
  22. numpy-1.10.0.post2/doc/source/reference/arrays.ndarray.rst +622 -0
  23. numpy-1.10.0.post2/doc/source/reference/arrays.scalars.rst +291 -0
  24. numpy-1.10.0.post2/doc/source/reference/c-api.array.rst +3393 -0
  25. numpy-1.10.0.post2/doc/source/reference/c-api.config.rst +103 -0
  26. numpy-1.10.0.post2/doc/source/reference/c-api.coremath.rst +420 -0
  27. numpy-1.10.0.post2/doc/source/reference/c-api.dtype.rst +376 -0
  28. numpy-1.10.0.post2/doc/source/reference/c-api.generalized-ufuncs.rst +191 -0
  29. numpy-1.10.0.post2/doc/source/reference/c-api.iterator.rst +1300 -0
  30. numpy-1.10.0.post2/doc/source/reference/c-api.types-and-structures.rst +1240 -0
  31. numpy-1.10.0.post2/doc/source/reference/c-api.ufunc.rst +413 -0
  32. numpy-1.10.0.post2/doc/source/reference/index.rst +43 -0
  33. numpy-1.10.0.post2/doc/source/reference/internals.code-explanations.rst +615 -0
  34. numpy-1.10.0.post2/doc/source/reference/routines.array-manipulation.rst +115 -0
  35. numpy-1.10.0.post2/doc/source/reference/routines.io.rst +78 -0
  36. numpy-1.10.0.post2/doc/source/reference/routines.linalg.rst +91 -0
  37. numpy-1.10.0.post2/doc/source/reference/routines.ma.rst +407 -0
  38. numpy-1.10.0.post2/doc/source/reference/routines.sort.rst +41 -0
  39. numpy-1.10.0.post2/doc/source/reference/routines.statistics.rst +57 -0
  40. numpy-1.10.0.post2/doc/source/reference/swig.interface-file.rst +1066 -0
  41. numpy-1.10.0.post2/doc/source/reference/swig.testing.rst +167 -0
  42. numpy-1.10.0.post2/doc/source/reference/ufuncs.rst +666 -0
  43. numpy-1.10.0.post2/doc/source/release.rst +20 -0
  44. numpy-1.10.0.post2/doc/source/user/basics.io.genfromtxt.rst +531 -0
  45. numpy-1.10.0.post2/doc/source/user/basics.rec.rst +7 -0
  46. numpy-1.10.0.post2/doc/source/user/c-info.beyond-basics.rst +560 -0
  47. numpy-1.10.0.post2/doc/source/user/c-info.how-to-extend.rst +642 -0
  48. numpy-1.10.0.post2/doc/source/user/c-info.python-as-glue.rst +1177 -0
  49. numpy-1.10.0.post2/doc/source/user/c-info.ufunc-tutorial.rst +1211 -0
  50. numpy-1.10.0.post2/doc/source/user/install.rst +194 -0
  51. numpy-1.10.0.post2/doc/sphinxext/.git +1 -0
  52. numpy-1.10.0.post2/numpy/__init__.py +227 -0
  53. numpy-1.10.0.post2/numpy/_build_utils/README +8 -0
  54. numpy-1.10.0.post2/numpy/_build_utils/apple_accelerate.py +21 -0
  55. numpy-1.10.0.post2/numpy/_build_utils/common.py +138 -0
  56. numpy-1.10.0.post2/numpy/_build_utils/src/apple_sgemv_fix.c +227 -0
  57. numpy-1.10.0.post2/numpy/_build_utils/waf.py +531 -0
  58. numpy-1.10.0.post2/numpy/_import_tools.py +353 -0
  59. numpy-1.10.0.post2/numpy/add_newdocs.py +7611 -0
  60. numpy-1.10.0.post2/numpy/compat/_inspect.py +194 -0
  61. numpy-1.10.0.post2/numpy/compat/py3k.py +88 -0
  62. numpy-1.10.0.post2/numpy/compat/setup.py +12 -0
  63. numpy-1.10.0.post2/numpy/core/__init__.py +89 -0
  64. numpy-1.10.0.post2/numpy/core/_internal.py +761 -0
  65. numpy-1.10.0.post2/numpy/core/_methods.py +133 -0
  66. numpy-1.10.0.post2/numpy/core/arrayprint.py +760 -0
  67. numpy-1.10.0.post2/numpy/core/code_generators/cversions.txt +34 -0
  68. numpy-1.10.0.post2/numpy/core/code_generators/generate_ufunc_api.py +219 -0
  69. numpy-1.10.0.post2/numpy/core/code_generators/generate_umath.py +1017 -0
  70. numpy-1.10.0.post2/numpy/core/code_generators/numpy_api.py +415 -0
  71. numpy-1.10.0.post2/numpy/core/code_generators/ufunc_docstrings.py +3442 -0
  72. numpy-1.10.0.post2/numpy/core/defchararray.py +2689 -0
  73. numpy-1.10.0.post2/numpy/core/fromnumeric.py +3089 -0
  74. numpy-1.10.0.post2/numpy/core/function_base.py +203 -0
  75. numpy-1.10.0.post2/numpy/core/getlimits.py +308 -0
  76. numpy-1.10.0.post2/numpy/core/include/numpy/ndarrayobject.h +246 -0
  77. numpy-1.10.0.post2/numpy/core/include/numpy/ndarraytypes.h +1797 -0
  78. numpy-1.10.0.post2/numpy/core/include/numpy/npy_3kcompat.h +448 -0
  79. numpy-1.10.0.post2/numpy/core/include/numpy/npy_common.h +1051 -0
  80. numpy-1.10.0.post2/numpy/core/include/numpy/npy_cpu.h +92 -0
  81. numpy-1.10.0.post2/numpy/core/include/numpy/npy_endian.h +61 -0
  82. numpy-1.10.0.post2/numpy/core/include/numpy/npy_math.h +525 -0
  83. numpy-1.10.0.post2/numpy/core/include/numpy/numpyconfig.h +36 -0
  84. numpy-1.10.0.post2/numpy/core/machar.py +342 -0
  85. numpy-1.10.0.post2/numpy/core/memmap.py +311 -0
  86. numpy-1.10.0.post2/numpy/core/numeric.py +2893 -0
  87. numpy-1.10.0.post2/numpy/core/numerictypes.py +1036 -0
  88. numpy-1.10.0.post2/numpy/core/records.py +846 -0
  89. numpy-1.10.0.post2/numpy/core/setup.py +983 -0
  90. numpy-1.10.0.post2/numpy/core/setup_common.py +352 -0
  91. numpy-1.10.0.post2/numpy/core/shape_base.py +350 -0
  92. numpy-1.10.0.post2/numpy/core/src/multiarray/alloc.c +244 -0
  93. numpy-1.10.0.post2/numpy/core/src/multiarray/arrayobject.c +1858 -0
  94. numpy-1.10.0.post2/numpy/core/src/multiarray/arraytypes.c.src +4738 -0
  95. numpy-1.10.0.post2/numpy/core/src/multiarray/arraytypes.h +37 -0
  96. numpy-1.10.0.post2/numpy/core/src/multiarray/buffer.c +981 -0
  97. numpy-1.10.0.post2/numpy/core/src/multiarray/calculation.c +1224 -0
  98. numpy-1.10.0.post2/numpy/core/src/multiarray/cblasfuncs.c +812 -0
  99. numpy-1.10.0.post2/numpy/core/src/multiarray/cblasfuncs.h +10 -0
  100. numpy-1.10.0.post2/numpy/core/src/multiarray/common.c +911 -0
  101. numpy-1.10.0.post2/numpy/core/src/multiarray/common.h +250 -0
  102. numpy-1.10.0.post2/numpy/core/src/multiarray/compiled_base.c +1664 -0
  103. numpy-1.10.0.post2/numpy/core/src/multiarray/compiled_base.h +24 -0
  104. numpy-1.10.0.post2/numpy/core/src/multiarray/conversion_utils.c +1217 -0
  105. numpy-1.10.0.post2/numpy/core/src/multiarray/convert.c +590 -0
  106. numpy-1.10.0.post2/numpy/core/src/multiarray/convert_datatype.c +2155 -0
  107. numpy-1.10.0.post2/numpy/core/src/multiarray/ctors.c +3838 -0
  108. numpy-1.10.0.post2/numpy/core/src/multiarray/datetime.c +3821 -0
  109. numpy-1.10.0.post2/numpy/core/src/multiarray/datetime_busday.c +1322 -0
  110. numpy-1.10.0.post2/numpy/core/src/multiarray/datetime_busdaycal.c +552 -0
  111. numpy-1.10.0.post2/numpy/core/src/multiarray/datetime_strings.c +1772 -0
  112. numpy-1.10.0.post2/numpy/core/src/multiarray/descriptor.c +3719 -0
  113. numpy-1.10.0.post2/numpy/core/src/multiarray/dtype_transfer.c +4239 -0
  114. numpy-1.10.0.post2/numpy/core/src/multiarray/einsum.c.src +3005 -0
  115. numpy-1.10.0.post2/numpy/core/src/multiarray/getset.c +986 -0
  116. numpy-1.10.0.post2/numpy/core/src/multiarray/hashdescr.c +318 -0
  117. numpy-1.10.0.post2/numpy/core/src/multiarray/item_selection.c +2413 -0
  118. numpy-1.10.0.post2/numpy/core/src/multiarray/iterators.c +2192 -0
  119. numpy-1.10.0.post2/numpy/core/src/multiarray/lowlevel_strided_loops.c.src +1769 -0
  120. numpy-1.10.0.post2/numpy/core/src/multiarray/mapping.c +3380 -0
  121. numpy-1.10.0.post2/numpy/core/src/multiarray/mapping.h +77 -0
  122. numpy-1.10.0.post2/numpy/core/src/multiarray/methods.c +2514 -0
  123. numpy-1.10.0.post2/numpy/core/src/multiarray/multiarray_tests.c.src +1035 -0
  124. numpy-1.10.0.post2/numpy/core/src/multiarray/multiarraymodule.c +4628 -0
  125. numpy-1.10.0.post2/numpy/core/src/multiarray/multiarraymodule.h +15 -0
  126. numpy-1.10.0.post2/numpy/core/src/multiarray/nditer_api.c +2809 -0
  127. numpy-1.10.0.post2/numpy/core/src/multiarray/nditer_constr.c +3160 -0
  128. numpy-1.10.0.post2/numpy/core/src/multiarray/nditer_pywrap.c +2499 -0
  129. numpy-1.10.0.post2/numpy/core/src/multiarray/number.c +1106 -0
  130. numpy-1.10.0.post2/numpy/core/src/multiarray/number.h +77 -0
  131. numpy-1.10.0.post2/numpy/core/src/multiarray/numpymemoryview.c +308 -0
  132. numpy-1.10.0.post2/numpy/core/src/multiarray/numpyos.c +683 -0
  133. numpy-1.10.0.post2/numpy/core/src/multiarray/scalarapi.c +870 -0
  134. numpy-1.10.0.post2/numpy/core/src/multiarray/scalartypes.c.src +4343 -0
  135. numpy-1.10.0.post2/numpy/core/src/multiarray/scalartypes.h +55 -0
  136. numpy-1.10.0.post2/numpy/core/src/multiarray/shape.c +1131 -0
  137. numpy-1.10.0.post2/numpy/core/src/multiarray/ucsnarrow.c +174 -0
  138. numpy-1.10.0.post2/numpy/core/src/multiarray/vdot.c +180 -0
  139. numpy-1.10.0.post2/numpy/core/src/multiarray/vdot.h +18 -0
  140. numpy-1.10.0.post2/numpy/core/src/npymath/ieee754.c.src +808 -0
  141. numpy-1.10.0.post2/numpy/core/src/npymath/npy_math.c.src +597 -0
  142. numpy-1.10.0.post2/numpy/core/src/npymath/npy_math_complex.c.src +1788 -0
  143. numpy-1.10.0.post2/numpy/core/src/npymath/npy_math_private.h +544 -0
  144. numpy-1.10.0.post2/numpy/core/src/npysort/heapsort.c.src +402 -0
  145. numpy-1.10.0.post2/numpy/core/src/npysort/mergesort.c.src +488 -0
  146. numpy-1.10.0.post2/numpy/core/src/npysort/npysort_common.h +360 -0
  147. numpy-1.10.0.post2/numpy/core/src/npysort/quicksort.c.src +523 -0
  148. numpy-1.10.0.post2/numpy/core/src/npysort/selection.c.src +426 -0
  149. numpy-1.10.0.post2/numpy/core/src/private/npy_cblas.h +584 -0
  150. numpy-1.10.0.post2/numpy/core/src/private/npy_config.h +101 -0
  151. numpy-1.10.0.post2/numpy/core/src/private/npy_import.h +32 -0
  152. numpy-1.10.0.post2/numpy/core/src/private/npy_partition.h.src +122 -0
  153. numpy-1.10.0.post2/numpy/core/src/private/npy_sort.h +196 -0
  154. numpy-1.10.0.post2/numpy/core/src/private/templ_common.h.src +43 -0
  155. numpy-1.10.0.post2/numpy/core/src/private/ufunc_override.h +397 -0
  156. numpy-1.10.0.post2/numpy/core/src/umath/funcs.inc.src +356 -0
  157. numpy-1.10.0.post2/numpy/core/src/umath/loops.c.src +2675 -0
  158. numpy-1.10.0.post2/numpy/core/src/umath/loops.h.src +497 -0
  159. numpy-1.10.0.post2/numpy/core/src/umath/operand_flag_tests.c.src +105 -0
  160. numpy-1.10.0.post2/numpy/core/src/umath/scalarmath.c.src +1738 -0
  161. numpy-1.10.0.post2/numpy/core/src/umath/simd.inc.src +903 -0
  162. numpy-1.10.0.post2/numpy/core/src/umath/test_rational.c.src +1404 -0
  163. numpy-1.10.0.post2/numpy/core/src/umath/ufunc_object.c +5703 -0
  164. numpy-1.10.0.post2/numpy/core/src/umath/ufunc_type_resolution.c +2159 -0
  165. numpy-1.10.0.post2/numpy/core/src/umath/umath_tests.c.src +392 -0
  166. numpy-1.10.0.post2/numpy/core/src/umath/umathmodule.c +443 -0
  167. numpy-1.10.0.post2/numpy/core/tests/test_abc.py +47 -0
  168. numpy-1.10.0.post2/numpy/core/tests/test_api.py +515 -0
  169. numpy-1.10.0.post2/numpy/core/tests/test_arrayprint.py +171 -0
  170. numpy-1.10.0.post2/numpy/core/tests/test_datetime.py +1820 -0
  171. numpy-1.10.0.post2/numpy/core/tests/test_defchararray.py +703 -0
  172. numpy-1.10.0.post2/numpy/core/tests/test_deprecations.py +619 -0
  173. numpy-1.10.0.post2/numpy/core/tests/test_dtype.py +578 -0
  174. numpy-1.10.0.post2/numpy/core/tests/test_einsum.py +627 -0
  175. numpy-1.10.0.post2/numpy/core/tests/test_errstate.py +52 -0
  176. numpy-1.10.0.post2/numpy/core/tests/test_function_base.py +142 -0
  177. numpy-1.10.0.post2/numpy/core/tests/test_getlimits.py +77 -0
  178. numpy-1.10.0.post2/numpy/core/tests/test_half.py +436 -0
  179. numpy-1.10.0.post2/numpy/core/tests/test_indexerrors.py +126 -0
  180. numpy-1.10.0.post2/numpy/core/tests/test_indexing.py +1047 -0
  181. numpy-1.10.0.post2/numpy/core/tests/test_item_selection.py +73 -0
  182. numpy-1.10.0.post2/numpy/core/tests/test_machar.py +29 -0
  183. numpy-1.10.0.post2/numpy/core/tests/test_memmap.py +130 -0
  184. numpy-1.10.0.post2/numpy/core/tests/test_multiarray.py +5924 -0
  185. numpy-1.10.0.post2/numpy/core/tests/test_multiarray_assignment.py +84 -0
  186. numpy-1.10.0.post2/numpy/core/tests/test_nditer.py +2638 -0
  187. numpy-1.10.0.post2/numpy/core/tests/test_numeric.py +2204 -0
  188. numpy-1.10.0.post2/numpy/core/tests/test_numerictypes.py +382 -0
  189. numpy-1.10.0.post2/numpy/core/tests/test_print.py +248 -0
  190. numpy-1.10.0.post2/numpy/core/tests/test_records.py +299 -0
  191. numpy-1.10.0.post2/numpy/core/tests/test_regression.py +2177 -0
  192. numpy-1.10.0.post2/numpy/core/tests/test_scalarinherit.py +41 -0
  193. numpy-1.10.0.post2/numpy/core/tests/test_scalarmath.py +316 -0
  194. numpy-1.10.0.post2/numpy/core/tests/test_shape_base.py +319 -0
  195. numpy-1.10.0.post2/numpy/core/tests/test_ufunc.py +1227 -0
  196. numpy-1.10.0.post2/numpy/core/tests/test_umath.py +1933 -0
  197. numpy-1.10.0.post2/numpy/core/tests/test_umath_complex.py +538 -0
  198. numpy-1.10.0.post2/numpy/core/tests/test_unicode.py +360 -0
  199. numpy-1.10.0.post2/numpy/distutils/__init__.py +23 -0
  200. numpy-1.10.0.post2/numpy/distutils/ccompiler.py +690 -0
  201. numpy-1.10.0.post2/numpy/distutils/command/autodist.py +94 -0
  202. numpy-1.10.0.post2/numpy/distutils/command/build.py +47 -0
  203. numpy-1.10.0.post2/numpy/distutils/command/build_clib.py +295 -0
  204. numpy-1.10.0.post2/numpy/distutils/command/build_ext.py +522 -0
  205. numpy-1.10.0.post2/numpy/distutils/command/config.py +437 -0
  206. numpy-1.10.0.post2/numpy/distutils/exec_command.py +651 -0
  207. numpy-1.10.0.post2/numpy/distutils/fcompiler/compaq.py +128 -0
  208. numpy-1.10.0.post2/numpy/distutils/fcompiler/gnu.py +403 -0
  209. numpy-1.10.0.post2/numpy/distutils/fcompiler/intel.py +217 -0
  210. numpy-1.10.0.post2/numpy/distutils/fcompiler/pg.py +63 -0
  211. numpy-1.10.0.post2/numpy/distutils/fcompiler/sun.py +55 -0
  212. numpy-1.10.0.post2/numpy/distutils/intelccompiler.py +95 -0
  213. numpy-1.10.0.post2/numpy/distutils/lib2def.py +116 -0
  214. numpy-1.10.0.post2/numpy/distutils/mingw32ccompiler.py +599 -0
  215. numpy-1.10.0.post2/numpy/distutils/misc_util.py +2306 -0
  216. numpy-1.10.0.post2/numpy/distutils/msvc9compiler.py +23 -0
  217. numpy-1.10.0.post2/numpy/distutils/msvccompiler.py +17 -0
  218. numpy-1.10.0.post2/numpy/distutils/npy_pkg_config.py +451 -0
  219. numpy-1.10.0.post2/numpy/distutils/system_info.py +2397 -0
  220. numpy-1.10.0.post2/numpy/distutils/tests/f2py_ext/tests/test_fib2.py +12 -0
  221. numpy-1.10.0.post2/numpy/distutils/tests/f2py_f90_ext/tests/test_foo.py +11 -0
  222. numpy-1.10.0.post2/numpy/distutils/tests/gen_ext/tests/test_fib3.py +11 -0
  223. numpy-1.10.0.post2/numpy/distutils/tests/pyrex_ext/tests/test_primes.py +13 -0
  224. numpy-1.10.0.post2/numpy/distutils/tests/swig_ext/__init__.py +1 -0
  225. numpy-1.10.0.post2/numpy/distutils/tests/swig_ext/tests/test_example.py +17 -0
  226. numpy-1.10.0.post2/numpy/distutils/tests/swig_ext/tests/test_example2.py +15 -0
  227. numpy-1.10.0.post2/numpy/distutils/tests/test_fcompiler_gnu.py +60 -0
  228. numpy-1.10.0.post2/numpy/distutils/tests/test_fcompiler_intel.py +36 -0
  229. numpy-1.10.0.post2/numpy/distutils/tests/test_misc_util.py +79 -0
  230. numpy-1.10.0.post2/numpy/distutils/tests/test_npy_pkg_config.py +102 -0
  231. numpy-1.10.0.post2/numpy/distutils/tests/test_system_info.py +209 -0
  232. numpy-1.10.0.post2/numpy/distutils/unixccompiler.py +125 -0
  233. numpy-1.10.0.post2/numpy/doc/byteswapping.py +156 -0
  234. numpy-1.10.0.post2/numpy/doc/creation.py +144 -0
  235. numpy-1.10.0.post2/numpy/doc/glossary.py +423 -0
  236. numpy-1.10.0.post2/numpy/doc/indexing.py +439 -0
  237. numpy-1.10.0.post2/numpy/doc/structured_arrays.py +290 -0
  238. numpy-1.10.0.post2/numpy/f2py/__init__.py +49 -0
  239. numpy-1.10.0.post2/numpy/f2py/__main__.py +25 -0
  240. numpy-1.10.0.post2/numpy/f2py/auxfuncs.py +858 -0
  241. numpy-1.10.0.post2/numpy/f2py/capi_maps.py +851 -0
  242. numpy-1.10.0.post2/numpy/f2py/cb_rules.py +554 -0
  243. numpy-1.10.0.post2/numpy/f2py/cfuncs.py +1261 -0
  244. numpy-1.10.0.post2/numpy/f2py/common_rules.py +150 -0
  245. numpy-1.10.0.post2/numpy/f2py/crackfortran.py +3314 -0
  246. numpy-1.10.0.post2/numpy/f2py/diagnose.py +156 -0
  247. numpy-1.10.0.post2/numpy/f2py/f2py2e.py +656 -0
  248. numpy-1.10.0.post2/numpy/f2py/f2py_testing.py +48 -0
  249. numpy-1.10.0.post2/numpy/f2py/f90mod_rules.py +272 -0
  250. numpy-1.10.0.post2/numpy/f2py/func2subr.py +299 -0
  251. numpy-1.10.0.post2/numpy/f2py/rules.py +1475 -0
  252. numpy-1.10.0.post2/numpy/f2py/setup.py +117 -0
  253. numpy-1.10.0.post2/numpy/f2py/src/fortranobject.c +1037 -0
  254. numpy-1.10.0.post2/numpy/f2py/src/fortranobject.h +162 -0
  255. numpy-1.10.0.post2/numpy/f2py/tests/src/array_from_pyobj/wrapmodule.c +223 -0
  256. numpy-1.10.0.post2/numpy/f2py/tests/test_array_from_pyobj.py +593 -0
  257. numpy-1.10.0.post2/numpy/f2py/tests/test_assumed_shape.py +35 -0
  258. numpy-1.10.0.post2/numpy/f2py/tests/test_callback.py +136 -0
  259. numpy-1.10.0.post2/numpy/f2py/tests/test_kind.py +36 -0
  260. numpy-1.10.0.post2/numpy/f2py/tests/test_mixed.py +40 -0
  261. numpy-1.10.0.post2/numpy/f2py/tests/test_regression.py +34 -0
  262. numpy-1.10.0.post2/numpy/f2py/tests/test_return_character.py +148 -0
  263. numpy-1.10.0.post2/numpy/f2py/tests/test_return_complex.py +170 -0
  264. numpy-1.10.0.post2/numpy/f2py/tests/test_return_integer.py +180 -0
  265. numpy-1.10.0.post2/numpy/f2py/tests/test_return_logical.py +189 -0
  266. numpy-1.10.0.post2/numpy/f2py/tests/test_return_real.py +206 -0
  267. numpy-1.10.0.post2/numpy/f2py/tests/test_size.py +44 -0
  268. numpy-1.10.0.post2/numpy/f2py/tests/util.py +367 -0
  269. numpy-1.10.0.post2/numpy/f2py/use_rules.py +115 -0
  270. numpy-1.10.0.post2/numpy/fft/fftpack.c +1501 -0
  271. numpy-1.10.0.post2/numpy/fft/fftpack.h +28 -0
  272. numpy-1.10.0.post2/numpy/fft/fftpack.py +1241 -0
  273. numpy-1.10.0.post2/numpy/fft/fftpack_litemodule.c +363 -0
  274. numpy-1.10.0.post2/numpy/fft/info.py +187 -0
  275. numpy-1.10.0.post2/numpy/fft/setup.py +19 -0
  276. numpy-1.10.0.post2/numpy/fft/tests/test_fftpack.py +166 -0
  277. numpy-1.10.0.post2/numpy/fft/tests/test_helper.py +78 -0
  278. numpy-1.10.0.post2/numpy/lib/_iotools.py +917 -0
  279. numpy-1.10.0.post2/numpy/lib/arraypad.py +1497 -0
  280. numpy-1.10.0.post2/numpy/lib/arraysetops.py +480 -0
  281. numpy-1.10.0.post2/numpy/lib/arrayterator.py +226 -0
  282. numpy-1.10.0.post2/numpy/lib/financial.py +737 -0
  283. numpy-1.10.0.post2/numpy/lib/format.py +814 -0
  284. numpy-1.10.0.post2/numpy/lib/function_base.py +4150 -0
  285. numpy-1.10.0.post2/numpy/lib/index_tricks.py +874 -0
  286. numpy-1.10.0.post2/numpy/lib/info.py +152 -0
  287. numpy-1.10.0.post2/numpy/lib/nanfunctions.py +1237 -0
  288. numpy-1.10.0.post2/numpy/lib/npyio.py +1992 -0
  289. numpy-1.10.0.post2/numpy/lib/polynomial.py +1277 -0
  290. numpy-1.10.0.post2/numpy/lib/recfunctions.py +1003 -0
  291. numpy-1.10.0.post2/numpy/lib/setup.py +12 -0
  292. numpy-1.10.0.post2/numpy/lib/shape_base.py +872 -0
  293. numpy-1.10.0.post2/numpy/lib/stride_tricks.py +200 -0
  294. numpy-1.10.0.post2/numpy/lib/tests/data/py2-objarr.npy +0 -0
  295. numpy-1.10.0.post2/numpy/lib/tests/data/py2-objarr.npz +0 -0
  296. numpy-1.10.0.post2/numpy/lib/tests/data/py3-objarr.npy +0 -0
  297. numpy-1.10.0.post2/numpy/lib/tests/data/py3-objarr.npz +0 -0
  298. numpy-1.10.0.post2/numpy/lib/tests/test__iotools.py +348 -0
  299. numpy-1.10.0.post2/numpy/lib/tests/test__version.py +70 -0
  300. numpy-1.10.0.post2/numpy/lib/tests/test_arraypad.py +1047 -0
  301. numpy-1.10.0.post2/numpy/lib/tests/test_arraysetops.py +309 -0
  302. numpy-1.10.0.post2/numpy/lib/tests/test_financial.py +163 -0
  303. numpy-1.10.0.post2/numpy/lib/tests/test_format.py +841 -0
  304. numpy-1.10.0.post2/numpy/lib/tests/test_function_base.py +2555 -0
  305. numpy-1.10.0.post2/numpy/lib/tests/test_index_tricks.py +326 -0
  306. numpy-1.10.0.post2/numpy/lib/tests/test_io.py +1916 -0
  307. numpy-1.10.0.post2/numpy/lib/tests/test_nanfunctions.py +707 -0
  308. numpy-1.10.0.post2/numpy/lib/tests/test_packbits.py +26 -0
  309. numpy-1.10.0.post2/numpy/lib/tests/test_polynomial.py +188 -0
  310. numpy-1.10.0.post2/numpy/lib/tests/test_recfunctions.py +734 -0
  311. numpy-1.10.0.post2/numpy/lib/tests/test_shape_base.py +386 -0
  312. numpy-1.10.0.post2/numpy/lib/tests/test_stride_tricks.py +405 -0
  313. numpy-1.10.0.post2/numpy/lib/tests/test_twodim_base.py +535 -0
  314. numpy-1.10.0.post2/numpy/lib/tests/test_type_check.py +332 -0
  315. numpy-1.10.0.post2/numpy/lib/twodim_base.py +1007 -0
  316. numpy-1.10.0.post2/numpy/lib/type_check.py +596 -0
  317. numpy-1.10.0.post2/numpy/lib/utils.py +1122 -0
  318. numpy-1.10.0.post2/numpy/linalg/lapack_lite/python_xerbla.c +46 -0
  319. numpy-1.10.0.post2/numpy/linalg/lapack_litemodule.c +358 -0
  320. numpy-1.10.0.post2/numpy/linalg/linalg.py +2406 -0
  321. numpy-1.10.0.post2/numpy/linalg/tests/test_build.py +59 -0
  322. numpy-1.10.0.post2/numpy/linalg/tests/test_linalg.py +1351 -0
  323. numpy-1.10.0.post2/numpy/linalg/tests/test_regression.py +95 -0
  324. numpy-1.10.0.post2/numpy/linalg/umath_linalg.c.src +3236 -0
  325. numpy-1.10.0.post2/numpy/ma/__init__.py +56 -0
  326. numpy-1.10.0.post2/numpy/ma/bench.py +131 -0
  327. numpy-1.10.0.post2/numpy/ma/core.py +7608 -0
  328. numpy-1.10.0.post2/numpy/ma/extras.py +1953 -0
  329. numpy-1.10.0.post2/numpy/ma/mrecords.py +796 -0
  330. numpy-1.10.0.post2/numpy/ma/setup.py +13 -0
  331. numpy-1.10.0.post2/numpy/ma/tests/test_core.py +4100 -0
  332. numpy-1.10.0.post2/numpy/ma/tests/test_extras.py +1132 -0
  333. numpy-1.10.0.post2/numpy/ma/tests/test_mrecords.py +520 -0
  334. numpy-1.10.0.post2/numpy/ma/tests/test_old_ma.py +879 -0
  335. numpy-1.10.0.post2/numpy/ma/tests/test_regression.py +80 -0
  336. numpy-1.10.0.post2/numpy/ma/tests/test_subclassing.py +338 -0
  337. numpy-1.10.0.post2/numpy/ma/testutils.py +289 -0
  338. numpy-1.10.0.post2/numpy/ma/timer_comparison.py +440 -0
  339. numpy-1.10.0.post2/numpy/matlib.py +358 -0
  340. numpy-1.10.0.post2/numpy/matrixlib/defmatrix.py +1232 -0
  341. numpy-1.10.0.post2/numpy/matrixlib/tests/test_defmatrix.py +449 -0
  342. numpy-1.10.0.post2/numpy/matrixlib/tests/test_multiarray.py +23 -0
  343. numpy-1.10.0.post2/numpy/matrixlib/tests/test_numeric.py +23 -0
  344. numpy-1.10.0.post2/numpy/matrixlib/tests/test_regression.py +37 -0
  345. numpy-1.10.0.post2/numpy/polynomial/_polybase.py +962 -0
  346. numpy-1.10.0.post2/numpy/polynomial/chebyshev.py +2056 -0
  347. numpy-1.10.0.post2/numpy/polynomial/hermite.py +1831 -0
  348. numpy-1.10.0.post2/numpy/polynomial/hermite_e.py +1828 -0
  349. numpy-1.10.0.post2/numpy/polynomial/laguerre.py +1780 -0
  350. numpy-1.10.0.post2/numpy/polynomial/legendre.py +1808 -0
  351. numpy-1.10.0.post2/numpy/polynomial/polyutils.py +403 -0
  352. numpy-1.10.0.post2/numpy/random/mtrand/distributions.c +912 -0
  353. numpy-1.10.0.post2/numpy/random/mtrand/mtrand.c +34805 -0
  354. numpy-1.10.0.post2/numpy/random/mtrand/mtrand.pyx +4766 -0
  355. numpy-1.10.0.post2/numpy/random/setup.py +61 -0
  356. numpy-1.10.0.post2/numpy/random/tests/test_random.py +723 -0
  357. numpy-1.10.0.post2/numpy/random/tests/test_regression.py +117 -0
  358. numpy-1.10.0.post2/numpy/setup.py +29 -0
  359. numpy-1.10.0.post2/numpy/testing/__init__.py +15 -0
  360. numpy-1.10.0.post2/numpy/testing/decorators.py +271 -0
  361. numpy-1.10.0.post2/numpy/testing/noseclasses.py +353 -0
  362. numpy-1.10.0.post2/numpy/testing/nosetester.py +511 -0
  363. numpy-1.10.0.post2/numpy/testing/print_coercion_tables.py +91 -0
  364. numpy-1.10.0.post2/numpy/testing/setup.py +20 -0
  365. numpy-1.10.0.post2/numpy/testing/tests/test_decorators.py +182 -0
  366. numpy-1.10.0.post2/numpy/testing/tests/test_utils.py +781 -0
  367. numpy-1.10.0.post2/numpy/testing/utils.py +1831 -0
  368. numpy-1.10.0.post2/numpy/tests/test_ctypeslib.py +106 -0
  369. numpy-1.10.0.post2/numpy/tests/test_matlib.py +55 -0
  370. numpy-1.10.0.post2/numpy/tests/test_scripts.py +69 -0
  371. numpy-1.10.0.post2/numpy/version.py +10 -0
  372. numpy-1.10.0.post2/setup.py +260 -0
  373. numpy-1.10.0.post2/site.cfg.example +193 -0
  374. numpy-1.10.0.post2/tmp.txt +789 -0
  375. numpy-1.10.0.post2/tools/swig/README +145 -0
  376. numpy-1.10.0.post2/tools/swig/numpy.i +3161 -0
  377. numpy-1.10.0.post2/tools/swig/test/Array.i +135 -0
  378. numpy-1.10.0.post2/tools/swig/test/ArrayZ.cxx +131 -0
  379. numpy-1.10.0.post2/tools/swig/test/ArrayZ.h +56 -0
  380. numpy-1.10.0.post2/tools/swig/test/Flat.cxx +36 -0
  381. numpy-1.10.0.post2/tools/swig/test/Flat.h +34 -0
  382. numpy-1.10.0.post2/tools/swig/test/Flat.i +36 -0
  383. numpy-1.10.0.post2/tools/swig/test/Makefile +37 -0
  384. numpy-1.10.0.post2/tools/swig/test/setup.py +71 -0
  385. numpy-1.10.0.post2/tools/swig/test/testArray.py +385 -0
  386. numpy-1.10.0.post2/tools/swig/test/testFarray.py +159 -0
  387. numpy-1.10.0.post2/tools/swig/test/testFlat.py +200 -0
  388. numpy-1.10.0.post2/tools/swig/test/testFortran.py +173 -0
  389. numpy-1.10.0.post2/tools/swig/test/testMatrix.py +362 -0
  390. numpy-1.10.0.post2/tools/swig/test/testSuperTensor.py +388 -0
  391. numpy-1.10.0.post2/tools/swig/test/testTensor.py +402 -0
  392. numpy-1.10.0.post2/tools/swig/test/testVector.py +381 -0
  393. numpy-1.9.2/INSTALL.txt +0 -138
  394. numpy-1.9.2/LICENSE.txt +0 -30
  395. numpy-1.9.2/MANIFEST.in +0 -26
  396. numpy-1.9.2/PKG-INFO +0 -39
  397. numpy-1.9.2/doc/scipy-sphinx-theme/.git +0 -1
  398. numpy-1.9.2/doc/source/conf.py +0 -331
  399. numpy-1.9.2/doc/source/dev/gitwash/branch_list.png +0 -0
  400. numpy-1.9.2/doc/source/dev/gitwash/branch_list_compare.png +0 -0
  401. numpy-1.9.2/doc/source/dev/gitwash/development_workflow.rst +0 -568
  402. numpy-1.9.2/doc/source/dev/gitwash/git_links.inc +0 -88
  403. numpy-1.9.2/doc/source/dev/gitwash/index.rst +0 -14
  404. numpy-1.9.2/doc/source/dev/index.rst +0 -10
  405. numpy-1.9.2/doc/source/reference/arrays.classes.rst +0 -427
  406. numpy-1.9.2/doc/source/reference/arrays.dtypes.rst +0 -534
  407. numpy-1.9.2/doc/source/reference/arrays.indexing.rst +0 -550
  408. numpy-1.9.2/doc/source/reference/arrays.interface.rst +0 -336
  409. numpy-1.9.2/doc/source/reference/arrays.ndarray.rst +0 -609
  410. numpy-1.9.2/doc/source/reference/arrays.scalars.rst +0 -291
  411. numpy-1.9.2/doc/source/reference/c-api.array.rst +0 -3362
  412. numpy-1.9.2/doc/source/reference/c-api.config.rst +0 -103
  413. numpy-1.9.2/doc/source/reference/c-api.coremath.rst +0 -420
  414. numpy-1.9.2/doc/source/reference/c-api.dtype.rst +0 -376
  415. numpy-1.9.2/doc/source/reference/c-api.generalized-ufuncs.rst +0 -171
  416. numpy-1.9.2/doc/source/reference/c-api.iterator.rst +0 -1298
  417. numpy-1.9.2/doc/source/reference/c-api.types-and-structures.rst +0 -1204
  418. numpy-1.9.2/doc/source/reference/c-api.ufunc.rst +0 -399
  419. numpy-1.9.2/doc/source/reference/index.rst +0 -44
  420. numpy-1.9.2/doc/source/reference/internals.code-explanations.rst +0 -666
  421. numpy-1.9.2/doc/source/reference/routines.array-manipulation.rst +0 -113
  422. numpy-1.9.2/doc/source/reference/routines.io.rst +0 -74
  423. numpy-1.9.2/doc/source/reference/routines.linalg.rst +0 -88
  424. numpy-1.9.2/doc/source/reference/routines.ma.rst +0 -405
  425. numpy-1.9.2/doc/source/reference/routines.sort.rst +0 -42
  426. numpy-1.9.2/doc/source/reference/routines.statistics.rst +0 -55
  427. numpy-1.9.2/doc/source/reference/swig.interface-file.rst +0 -1055
  428. numpy-1.9.2/doc/source/reference/swig.testing.rst +0 -166
  429. numpy-1.9.2/doc/source/reference/ufuncs.rst +0 -651
  430. numpy-1.9.2/doc/source/release.rst +0 -19
  431. numpy-1.9.2/doc/source/user/basics.io.genfromtxt.rst +0 -531
  432. numpy-1.9.2/doc/source/user/basics.rec.rst +0 -7
  433. numpy-1.9.2/doc/source/user/c-info.beyond-basics.rst +0 -560
  434. numpy-1.9.2/doc/source/user/c-info.how-to-extend.rst +0 -642
  435. numpy-1.9.2/doc/source/user/c-info.python-as-glue.rst +0 -1528
  436. numpy-1.9.2/doc/source/user/c-info.ufunc-tutorial.rst +0 -1211
  437. numpy-1.9.2/doc/source/user/install.rst +0 -180
  438. numpy-1.9.2/doc/sphinxext/.git +0 -1
  439. numpy-1.9.2/numpy/__init__.py +0 -216
  440. numpy-1.9.2/numpy/_import_tools.py +0 -348
  441. numpy-1.9.2/numpy/add_newdocs.py +0 -7518
  442. numpy-1.9.2/numpy/compat/_inspect.py +0 -221
  443. numpy-1.9.2/numpy/compat/py3k.py +0 -89
  444. numpy-1.9.2/numpy/compat/setup.py +0 -12
  445. numpy-1.9.2/numpy/core/__init__.py +0 -78
  446. numpy-1.9.2/numpy/core/_internal.py +0 -570
  447. numpy-1.9.2/numpy/core/_methods.py +0 -134
  448. numpy-1.9.2/numpy/core/arrayprint.py +0 -752
  449. numpy-1.9.2/numpy/core/blasdot/_dotblas.c +0 -1255
  450. numpy-1.9.2/numpy/core/blasdot/apple_sgemv_patch.c +0 -216
  451. numpy-1.9.2/numpy/core/blasdot/cblas.h +0 -578
  452. numpy-1.9.2/numpy/core/code_generators/cversions.txt +0 -31
  453. numpy-1.9.2/numpy/core/code_generators/generate_ufunc_api.py +0 -219
  454. numpy-1.9.2/numpy/core/code_generators/generate_umath.py +0 -972
  455. numpy-1.9.2/numpy/core/code_generators/numpy_api.py +0 -412
  456. numpy-1.9.2/numpy/core/code_generators/ufunc_docstrings.py +0 -3419
  457. numpy-1.9.2/numpy/core/defchararray.py +0 -2687
  458. numpy-1.9.2/numpy/core/fromnumeric.py +0 -2938
  459. numpy-1.9.2/numpy/core/function_base.py +0 -190
  460. numpy-1.9.2/numpy/core/getlimits.py +0 -306
  461. numpy-1.9.2/numpy/core/include/numpy/fenv/fenv.c +0 -38
  462. numpy-1.9.2/numpy/core/include/numpy/fenv/fenv.h +0 -224
  463. numpy-1.9.2/numpy/core/include/numpy/ndarrayobject.h +0 -237
  464. numpy-1.9.2/numpy/core/include/numpy/ndarraytypes.h +0 -1820
  465. numpy-1.9.2/numpy/core/include/numpy/npy_3kcompat.h +0 -506
  466. numpy-1.9.2/numpy/core/include/numpy/npy_common.h +0 -1038
  467. numpy-1.9.2/numpy/core/include/numpy/npy_cpu.h +0 -122
  468. numpy-1.9.2/numpy/core/include/numpy/npy_endian.h +0 -49
  469. numpy-1.9.2/numpy/core/include/numpy/npy_math.h +0 -479
  470. numpy-1.9.2/numpy/core/include/numpy/numpyconfig.h +0 -35
  471. numpy-1.9.2/numpy/core/machar.py +0 -338
  472. numpy-1.9.2/numpy/core/memmap.py +0 -308
  473. numpy-1.9.2/numpy/core/numeric.py +0 -2842
  474. numpy-1.9.2/numpy/core/numerictypes.py +0 -1042
  475. numpy-1.9.2/numpy/core/records.py +0 -804
  476. numpy-1.9.2/numpy/core/setup.py +0 -1016
  477. numpy-1.9.2/numpy/core/setup_common.py +0 -321
  478. numpy-1.9.2/numpy/core/shape_base.py +0 -277
  479. numpy-1.9.2/numpy/core/src/multiarray/alloc.c +0 -241
  480. numpy-1.9.2/numpy/core/src/multiarray/arrayobject.c +0 -1791
  481. numpy-1.9.2/numpy/core/src/multiarray/arraytypes.c.src +0 -4372
  482. numpy-1.9.2/numpy/core/src/multiarray/arraytypes.h +0 -13
  483. numpy-1.9.2/numpy/core/src/multiarray/buffer.c +0 -954
  484. numpy-1.9.2/numpy/core/src/multiarray/calculation.c +0 -1229
  485. numpy-1.9.2/numpy/core/src/multiarray/common.c +0 -798
  486. numpy-1.9.2/numpy/core/src/multiarray/common.h +0 -328
  487. numpy-1.9.2/numpy/core/src/multiarray/conversion_utils.c +0 -1240
  488. numpy-1.9.2/numpy/core/src/multiarray/convert.c +0 -589
  489. numpy-1.9.2/numpy/core/src/multiarray/convert_datatype.c +0 -2199
  490. numpy-1.9.2/numpy/core/src/multiarray/ctors.c +0 -3785
  491. numpy-1.9.2/numpy/core/src/multiarray/datetime.c +0 -3823
  492. numpy-1.9.2/numpy/core/src/multiarray/datetime_busday.c +0 -1322
  493. numpy-1.9.2/numpy/core/src/multiarray/datetime_busdaycal.c +0 -552
  494. numpy-1.9.2/numpy/core/src/multiarray/datetime_strings.c +0 -1772
  495. numpy-1.9.2/numpy/core/src/multiarray/descriptor.c +0 -3658
  496. numpy-1.9.2/numpy/core/src/multiarray/dtype_transfer.c +0 -4232
  497. numpy-1.9.2/numpy/core/src/multiarray/einsum.c.src +0 -3013
  498. numpy-1.9.2/numpy/core/src/multiarray/getset.c +0 -984
  499. numpy-1.9.2/numpy/core/src/multiarray/hashdescr.c +0 -319
  500. numpy-1.9.2/numpy/core/src/multiarray/item_selection.c +0 -2711
  501. numpy-1.9.2/numpy/core/src/multiarray/iterators.c +0 -2160
  502. numpy-1.9.2/numpy/core/src/multiarray/lowlevel_strided_loops.c.src +0 -1767
  503. numpy-1.9.2/numpy/core/src/multiarray/mapping.c +0 -3316
  504. numpy-1.9.2/numpy/core/src/multiarray/mapping.h +0 -73
  505. numpy-1.9.2/numpy/core/src/multiarray/methods.c +0 -2497
  506. numpy-1.9.2/numpy/core/src/multiarray/multiarray_tests.c.src +0 -977
  507. numpy-1.9.2/numpy/core/src/multiarray/multiarraymodule.c +0 -4202
  508. numpy-1.9.2/numpy/core/src/multiarray/multiarraymodule.h +0 -4
  509. numpy-1.9.2/numpy/core/src/multiarray/multiarraymodule_onefile.c +0 -58
  510. numpy-1.9.2/numpy/core/src/multiarray/nditer_api.c +0 -2809
  511. numpy-1.9.2/numpy/core/src/multiarray/nditer_constr.c +0 -3159
  512. numpy-1.9.2/numpy/core/src/multiarray/nditer_pywrap.c +0 -2492
  513. numpy-1.9.2/numpy/core/src/multiarray/number.c +0 -1057
  514. numpy-1.9.2/numpy/core/src/multiarray/number.h +0 -76
  515. numpy-1.9.2/numpy/core/src/multiarray/numpymemoryview.c +0 -309
  516. numpy-1.9.2/numpy/core/src/multiarray/numpyos.c +0 -683
  517. numpy-1.9.2/numpy/core/src/multiarray/scalarapi.c +0 -861
  518. numpy-1.9.2/numpy/core/src/multiarray/scalartypes.c.src +0 -4270
  519. numpy-1.9.2/numpy/core/src/multiarray/scalartypes.h +0 -52
  520. numpy-1.9.2/numpy/core/src/multiarray/shape.c +0 -1141
  521. numpy-1.9.2/numpy/core/src/multiarray/ucsnarrow.c +0 -173
  522. numpy-1.9.2/numpy/core/src/npymath/ieee754.c.src +0 -814
  523. numpy-1.9.2/numpy/core/src/npymath/npy_math.c.src +0 -527
  524. numpy-1.9.2/numpy/core/src/npymath/npy_math_complex.c.src +0 -291
  525. numpy-1.9.2/numpy/core/src/npymath/npy_math_private.h +0 -539
  526. numpy-1.9.2/numpy/core/src/npysort/heapsort.c.src +0 -341
  527. numpy-1.9.2/numpy/core/src/npysort/mergesort.c.src +0 -428
  528. numpy-1.9.2/numpy/core/src/npysort/npysort_common.h +0 -367
  529. numpy-1.9.2/numpy/core/src/npysort/quicksort.c.src +0 -363
  530. numpy-1.9.2/numpy/core/src/npysort/selection.c.src +0 -474
  531. numpy-1.9.2/numpy/core/src/private/npy_config.h +0 -44
  532. numpy-1.9.2/numpy/core/src/private/npy_partition.h.src +0 -138
  533. numpy-1.9.2/numpy/core/src/private/npy_sort.h +0 -194
  534. numpy-1.9.2/numpy/core/src/private/scalarmathmodule.h.src +0 -42
  535. numpy-1.9.2/numpy/core/src/private/ufunc_override.h +0 -384
  536. numpy-1.9.2/numpy/core/src/scalarmathmodule.c.src +0 -1980
  537. numpy-1.9.2/numpy/core/src/umath/funcs.inc.src +0 -715
  538. numpy-1.9.2/numpy/core/src/umath/loops.c.src +0 -2654
  539. numpy-1.9.2/numpy/core/src/umath/loops.h.src +0 -501
  540. numpy-1.9.2/numpy/core/src/umath/operand_flag_tests.c.src +0 -105
  541. numpy-1.9.2/numpy/core/src/umath/simd.inc.src +0 -881
  542. numpy-1.9.2/numpy/core/src/umath/test_rational.c.src +0 -1404
  543. numpy-1.9.2/numpy/core/src/umath/ufunc_object.c +0 -5520
  544. numpy-1.9.2/numpy/core/src/umath/ufunc_type_resolution.c +0 -2164
  545. numpy-1.9.2/numpy/core/src/umath/umath_tests.c.src +0 -341
  546. numpy-1.9.2/numpy/core/src/umath/umathmodule.c +0 -561
  547. numpy-1.9.2/numpy/core/src/umath/umathmodule_onefile.c +0 -6
  548. numpy-1.9.2/numpy/core/tests/test_abc.py +0 -45
  549. numpy-1.9.2/numpy/core/tests/test_api.py +0 -514
  550. numpy-1.9.2/numpy/core/tests/test_arrayprint.py +0 -167
  551. numpy-1.9.2/numpy/core/tests/test_blasdot.py +0 -249
  552. numpy-1.9.2/numpy/core/tests/test_datetime.py +0 -1781
  553. numpy-1.9.2/numpy/core/tests/test_defchararray.py +0 -642
  554. numpy-1.9.2/numpy/core/tests/test_deprecations.py +0 -512
  555. numpy-1.9.2/numpy/core/tests/test_dtype.py +0 -542
  556. numpy-1.9.2/numpy/core/tests/test_einsum.py +0 -583
  557. numpy-1.9.2/numpy/core/tests/test_errstate.py +0 -51
  558. numpy-1.9.2/numpy/core/tests/test_function_base.py +0 -111
  559. numpy-1.9.2/numpy/core/tests/test_getlimits.py +0 -86
  560. numpy-1.9.2/numpy/core/tests/test_half.py +0 -439
  561. numpy-1.9.2/numpy/core/tests/test_indexerrors.py +0 -127
  562. numpy-1.9.2/numpy/core/tests/test_indexing.py +0 -1014
  563. numpy-1.9.2/numpy/core/tests/test_item_selection.py +0 -70
  564. numpy-1.9.2/numpy/core/tests/test_machar.py +0 -30
  565. numpy-1.9.2/numpy/core/tests/test_memmap.py +0 -127
  566. numpy-1.9.2/numpy/core/tests/test_multiarray.py +0 -4645
  567. numpy-1.9.2/numpy/core/tests/test_multiarray_assignment.py +0 -80
  568. numpy-1.9.2/numpy/core/tests/test_nditer.py +0 -2630
  569. numpy-1.9.2/numpy/core/tests/test_numeric.py +0 -2117
  570. numpy-1.9.2/numpy/core/tests/test_numerictypes.py +0 -377
  571. numpy-1.9.2/numpy/core/tests/test_print.py +0 -245
  572. numpy-1.9.2/numpy/core/tests/test_records.py +0 -185
  573. numpy-1.9.2/numpy/core/tests/test_regression.py +0 -2108
  574. numpy-1.9.2/numpy/core/tests/test_scalarinherit.py +0 -34
  575. numpy-1.9.2/numpy/core/tests/test_scalarmath.py +0 -275
  576. numpy-1.9.2/numpy/core/tests/test_shape_base.py +0 -250
  577. numpy-1.9.2/numpy/core/tests/test_ufunc.py +0 -1153
  578. numpy-1.9.2/numpy/core/tests/test_umath.py +0 -1695
  579. numpy-1.9.2/numpy/core/tests/test_umath_complex.py +0 -537
  580. numpy-1.9.2/numpy/core/tests/test_unicode.py +0 -357
  581. numpy-1.9.2/numpy/distutils/__init__.py +0 -39
  582. numpy-1.9.2/numpy/distutils/ccompiler.py +0 -656
  583. numpy-1.9.2/numpy/distutils/command/autodist.py +0 -43
  584. numpy-1.9.2/numpy/distutils/command/build.py +0 -39
  585. numpy-1.9.2/numpy/distutils/command/build_clib.py +0 -284
  586. numpy-1.9.2/numpy/distutils/command/build_ext.py +0 -503
  587. numpy-1.9.2/numpy/distutils/command/config.py +0 -476
  588. numpy-1.9.2/numpy/distutils/exec_command.py +0 -618
  589. numpy-1.9.2/numpy/distutils/fcompiler/compaq.py +0 -128
  590. numpy-1.9.2/numpy/distutils/fcompiler/gnu.py +0 -390
  591. numpy-1.9.2/numpy/distutils/fcompiler/intel.py +0 -205
  592. numpy-1.9.2/numpy/distutils/fcompiler/pg.py +0 -60
  593. numpy-1.9.2/numpy/distutils/fcompiler/sun.py +0 -52
  594. numpy-1.9.2/numpy/distutils/intelccompiler.py +0 -45
  595. numpy-1.9.2/numpy/distutils/lib2def.py +0 -116
  596. numpy-1.9.2/numpy/distutils/mingw32ccompiler.py +0 -582
  597. numpy-1.9.2/numpy/distutils/misc_util.py +0 -2271
  598. numpy-1.9.2/numpy/distutils/npy_pkg_config.py +0 -464
  599. numpy-1.9.2/numpy/distutils/system_info.py +0 -2319
  600. numpy-1.9.2/numpy/distutils/tests/f2py_ext/tests/test_fib2.py +0 -13
  601. numpy-1.9.2/numpy/distutils/tests/f2py_f90_ext/tests/test_foo.py +0 -12
  602. numpy-1.9.2/numpy/distutils/tests/gen_ext/tests/test_fib3.py +0 -12
  603. numpy-1.9.2/numpy/distutils/tests/pyrex_ext/tests/test_primes.py +0 -14
  604. numpy-1.9.2/numpy/distutils/tests/swig_ext/tests/test_example.py +0 -18
  605. numpy-1.9.2/numpy/distutils/tests/swig_ext/tests/test_example2.py +0 -16
  606. numpy-1.9.2/numpy/distutils/tests/test_fcompiler_gnu.py +0 -53
  607. numpy-1.9.2/numpy/distutils/tests/test_fcompiler_intel.py +0 -36
  608. numpy-1.9.2/numpy/distutils/tests/test_misc_util.py +0 -75
  609. numpy-1.9.2/numpy/distutils/tests/test_npy_pkg_config.py +0 -98
  610. numpy-1.9.2/numpy/distutils/unixccompiler.py +0 -113
  611. numpy-1.9.2/numpy/doc/byteswapping.py +0 -147
  612. numpy-1.9.2/numpy/doc/creation.py +0 -144
  613. numpy-1.9.2/numpy/doc/glossary.py +0 -418
  614. numpy-1.9.2/numpy/doc/indexing.py +0 -437
  615. numpy-1.9.2/numpy/doc/structured_arrays.py +0 -223
  616. numpy-1.9.2/numpy/f2py/__init__.py +0 -49
  617. numpy-1.9.2/numpy/f2py/auxfuncs.py +0 -711
  618. numpy-1.9.2/numpy/f2py/capi_maps.py +0 -773
  619. numpy-1.9.2/numpy/f2py/cb_rules.py +0 -539
  620. numpy-1.9.2/numpy/f2py/cfuncs.py +0 -1224
  621. numpy-1.9.2/numpy/f2py/common_rules.py +0 -132
  622. numpy-1.9.2/numpy/f2py/crackfortran.py +0 -2870
  623. numpy-1.9.2/numpy/f2py/diagnose.py +0 -149
  624. numpy-1.9.2/numpy/f2py/f2py2e.py +0 -598
  625. numpy-1.9.2/numpy/f2py/f2py_testing.py +0 -46
  626. numpy-1.9.2/numpy/f2py/f90mod_rules.py +0 -246
  627. numpy-1.9.2/numpy/f2py/func2subr.py +0 -291
  628. numpy-1.9.2/numpy/f2py/rules.py +0 -1448
  629. numpy-1.9.2/numpy/f2py/setup.py +0 -129
  630. numpy-1.9.2/numpy/f2py/src/fortranobject.c +0 -972
  631. numpy-1.9.2/numpy/f2py/src/fortranobject.h +0 -162
  632. numpy-1.9.2/numpy/f2py/tests/src/array_from_pyobj/wrapmodule.c +0 -223
  633. numpy-1.9.2/numpy/f2py/tests/test_array_from_pyobj.py +0 -559
  634. numpy-1.9.2/numpy/f2py/tests/test_assumed_shape.py +0 -37
  635. numpy-1.9.2/numpy/f2py/tests/test_callback.py +0 -132
  636. numpy-1.9.2/numpy/f2py/tests/test_kind.py +0 -36
  637. numpy-1.9.2/numpy/f2py/tests/test_mixed.py +0 -41
  638. numpy-1.9.2/numpy/f2py/tests/test_regression.py +0 -32
  639. numpy-1.9.2/numpy/f2py/tests/test_return_character.py +0 -142
  640. numpy-1.9.2/numpy/f2py/tests/test_return_complex.py +0 -169
  641. numpy-1.9.2/numpy/f2py/tests/test_return_integer.py +0 -178
  642. numpy-1.9.2/numpy/f2py/tests/test_return_logical.py +0 -187
  643. numpy-1.9.2/numpy/f2py/tests/test_return_real.py +0 -203
  644. numpy-1.9.2/numpy/f2py/tests/test_size.py +0 -47
  645. numpy-1.9.2/numpy/f2py/tests/util.py +0 -353
  646. numpy-1.9.2/numpy/f2py/use_rules.py +0 -109
  647. numpy-1.9.2/numpy/fft/fftpack.c +0 -1501
  648. numpy-1.9.2/numpy/fft/fftpack.h +0 -28
  649. numpy-1.9.2/numpy/fft/fftpack.py +0 -1169
  650. numpy-1.9.2/numpy/fft/fftpack_litemodule.c +0 -371
  651. numpy-1.9.2/numpy/fft/info.py +0 -179
  652. numpy-1.9.2/numpy/fft/setup.py +0 -20
  653. numpy-1.9.2/numpy/fft/tests/test_fftpack.py +0 -75
  654. numpy-1.9.2/numpy/fft/tests/test_helper.py +0 -78
  655. numpy-1.9.2/numpy/lib/_iotools.py +0 -891
  656. numpy-1.9.2/numpy/lib/arraypad.py +0 -1475
  657. numpy-1.9.2/numpy/lib/arraysetops.py +0 -464
  658. numpy-1.9.2/numpy/lib/arrayterator.py +0 -226
  659. numpy-1.9.2/numpy/lib/financial.py +0 -737
  660. numpy-1.9.2/numpy/lib/format.py +0 -771
  661. numpy-1.9.2/numpy/lib/function_base.py +0 -3884
  662. numpy-1.9.2/numpy/lib/index_tricks.py +0 -869
  663. numpy-1.9.2/numpy/lib/info.py +0 -151
  664. numpy-1.9.2/numpy/lib/nanfunctions.py +0 -1158
  665. numpy-1.9.2/numpy/lib/npyio.py +0 -1918
  666. numpy-1.9.2/numpy/lib/polynomial.py +0 -1271
  667. numpy-1.9.2/numpy/lib/recfunctions.py +0 -1003
  668. numpy-1.9.2/numpy/lib/setup.py +0 -23
  669. numpy-1.9.2/numpy/lib/shape_base.py +0 -865
  670. numpy-1.9.2/numpy/lib/src/_compiled_base.c +0 -1761
  671. numpy-1.9.2/numpy/lib/stride_tricks.py +0 -123
  672. numpy-1.9.2/numpy/lib/tests/test__iotools.py +0 -326
  673. numpy-1.9.2/numpy/lib/tests/test__version.py +0 -57
  674. numpy-1.9.2/numpy/lib/tests/test_arraypad.py +0 -560
  675. numpy-1.9.2/numpy/lib/tests/test_arraysetops.py +0 -301
  676. numpy-1.9.2/numpy/lib/tests/test_financial.py +0 -160
  677. numpy-1.9.2/numpy/lib/tests/test_format.py +0 -716
  678. numpy-1.9.2/numpy/lib/tests/test_function_base.py +0 -2145
  679. numpy-1.9.2/numpy/lib/tests/test_index_tricks.py +0 -289
  680. numpy-1.9.2/numpy/lib/tests/test_io.py +0 -1754
  681. numpy-1.9.2/numpy/lib/tests/test_nanfunctions.py +0 -774
  682. numpy-1.9.2/numpy/lib/tests/test_polynomial.py +0 -177
  683. numpy-1.9.2/numpy/lib/tests/test_recfunctions.py +0 -705
  684. numpy-1.9.2/numpy/lib/tests/test_shape_base.py +0 -368
  685. numpy-1.9.2/numpy/lib/tests/test_stride_tricks.py +0 -238
  686. numpy-1.9.2/numpy/lib/tests/test_twodim_base.py +0 -504
  687. numpy-1.9.2/numpy/lib/tests/test_type_check.py +0 -328
  688. numpy-1.9.2/numpy/lib/twodim_base.py +0 -1003
  689. numpy-1.9.2/numpy/lib/type_check.py +0 -605
  690. numpy-1.9.2/numpy/lib/utils.py +0 -1176
  691. numpy-1.9.2/numpy/linalg/lapack_lite/python_xerbla.c +0 -47
  692. numpy-1.9.2/numpy/linalg/lapack_litemodule.c +0 -362
  693. numpy-1.9.2/numpy/linalg/linalg.py +0 -2136
  694. numpy-1.9.2/numpy/linalg/tests/test_build.py +0 -53
  695. numpy-1.9.2/numpy/linalg/tests/test_linalg.py +0 -1156
  696. numpy-1.9.2/numpy/linalg/tests/test_regression.py +0 -90
  697. numpy-1.9.2/numpy/linalg/umath_linalg.c.src +0 -3210
  698. numpy-1.9.2/numpy/ma/__init__.py +0 -58
  699. numpy-1.9.2/numpy/ma/bench.py +0 -166
  700. numpy-1.9.2/numpy/ma/core.py +0 -7374
  701. numpy-1.9.2/numpy/ma/extras.py +0 -1932
  702. numpy-1.9.2/numpy/ma/mrecords.py +0 -734
  703. numpy-1.9.2/numpy/ma/setup.py +0 -20
  704. numpy-1.9.2/numpy/ma/tests/test_core.py +0 -3706
  705. numpy-1.9.2/numpy/ma/tests/test_extras.py +0 -954
  706. numpy-1.9.2/numpy/ma/tests/test_mrecords.py +0 -521
  707. numpy-1.9.2/numpy/ma/tests/test_old_ma.py +0 -869
  708. numpy-1.9.2/numpy/ma/tests/test_regression.py +0 -75
  709. numpy-1.9.2/numpy/ma/tests/test_subclassing.py +0 -236
  710. numpy-1.9.2/numpy/ma/testutils.py +0 -240
  711. numpy-1.9.2/numpy/ma/timer_comparison.py +0 -459
  712. numpy-1.9.2/numpy/matlib.py +0 -358
  713. numpy-1.9.2/numpy/matrixlib/defmatrix.py +0 -1094
  714. numpy-1.9.2/numpy/matrixlib/tests/test_defmatrix.py +0 -400
  715. numpy-1.9.2/numpy/matrixlib/tests/test_multiarray.py +0 -18
  716. numpy-1.9.2/numpy/matrixlib/tests/test_numeric.py +0 -10
  717. numpy-1.9.2/numpy/matrixlib/tests/test_regression.py +0 -34
  718. numpy-1.9.2/numpy/polynomial/_polybase.py +0 -962
  719. numpy-1.9.2/numpy/polynomial/chebyshev.py +0 -2056
  720. numpy-1.9.2/numpy/polynomial/hermite.py +0 -1789
  721. numpy-1.9.2/numpy/polynomial/hermite_e.py +0 -1786
  722. numpy-1.9.2/numpy/polynomial/laguerre.py +0 -1781
  723. numpy-1.9.2/numpy/polynomial/legendre.py +0 -1809
  724. numpy-1.9.2/numpy/polynomial/polytemplate.py +0 -927
  725. numpy-1.9.2/numpy/polynomial/polyutils.py +0 -403
  726. numpy-1.9.2/numpy/random/mtrand/distributions.c +0 -892
  727. numpy-1.9.2/numpy/random/mtrand/mtrand.c +0 -31204
  728. numpy-1.9.2/numpy/random/mtrand/mtrand.pyx +0 -4706
  729. numpy-1.9.2/numpy/random/setup.py +0 -74
  730. numpy-1.9.2/numpy/random/tests/test_random.py +0 -707
  731. numpy-1.9.2/numpy/random/tests/test_regression.py +0 -86
  732. numpy-1.9.2/numpy/setup.py +0 -27
  733. numpy-1.9.2/numpy/testing/__init__.py +0 -16
  734. numpy-1.9.2/numpy/testing/decorators.py +0 -271
  735. numpy-1.9.2/numpy/testing/noseclasses.py +0 -353
  736. numpy-1.9.2/numpy/testing/nosetester.py +0 -504
  737. numpy-1.9.2/numpy/testing/print_coercion_tables.py +0 -89
  738. numpy-1.9.2/numpy/testing/setup.py +0 -20
  739. numpy-1.9.2/numpy/testing/tests/test_decorators.py +0 -185
  740. numpy-1.9.2/numpy/testing/tests/test_utils.py +0 -558
  741. numpy-1.9.2/numpy/testing/utils.py +0 -1715
  742. numpy-1.9.2/numpy/tests/test_ctypeslib.py +0 -102
  743. numpy-1.9.2/numpy/tests/test_matlib.py +0 -55
  744. numpy-1.9.2/numpy/version.py +0 -10
  745. numpy-1.9.2/setup.py +0 -251
  746. numpy-1.9.2/site.cfg.example +0 -157
  747. numpy-1.9.2/tools/swig/README +0 -135
  748. numpy-1.9.2/tools/swig/numpy.i +0 -3085
  749. numpy-1.9.2/tools/swig/test/Array.i +0 -102
  750. numpy-1.9.2/tools/swig/test/Makefile +0 -34
  751. numpy-1.9.2/tools/swig/test/setup.py +0 -64
  752. numpy-1.9.2/tools/swig/test/testArray.py +0 -284
  753. numpy-1.9.2/tools/swig/test/testFarray.py +0 -159
  754. numpy-1.9.2/tools/swig/test/testFortran.py +0 -173
  755. numpy-1.9.2/tools/swig/test/testMatrix.py +0 -362
  756. numpy-1.9.2/tools/swig/test/testSuperTensor.py +0 -388
  757. numpy-1.9.2/tools/swig/test/testTensor.py +0 -402
  758. numpy-1.9.2/tools/swig/test/testVector.py +0 -381
  759. {numpy-1.9.2 → numpy-1.10.0.post2}/BENTO_BUILD.txt +0 -0
  760. {numpy-1.9.2 → numpy-1.10.0.post2}/COMPATIBILITY +0 -0
  761. {numpy-1.9.2 → numpy-1.10.0.post2}/DEV_README.txt +0 -0
  762. {numpy-1.9.2 → numpy-1.10.0.post2}/README.txt +0 -0
  763. {numpy-1.9.2 → numpy-1.10.0.post2}/THANKS.txt +0 -0
  764. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/Makefile +0 -0
  765. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/BUGS.txt +0 -0
  766. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/FAQ.txt +0 -0
  767. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/HISTORY.txt +0 -0
  768. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/Makefile +0 -0
  769. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/OLDNEWS.txt +0 -0
  770. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/README.txt +0 -0
  771. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/Release-1.x.txt +0 -0
  772. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/Release-2.x.txt +0 -0
  773. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/Release-3.x.txt +0 -0
  774. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/Release-4.x.txt +0 -0
  775. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/TESTING.txt +0 -0
  776. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/THANKS.txt +0 -0
  777. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/TODO.txt +0 -0
  778. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/apps.tex +0 -0
  779. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/bugs.tex +0 -0
  780. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/collectinput.py +0 -0
  781. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/commands.tex +0 -0
  782. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/default.css +0 -0
  783. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/docutils.conf +0 -0
  784. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/ex1/arr.f +0 -0
  785. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/ex1/bar.f +0 -0
  786. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/ex1/foo.f +0 -0
  787. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/ex1/foobar-smart.f90 +0 -0
  788. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/ex1/foobar.f90 +0 -0
  789. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/ex1/foobarmodule.tex +0 -0
  790. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/ex1/runme +0 -0
  791. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/f2py.1 +0 -0
  792. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/f2py2e.tex +0 -0
  793. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/f2python9-final/README.txt +0 -0
  794. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/f2python9-final/aerostructure.jpg +0 -0
  795. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/f2python9-final/flow.jpg +0 -0
  796. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/f2python9-final/mk_html.sh +0 -0
  797. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/f2python9-final/mk_pdf.sh +0 -0
  798. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/f2python9-final/mk_ps.sh +0 -0
  799. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/f2python9-final/src/examples/exp1.f +0 -0
  800. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/f2python9-final/src/examples/exp1mess.txt +0 -0
  801. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/f2python9-final/src/examples/exp1session.txt +0 -0
  802. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/f2python9-final/src/examples/foo.pyf +0 -0
  803. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/f2python9-final/src/examples/foom.pyf +0 -0
  804. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/f2python9-final/structure.jpg +0 -0
  805. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/fortranobject.tex +0 -0
  806. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/hello.f +0 -0
  807. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/index.html +0 -0
  808. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/intro.tex +0 -0
  809. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/multiarray/array_from_pyobj.c +0 -0
  810. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/multiarray/bar.c +0 -0
  811. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/multiarray/foo.f +0 -0
  812. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/multiarray/fortran_array_from_pyobj.txt +0 -0
  813. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/multiarray/fun.pyf +0 -0
  814. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/multiarray/run.pyf +0 -0
  815. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/multiarray/transpose.txt +0 -0
  816. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/multiarrays.txt +0 -0
  817. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/notes.tex +0 -0
  818. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/oldnews.html +0 -0
  819. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/options.tex +0 -0
  820. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/pyforttest.pyf +0 -0
  821. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/pytest.py +0 -0
  822. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/python9.tex +0 -0
  823. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/signaturefile.tex +0 -0
  824. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/simple.f +0 -0
  825. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/simple_session.dat +0 -0
  826. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/using_F_compiler.txt +0 -0
  827. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/f2py/win32_notes.txt +0 -0
  828. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/postprocess.py +0 -0
  829. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/release/1.3.0-notes.rst +0 -0
  830. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/release/1.4.0-notes.rst +0 -0
  831. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/release/1.5.0-notes.rst +0 -0
  832. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/release/1.6.0-notes.rst +0 -0
  833. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/release/1.6.1-notes.rst +0 -0
  834. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/release/1.6.2-notes.rst +0 -0
  835. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/release/1.7.0-notes.rst +0 -0
  836. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/release/1.7.1-notes.rst +0 -0
  837. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/release/1.7.2-notes.rst +0 -0
  838. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/release/1.8.0-notes.rst +0 -0
  839. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/release/1.8.1-notes.rst +0 -0
  840. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/release/1.8.2-notes.rst +0 -0
  841. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/release/1.9.0-notes.rst +0 -0
  842. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/release/1.9.1-notes.rst +0 -0
  843. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/release/1.9.2-notes.rst +0 -0
  844. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/release/time_based_proposal.rst +0 -0
  845. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/.gitignore +0 -0
  846. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/Makefile +0 -0
  847. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/README.rst +0 -0
  848. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_static/scipyshiny_small.png +0 -0
  849. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/layout.html +0 -0
  850. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/searchbox.html +0 -0
  851. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/sourcelink.html +0 -0
  852. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/css/extend.css +0 -0
  853. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/css/pygments.css +0 -0
  854. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/css/scipy-central.css +0 -0
  855. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/css/spc-bootstrap.css +0 -0
  856. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/css/spc-extend.css +0 -0
  857. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/all-icons.svg +0 -0
  858. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/contents.png +0 -0
  859. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/create-new-account-icon.png +0 -0
  860. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/external-link-icon-shrunk.png +0 -0
  861. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/external-link-icon.png +0 -0
  862. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/external-link-icon.svg +0 -0
  863. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/external-link-list-icon-tiniest.png +0 -0
  864. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/external-link-list-icon-tiny.png +0 -0
  865. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/external-link-list-icon.png +0 -0
  866. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ad.png +0 -0
  867. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ae.png +0 -0
  868. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-af.png +0 -0
  869. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ag.png +0 -0
  870. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ai.png +0 -0
  871. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-al.png +0 -0
  872. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-am.png +0 -0
  873. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ao.png +0 -0
  874. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-aq.png +0 -0
  875. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ar.png +0 -0
  876. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-as.png +0 -0
  877. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-at.png +0 -0
  878. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-au.png +0 -0
  879. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-aw.png +0 -0
  880. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-az.png +0 -0
  881. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ba.png +0 -0
  882. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-bb.png +0 -0
  883. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-bd.png +0 -0
  884. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-be.png +0 -0
  885. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-bf.png +0 -0
  886. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-bg.png +0 -0
  887. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-bh.png +0 -0
  888. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-bi.png +0 -0
  889. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-bj.png +0 -0
  890. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-bl.png +0 -0
  891. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-bm.png +0 -0
  892. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-bn.png +0 -0
  893. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-bo.png +0 -0
  894. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-br.png +0 -0
  895. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-bs.png +0 -0
  896. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-bt.png +0 -0
  897. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-bw.png +0 -0
  898. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-by.png +0 -0
  899. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-bz.png +0 -0
  900. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ca.png +0 -0
  901. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-cc.png +0 -0
  902. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-cd.png +0 -0
  903. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-cf.png +0 -0
  904. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-cg.png +0 -0
  905. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ch.png +0 -0
  906. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ci.png +0 -0
  907. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ck.png +0 -0
  908. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-cl.png +0 -0
  909. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-cm.png +0 -0
  910. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-cn.png +0 -0
  911. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-co.png +0 -0
  912. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-cr.png +0 -0
  913. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-cu.png +0 -0
  914. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-cv.png +0 -0
  915. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-cw.png +0 -0
  916. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-cx.png +0 -0
  917. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-cy.png +0 -0
  918. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-cz.png +0 -0
  919. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-de.png +0 -0
  920. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-dj.png +0 -0
  921. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-dk.png +0 -0
  922. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-dm.png +0 -0
  923. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-do.png +0 -0
  924. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-dz.png +0 -0
  925. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ec.png +0 -0
  926. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ee.png +0 -0
  927. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-eg.png +0 -0
  928. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-er.png +0 -0
  929. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-es.png +0 -0
  930. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-et.png +0 -0
  931. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-fi.png +0 -0
  932. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-fj.png +0 -0
  933. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-fk.png +0 -0
  934. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-fm.png +0 -0
  935. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-fo.png +0 -0
  936. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-fr.png +0 -0
  937. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ga.png +0 -0
  938. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-gb.png +0 -0
  939. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-gd.png +0 -0
  940. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ge.png +0 -0
  941. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-gf.png +0 -0
  942. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-gg.png +0 -0
  943. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-gh.png +0 -0
  944. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-gi.png +0 -0
  945. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-gl.png +0 -0
  946. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-gm.png +0 -0
  947. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-gn.png +0 -0
  948. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-gq.png +0 -0
  949. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-gr.png +0 -0
  950. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-gs.png +0 -0
  951. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-gt.png +0 -0
  952. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-gu.png +0 -0
  953. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-gw.png +0 -0
  954. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-gy.png +0 -0
  955. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-hk.png +0 -0
  956. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-hm.png +0 -0
  957. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-hn.png +0 -0
  958. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-hr.png +0 -0
  959. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ht.png +0 -0
  960. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-hu.png +0 -0
  961. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-id.png +0 -0
  962. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ie.png +0 -0
  963. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-il.png +0 -0
  964. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-im.png +0 -0
  965. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-in.png +0 -0
  966. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-io.png +0 -0
  967. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-iq.png +0 -0
  968. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ir.png +0 -0
  969. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-is.png +0 -0
  970. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-it.png +0 -0
  971. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-je.png +0 -0
  972. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-jm.png +0 -0
  973. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-jo.png +0 -0
  974. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-jp.png +0 -0
  975. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ke.png +0 -0
  976. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-kg.png +0 -0
  977. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-kh.png +0 -0
  978. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ki.png +0 -0
  979. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-km.png +0 -0
  980. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-kn.png +0 -0
  981. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-kp.png +0 -0
  982. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-kr.png +0 -0
  983. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-kw.png +0 -0
  984. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ky.png +0 -0
  985. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-kz.png +0 -0
  986. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-la.png +0 -0
  987. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-lb.png +0 -0
  988. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-lc.png +0 -0
  989. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-li.png +0 -0
  990. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-lk.png +0 -0
  991. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-lr.png +0 -0
  992. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ls.png +0 -0
  993. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-lt.png +0 -0
  994. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-lu.png +0 -0
  995. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-lv.png +0 -0
  996. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ly.png +0 -0
  997. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ma.png +0 -0
  998. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-mc.png +0 -0
  999. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-md.png +0 -0
  1000. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-me.png +0 -0
  1001. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-mf.png +0 -0
  1002. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-mg.png +0 -0
  1003. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-mh.png +0 -0
  1004. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-mk.png +0 -0
  1005. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ml.png +0 -0
  1006. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-mm.png +0 -0
  1007. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-mn.png +0 -0
  1008. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-mo.png +0 -0
  1009. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-mp.png +0 -0
  1010. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-mq.png +0 -0
  1011. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-mr.png +0 -0
  1012. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ms.png +0 -0
  1013. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-mt.png +0 -0
  1014. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-mu.png +0 -0
  1015. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-mv.png +0 -0
  1016. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-mw.png +0 -0
  1017. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-mx.png +0 -0
  1018. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-my.png +0 -0
  1019. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-mz.png +0 -0
  1020. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-na.png +0 -0
  1021. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-nc.png +0 -0
  1022. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ne.png +0 -0
  1023. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-nf.png +0 -0
  1024. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ng.png +0 -0
  1025. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ni.png +0 -0
  1026. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-nl.png +0 -0
  1027. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-no.png +0 -0
  1028. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-np.png +0 -0
  1029. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-nr.png +0 -0
  1030. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-nu.png +0 -0
  1031. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-nz.png +0 -0
  1032. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-om.png +0 -0
  1033. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-pa.png +0 -0
  1034. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-pe.png +0 -0
  1035. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-pf.png +0 -0
  1036. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-pg.png +0 -0
  1037. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ph.png +0 -0
  1038. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-pk.png +0 -0
  1039. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-pl.png +0 -0
  1040. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-pm.png +0 -0
  1041. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-pn.png +0 -0
  1042. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-pr.png +0 -0
  1043. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ps.png +0 -0
  1044. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-pt.png +0 -0
  1045. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-pw.png +0 -0
  1046. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-py.png +0 -0
  1047. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-qa.png +0 -0
  1048. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-re.png +0 -0
  1049. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ro.png +0 -0
  1050. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-rs.png +0 -0
  1051. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ru.png +0 -0
  1052. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-rw.png +0 -0
  1053. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-sa.png +0 -0
  1054. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-sb.png +0 -0
  1055. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-sc.png +0 -0
  1056. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-sd.png +0 -0
  1057. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-se.png +0 -0
  1058. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-sg.png +0 -0
  1059. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-sh.png +0 -0
  1060. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-si.png +0 -0
  1061. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-sj.png +0 -0
  1062. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-sk.png +0 -0
  1063. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-sl.png +0 -0
  1064. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-sm.png +0 -0
  1065. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-sn.png +0 -0
  1066. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-so.png +0 -0
  1067. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-sr.png +0 -0
  1068. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-st.png +0 -0
  1069. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-sv.png +0 -0
  1070. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-sy.png +0 -0
  1071. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-sz.png +0 -0
  1072. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-tc.png +0 -0
  1073. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-td.png +0 -0
  1074. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-tf.png +0 -0
  1075. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-tg.png +0 -0
  1076. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-th.png +0 -0
  1077. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-tj.png +0 -0
  1078. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-tk.png +0 -0
  1079. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-tl.png +0 -0
  1080. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-tm.png +0 -0
  1081. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-tn.png +0 -0
  1082. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-to.png +0 -0
  1083. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-tr.png +0 -0
  1084. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-tt.png +0 -0
  1085. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-tv.png +0 -0
  1086. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-tw.png +0 -0
  1087. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-tz.png +0 -0
  1088. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ua.png +0 -0
  1089. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ug.png +0 -0
  1090. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-um.png +0 -0
  1091. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-us.png +0 -0
  1092. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-uy.png +0 -0
  1093. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-uz.png +0 -0
  1094. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-va.png +0 -0
  1095. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-vc.png +0 -0
  1096. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ve.png +0 -0
  1097. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-vg.png +0 -0
  1098. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-vi.png +0 -0
  1099. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-vn.png +0 -0
  1100. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-vu.png +0 -0
  1101. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-wf.png +0 -0
  1102. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ws.png +0 -0
  1103. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ye.png +0 -0
  1104. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-za.png +0 -0
  1105. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-zm.png +0 -0
  1106. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-zw.png +0 -0
  1107. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/glyphicons-halflings-white.png +0 -0
  1108. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/glyphicons-halflings.png +0 -0
  1109. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/important-icon.png +0 -0
  1110. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/information-icon.png +0 -0
  1111. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/internet-web-browser.png +0 -0
  1112. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/multiple-file-icon-shrunk.png +0 -0
  1113. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/multiple-file-icon.png +0 -0
  1114. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/multiple-file-icon.svg +0 -0
  1115. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/multiple-file-list-icon-tiny.png +0 -0
  1116. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/multiple-file-list-icon.png +0 -0
  1117. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/navigation.png +0 -0
  1118. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/person-list-icon-tiny.png +0 -0
  1119. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/person-list-icon.png +0 -0
  1120. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/scipy-logo.png +0 -0
  1121. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/scipy_org_logo.gif +0 -0
  1122. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/scipycentral_logo.png +0 -0
  1123. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/scipyshiny_small.png +0 -0
  1124. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/send-email-icon.png +0 -0
  1125. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/single-file-icon-shrunk.png +0 -0
  1126. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/single-file-icon.png +0 -0
  1127. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/single-file-icon.svg +0 -0
  1128. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/single-file-list-icon-tiniest.png +0 -0
  1129. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/single-file-list-icon-tiny.png +0 -0
  1130. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/single-file-list-icon.png +0 -0
  1131. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/transparent-pixel.gif +0 -0
  1132. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/ui-anim_basic_16x16.gif +0 -0
  1133. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/js/copybutton.js +0 -0
  1134. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/accordion.less +0 -0
  1135. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/alerts.less +0 -0
  1136. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/bootstrap.less +0 -0
  1137. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/breadcrumbs.less +0 -0
  1138. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/button-groups.less +0 -0
  1139. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/buttons.less +0 -0
  1140. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/carousel.less +0 -0
  1141. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/close.less +0 -0
  1142. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/code.less +0 -0
  1143. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/component-animations.less +0 -0
  1144. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/dropdowns.less +0 -0
  1145. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/forms.less +0 -0
  1146. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/grid.less +0 -0
  1147. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/hero-unit.less +0 -0
  1148. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/labels-badges.less +0 -0
  1149. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/layouts.less +0 -0
  1150. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/media.less +0 -0
  1151. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/mixins.less +0 -0
  1152. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/modals.less +0 -0
  1153. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/navbar.less +0 -0
  1154. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/navs.less +0 -0
  1155. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/pager.less +0 -0
  1156. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/pagination.less +0 -0
  1157. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/popovers.less +0 -0
  1158. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/progress-bars.less +0 -0
  1159. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/reset.less +0 -0
  1160. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/responsive-1200px-min.less +0 -0
  1161. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/responsive-767px-max.less +0 -0
  1162. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/responsive-768px-979px.less +0 -0
  1163. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/responsive-navbar.less +0 -0
  1164. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/responsive-utilities.less +0 -0
  1165. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/responsive.less +0 -0
  1166. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/scaffolding.less +0 -0
  1167. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/sprites.less +0 -0
  1168. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/tables.less +0 -0
  1169. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/thumbnails.less +0 -0
  1170. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/tooltip.less +0 -0
  1171. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/type.less +0 -0
  1172. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/utilities.less +0 -0
  1173. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/variables.less +0 -0
  1174. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/wells.less +0 -0
  1175. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/spc-bootstrap.less +0 -0
  1176. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/spc-content.less +0 -0
  1177. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/spc-extend.less +0 -0
  1178. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/spc-footer.less +0 -0
  1179. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/spc-header.less +0 -0
  1180. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/spc-rightsidebar.less +0 -0
  1181. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/spc-utils.less +0 -0
  1182. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/scipy.css_t +0 -0
  1183. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/theme.conf +0 -0
  1184. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/conf.py +0 -0
  1185. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/index.rst +0 -0
  1186. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/test_autodoc.rst +0 -0
  1187. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/test_autodoc_2.rst +0 -0
  1188. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/test_autodoc_3.rst +0 -0
  1189. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/test_autodoc_4.rst +0 -0
  1190. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/test_optimize.rst +0 -0
  1191. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/_templates/autosummary/class.rst +0 -0
  1192. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/_templates/indexcontent.html +0 -0
  1193. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/_templates/indexsidebar.html +0 -0
  1194. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/_templates/layout.html +0 -0
  1195. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/about.rst +0 -0
  1196. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/bugs.rst +0 -0
  1197. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/contents.rst +0 -0
  1198. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/dev/gitwash/configure_git.rst +0 -0
  1199. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/dev/gitwash/development_setup.rst +0 -0
  1200. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/dev/gitwash/dot2_dot3.rst +0 -0
  1201. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/dev/gitwash/following_latest.rst +0 -0
  1202. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/dev/gitwash/forking_button.png +0 -0
  1203. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/dev/gitwash/git_development.rst +0 -0
  1204. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/dev/gitwash/git_intro.rst +0 -0
  1205. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/dev/gitwash/git_resources.rst +0 -0
  1206. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/dev/gitwash/pull_button.png +0 -0
  1207. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/dev/gitwash_links.txt +0 -0
  1208. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/f2py/advanced.rst +0 -0
  1209. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/f2py/allocarr.f90 +0 -0
  1210. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/f2py/allocarr_session.dat +0 -0
  1211. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/f2py/array.f +0 -0
  1212. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/f2py/array_session.dat +0 -0
  1213. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/f2py/calculate.f +0 -0
  1214. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/f2py/calculate_session.dat +0 -0
  1215. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/f2py/callback.f +0 -0
  1216. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/f2py/callback2.pyf +0 -0
  1217. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/f2py/callback_session.dat +0 -0
  1218. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/f2py/common.f +0 -0
  1219. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/f2py/common_session.dat +0 -0
  1220. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/f2py/compile_session.dat +0 -0
  1221. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/f2py/distutils.rst +0 -0
  1222. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/f2py/extcallback.f +0 -0
  1223. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/f2py/extcallback_session.dat +0 -0
  1224. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/f2py/fib1.f +0 -0
  1225. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/f2py/fib1.pyf +0 -0
  1226. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/f2py/fib2.pyf +0 -0
  1227. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/f2py/fib3.f +0 -0
  1228. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/f2py/ftype.f +0 -0
  1229. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/f2py/ftype_session.dat +0 -0
  1230. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/f2py/getting-started.rst +0 -0
  1231. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/f2py/index.rst +0 -0
  1232. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/f2py/moddata.f90 +0 -0
  1233. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/f2py/moddata_session.dat +0 -0
  1234. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/f2py/python-usage.rst +0 -0
  1235. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/f2py/run_main_session.dat +0 -0
  1236. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/f2py/scalar.f +0 -0
  1237. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/f2py/scalar_session.dat +0 -0
  1238. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/f2py/setup_example.py +0 -0
  1239. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/f2py/signature-file.rst +0 -0
  1240. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/f2py/spam.pyf +0 -0
  1241. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/f2py/spam_session.dat +0 -0
  1242. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/f2py/string.f +0 -0
  1243. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/f2py/string_session.dat +0 -0
  1244. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/f2py/usage.rst +0 -0
  1245. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/f2py/var.pyf +0 -0
  1246. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/f2py/var_session.dat +0 -0
  1247. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/glossary.rst +0 -0
  1248. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/license.rst +0 -0
  1249. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/neps/datetime-proposal.rst +0 -0
  1250. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/neps/datetime-proposal3.rst +0 -0
  1251. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/neps/deferred-ufunc-evaluation.rst +0 -0
  1252. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/neps/generalized-ufuncs.rst +0 -0
  1253. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/neps/groupby_additions.rst +0 -0
  1254. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/neps/index.rst +0 -0
  1255. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/neps/math_config_clean.rst +0 -0
  1256. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/neps/missing-data.rst +0 -0
  1257. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/neps/new-iterator-ufunc.rst +0 -0
  1258. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/neps/newbugtracker.rst +0 -0
  1259. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/neps/npy-format.rst +0 -0
  1260. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/neps/structured_array_extensions.rst +0 -0
  1261. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/neps/ufunc-overrides.rst +0 -0
  1262. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/neps/warnfix.rst +0 -0
  1263. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/arrays.datetime.rst +0 -0
  1264. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/arrays.nditer.rst +0 -0
  1265. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/arrays.rst +0 -0
  1266. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/c-api.deprecations.rst +0 -0
  1267. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/c-api.rst +0 -0
  1268. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/distutils.rst +0 -0
  1269. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/figures/dtype-hierarchy.dia +0 -0
  1270. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/figures/dtype-hierarchy.pdf +0 -0
  1271. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/figures/dtype-hierarchy.png +0 -0
  1272. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/figures/threefundamental.fig +0 -0
  1273. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/figures/threefundamental.pdf +0 -0
  1274. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/figures/threefundamental.png +0 -0
  1275. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/internals.rst +0 -0
  1276. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/maskedarray.baseclass.rst +0 -0
  1277. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/maskedarray.generic.rst +0 -0
  1278. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/maskedarray.rst +0 -0
  1279. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/routines.array-creation.rst +0 -0
  1280. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/routines.bitwise.rst +0 -0
  1281. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/routines.char.rst +0 -0
  1282. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/routines.ctypeslib.rst +0 -0
  1283. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/routines.datetime.rst +0 -0
  1284. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/routines.dtype.rst +0 -0
  1285. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/routines.dual.rst +0 -0
  1286. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/routines.emath.rst +0 -0
  1287. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/routines.err.rst +0 -0
  1288. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/routines.fft.rst +0 -0
  1289. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/routines.financial.rst +0 -0
  1290. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/routines.functional.rst +0 -0
  1291. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/routines.help.rst +0 -0
  1292. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/routines.indexing.rst +0 -0
  1293. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/routines.logic.rst +0 -0
  1294. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/routines.math.rst +0 -0
  1295. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/routines.matlib.rst +0 -0
  1296. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/routines.numarray.rst +0 -0
  1297. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/routines.oldnumeric.rst +0 -0
  1298. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/routines.other.rst +0 -0
  1299. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/routines.padding.rst +0 -0
  1300. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/routines.polynomials.chebyshev.rst +0 -0
  1301. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/routines.polynomials.classes.rst +0 -0
  1302. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/routines.polynomials.hermite.rst +0 -0
  1303. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/routines.polynomials.hermite_e.rst +0 -0
  1304. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/routines.polynomials.laguerre.rst +0 -0
  1305. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/routines.polynomials.legendre.rst +0 -0
  1306. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/routines.polynomials.package.rst +0 -0
  1307. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/routines.polynomials.poly1d.rst +0 -0
  1308. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/routines.polynomials.polynomial.rst +0 -0
  1309. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/routines.polynomials.rst +0 -0
  1310. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/routines.random.rst +0 -0
  1311. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/routines.rst +0 -0
  1312. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/routines.set.rst +0 -0
  1313. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/routines.testing.rst +0 -0
  1314. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/routines.window.rst +0 -0
  1315. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/reference/swig.rst +0 -0
  1316. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/user/basics.broadcasting.rst +0 -0
  1317. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/user/basics.byteswapping.rst +0 -0
  1318. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/user/basics.creation.rst +0 -0
  1319. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/user/basics.indexing.rst +0 -0
  1320. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/user/basics.io.rst +0 -0
  1321. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/user/basics.rst +0 -0
  1322. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/user/basics.subclassing.rst +0 -0
  1323. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/user/basics.types.rst +0 -0
  1324. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/user/c-info.rst +0 -0
  1325. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/user/howtofind.rst +0 -0
  1326. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/user/index.rst +0 -0
  1327. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/user/introduction.rst +0 -0
  1328. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/user/misc.rst +0 -0
  1329. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/user/performance.rst +0 -0
  1330. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/source/user/whatisnumpy.rst +0 -0
  1331. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/sphinxext/.gitignore +0 -0
  1332. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/sphinxext/.travis.yml +0 -0
  1333. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/sphinxext/LICENSE.txt +0 -0
  1334. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/sphinxext/MANIFEST.in +0 -0
  1335. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/sphinxext/README.rst +0 -0
  1336. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/sphinxext/numpydoc/__init__.py +0 -0
  1337. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/sphinxext/numpydoc/comment_eater.py +0 -0
  1338. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/sphinxext/numpydoc/compiler_unparse.py +0 -0
  1339. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/sphinxext/numpydoc/docscrape.py +0 -0
  1340. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/sphinxext/numpydoc/docscrape_sphinx.py +0 -0
  1341. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/sphinxext/numpydoc/linkcode.py +0 -0
  1342. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/sphinxext/numpydoc/numpydoc.py +0 -0
  1343. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/sphinxext/numpydoc/phantom_import.py +0 -0
  1344. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/sphinxext/numpydoc/plot_directive.py +0 -0
  1345. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/sphinxext/numpydoc/tests/test_docscrape.py +0 -0
  1346. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/sphinxext/numpydoc/tests/test_linkcode.py +0 -0
  1347. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/sphinxext/numpydoc/tests/test_phantom_import.py +0 -0
  1348. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/sphinxext/numpydoc/tests/test_plot_directive.py +0 -0
  1349. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/sphinxext/numpydoc/tests/test_traitsdoc.py +0 -0
  1350. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/sphinxext/numpydoc/traitsdoc.py +0 -0
  1351. {numpy-1.9.2 → numpy-1.10.0.post2}/doc/sphinxext/setup.py +0 -0
  1352. {numpy-1.9.2/numpy/core/code_generators → numpy-1.10.0.post2/numpy/_build_utils}/__init__.py +0 -0
  1353. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/compat/__init__.py +0 -0
  1354. {numpy-1.9.2/numpy/distutils/tests/f2py_ext → numpy-1.10.0.post2/numpy/core/code_generators}/__init__.py +0 -0
  1355. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/code_generators/genapi.py +0 -0
  1356. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/code_generators/generate_numpy_api.py +0 -0
  1357. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/cversions.py +0 -0
  1358. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/include/numpy/_neighborhood_iterator_imp.h +0 -0
  1359. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/include/numpy/_numpyconfig.h.in +0 -0
  1360. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/include/numpy/arrayobject.h +0 -0
  1361. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/include/numpy/arrayscalars.h +0 -0
  1362. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/include/numpy/halffloat.h +0 -0
  1363. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/include/numpy/noprefix.h +0 -0
  1364. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/include/numpy/npy_1_7_deprecated_api.h +0 -0
  1365. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/include/numpy/npy_interrupt.h +0 -0
  1366. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/include/numpy/npy_no_deprecated_api.h +0 -0
  1367. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/include/numpy/npy_os.h +0 -0
  1368. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/include/numpy/old_defines.h +0 -0
  1369. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/include/numpy/oldnumeric.h +0 -0
  1370. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/include/numpy/ufuncobject.h +0 -0
  1371. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/include/numpy/utils.h +0 -0
  1372. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/info.py +0 -0
  1373. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/mlib.ini.in +0 -0
  1374. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/npymath.ini.in +0 -0
  1375. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/dummymodule.c +0 -0
  1376. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/multiarray/_datetime.h +0 -0
  1377. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/multiarray/alloc.h +0 -0
  1378. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/multiarray/array_assign.c +0 -0
  1379. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/multiarray/array_assign.h +0 -0
  1380. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/multiarray/array_assign_array.c +0 -0
  1381. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/multiarray/array_assign_scalar.c +0 -0
  1382. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/multiarray/arrayobject.h +0 -0
  1383. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/multiarray/buffer.h +0 -0
  1384. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/multiarray/calculation.h +0 -0
  1385. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/multiarray/conversion_utils.h +0 -0
  1386. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/multiarray/convert.h +0 -0
  1387. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/multiarray/convert_datatype.h +0 -0
  1388. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/multiarray/ctors.h +0 -0
  1389. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/multiarray/datetime_busday.h +0 -0
  1390. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/multiarray/datetime_busdaycal.h +0 -0
  1391. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/multiarray/datetime_strings.h +0 -0
  1392. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/multiarray/descriptor.h +0 -0
  1393. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/multiarray/flagsobject.c +0 -0
  1394. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/multiarray/getset.h +0 -0
  1395. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/multiarray/hashdescr.h +0 -0
  1396. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/multiarray/item_selection.h +0 -0
  1397. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/multiarray/iterators.h +0 -0
  1398. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/multiarray/methods.h +0 -0
  1399. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/multiarray/nditer_impl.h +0 -0
  1400. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/multiarray/nditer_pywrap.h +0 -0
  1401. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/multiarray/nditer_templ.c.src +0 -0
  1402. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/multiarray/numpymemoryview.h +0 -0
  1403. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/multiarray/numpyos.h +0 -0
  1404. {numpy-1.9.2/numpy/core/blasdot → numpy-1.10.0.post2/numpy/core/src/multiarray}/python_xerbla.c +0 -0
  1405. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/multiarray/refcount.c +0 -0
  1406. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/multiarray/refcount.h +0 -0
  1407. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/multiarray/sequence.c +0 -0
  1408. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/multiarray/sequence.h +0 -0
  1409. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/multiarray/shape.h +0 -0
  1410. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/multiarray/ucsnarrow.h +0 -0
  1411. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/multiarray/usertypes.c +0 -0
  1412. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/multiarray/usertypes.h +0 -0
  1413. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/npymath/_signbit.c +0 -0
  1414. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/npymath/halffloat.c +0 -0
  1415. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/npymath/npy_math_common.h +0 -0
  1416. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/npysort/binsearch.c.src +0 -0
  1417. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/private/lowlevel_strided_loops.h +0 -0
  1418. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/private/npy_binsearch.h.src +0 -0
  1419. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/private/npy_fpmath.h +0 -0
  1420. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/private/npy_pycompat.h +0 -0
  1421. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/umath/reduction.c +0 -0
  1422. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/umath/reduction.h +0 -0
  1423. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/umath/struct_ufunc_test.c.src +0 -0
  1424. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/umath/ufunc_object.h +0 -0
  1425. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/src/umath/ufunc_type_resolution.h +0 -0
  1426. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/tests/data/astype_copy.pkl +0 -0
  1427. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/tests/data/recarray_from_file.fits +0 -0
  1428. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/core/tests/test_scalarprint.py +0 -0
  1429. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/ctypeslib.py +0 -0
  1430. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/__version__.py +0 -0
  1431. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/command/__init__.py +0 -0
  1432. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/command/bdist_rpm.py +0 -0
  1433. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/command/build_py.py +0 -0
  1434. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/command/build_scripts.py +0 -0
  1435. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/command/build_src.py +0 -0
  1436. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/command/config_compiler.py +0 -0
  1437. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/command/develop.py +0 -0
  1438. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/command/egg_info.py +0 -0
  1439. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/command/install.py +0 -0
  1440. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/command/install_clib.py +0 -0
  1441. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/command/install_data.py +0 -0
  1442. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/command/install_headers.py +0 -0
  1443. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/command/sdist.py +0 -0
  1444. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/compat.py +0 -0
  1445. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/conv_template.py +0 -0
  1446. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/core.py +0 -0
  1447. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/cpuinfo.py +0 -0
  1448. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/environment.py +0 -0
  1449. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/extension.py +0 -0
  1450. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/fcompiler/__init__.py +0 -0
  1451. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/fcompiler/absoft.py +0 -0
  1452. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/fcompiler/g95.py +0 -0
  1453. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/fcompiler/hpux.py +0 -0
  1454. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/fcompiler/ibm.py +0 -0
  1455. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/fcompiler/lahey.py +0 -0
  1456. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/fcompiler/mips.py +0 -0
  1457. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/fcompiler/nag.py +0 -0
  1458. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/fcompiler/none.py +0 -0
  1459. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/fcompiler/pathf95.py +0 -0
  1460. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/fcompiler/vast.py +0 -0
  1461. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/from_template.py +0 -0
  1462. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/info.py +0 -0
  1463. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/line_endings.py +0 -0
  1464. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/log.py +0 -0
  1465. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/mingw/gfortran_vs2003_hack.c +0 -0
  1466. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/numpy_distribution.py +0 -0
  1467. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/pathccompiler.py +0 -0
  1468. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/setup.py +0 -0
  1469. {numpy-1.9.2/numpy/distutils/tests/f2py_f90_ext → numpy-1.10.0.post2/numpy/distutils/tests/f2py_ext}/__init__.py +0 -0
  1470. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/tests/f2py_ext/setup.py +0 -0
  1471. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/tests/f2py_ext/src/fib1.f +0 -0
  1472. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/tests/f2py_ext/src/fib2.pyf +0 -0
  1473. {numpy-1.9.2/numpy/distutils/tests/gen_ext → numpy-1.10.0.post2/numpy/distutils/tests/f2py_f90_ext}/__init__.py +0 -0
  1474. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/tests/f2py_f90_ext/include/body.f90 +0 -0
  1475. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/tests/f2py_f90_ext/setup.py +0 -0
  1476. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/tests/f2py_f90_ext/src/foo_free.f90 +0 -0
  1477. {numpy-1.9.2/numpy/distutils/tests/pyrex_ext → numpy-1.10.0.post2/numpy/distutils/tests/gen_ext}/__init__.py +0 -0
  1478. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/tests/gen_ext/setup.py +0 -0
  1479. {numpy-1.9.2/numpy/distutils/tests/swig_ext → numpy-1.10.0.post2/numpy/distutils/tests/pyrex_ext}/__init__.py +0 -0
  1480. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/tests/pyrex_ext/primes.pyx +0 -0
  1481. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/tests/pyrex_ext/setup.py +0 -0
  1482. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/tests/setup.py +0 -0
  1483. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/tests/swig_ext/setup.py +0 -0
  1484. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/tests/swig_ext/src/example.c +0 -0
  1485. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/tests/swig_ext/src/example.i +0 -0
  1486. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/tests/swig_ext/src/zoo.cc +0 -0
  1487. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/tests/swig_ext/src/zoo.h +0 -0
  1488. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/tests/swig_ext/src/zoo.i +0 -0
  1489. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/distutils/tests/test_exec_command.py +0 -0
  1490. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/doc/__init__.py +0 -0
  1491. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/doc/basics.py +0 -0
  1492. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/doc/broadcasting.py +0 -0
  1493. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/doc/constants.py +0 -0
  1494. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/doc/howtofind.py +0 -0
  1495. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/doc/internals.py +0 -0
  1496. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/doc/io.py +0 -0
  1497. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/doc/jargon.py +0 -0
  1498. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/doc/methods_vs_functions.py +0 -0
  1499. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/doc/misc.py +0 -0
  1500. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/doc/performance.py +0 -0
  1501. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/doc/subclassing.py +0 -0
  1502. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/doc/ufuncs.py +0 -0
  1503. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/dual.py +0 -0
  1504. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/f2py/__version__.py +0 -0
  1505. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/f2py/info.py +0 -0
  1506. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/f2py/tests/src/assumed_shape/.f2py_f2cmap +0 -0
  1507. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/f2py/tests/src/assumed_shape/foo_free.f90 +0 -0
  1508. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/f2py/tests/src/assumed_shape/foo_mod.f90 +0 -0
  1509. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/f2py/tests/src/assumed_shape/foo_use.f90 +0 -0
  1510. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/f2py/tests/src/assumed_shape/precision.f90 +0 -0
  1511. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/f2py/tests/src/kind/foo.f90 +0 -0
  1512. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/f2py/tests/src/mixed/foo.f +0 -0
  1513. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/f2py/tests/src/mixed/foo_fixed.f90 +0 -0
  1514. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/f2py/tests/src/mixed/foo_free.f90 +0 -0
  1515. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/f2py/tests/src/regression/inout.f90 +0 -0
  1516. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/f2py/tests/src/size/foo.f90 +0 -0
  1517. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/fft/__init__.py +0 -0
  1518. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/fft/helper.py +0 -0
  1519. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/lib/__init__.py +0 -0
  1520. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/lib/_datasource.py +0 -0
  1521. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/lib/_version.py +0 -0
  1522. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/lib/scimath.py +0 -0
  1523. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/lib/tests/data/python3.npy +0 -0
  1524. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/lib/tests/data/win64python2.npy +0 -0
  1525. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/lib/tests/test__datasource.py +0 -0
  1526. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/lib/tests/test_arrayterator.py +0 -0
  1527. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/lib/tests/test_regression.py +0 -0
  1528. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/lib/tests/test_ufunclike.py +0 -0
  1529. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/lib/tests/test_utils.py +0 -0
  1530. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/lib/ufunclike.py +0 -0
  1531. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/lib/user_array.py +0 -0
  1532. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/linalg/__init__.py +0 -0
  1533. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/linalg/info.py +0 -0
  1534. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/linalg/lapack_lite/blas_lite.c +0 -0
  1535. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/linalg/lapack_lite/dlamch.c +0 -0
  1536. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/linalg/lapack_lite/dlapack_lite.c +0 -0
  1537. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/linalg/lapack_lite/f2c.h +0 -0
  1538. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/linalg/lapack_lite/f2c_lite.c +0 -0
  1539. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/linalg/lapack_lite/zlapack_lite.c +0 -0
  1540. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/linalg/setup.py +0 -0
  1541. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/linalg/tests/test_deprecations.py +0 -0
  1542. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/ma/version.py +0 -0
  1543. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/matrixlib/__init__.py +0 -0
  1544. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/matrixlib/setup.py +0 -0
  1545. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/polynomial/__init__.py +0 -0
  1546. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/polynomial/polynomial.py +0 -0
  1547. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/polynomial/setup.py +0 -0
  1548. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/polynomial/tests/test_chebyshev.py +0 -0
  1549. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/polynomial/tests/test_classes.py +0 -0
  1550. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/polynomial/tests/test_hermite.py +0 -0
  1551. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/polynomial/tests/test_hermite_e.py +0 -0
  1552. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/polynomial/tests/test_laguerre.py +0 -0
  1553. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/polynomial/tests/test_legendre.py +0 -0
  1554. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/polynomial/tests/test_polynomial.py +0 -0
  1555. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/polynomial/tests/test_polyutils.py +0 -0
  1556. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/polynomial/tests/test_printing.py +0 -0
  1557. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/random/__init__.py +0 -0
  1558. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/random/info.py +0 -0
  1559. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/random/mtrand/Python.pxi +0 -0
  1560. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/random/mtrand/distributions.h +0 -0
  1561. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/random/mtrand/generate_mtrand_c.py +0 -0
  1562. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/random/mtrand/initarray.c +0 -0
  1563. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/random/mtrand/initarray.h +0 -0
  1564. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/random/mtrand/mtrand_py_helper.h +0 -0
  1565. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/random/mtrand/numpy.pxd +0 -0
  1566. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/random/mtrand/randomkit.c +0 -0
  1567. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/random/mtrand/randomkit.h +0 -0
  1568. {numpy-1.9.2 → numpy-1.10.0.post2}/numpy/testing/tests/test_doctesting.py +0 -0
  1569. {numpy-1.9.2 → numpy-1.10.0.post2}/setupegg.py +0 -0
  1570. {numpy-1.9.2 → numpy-1.10.0.post2}/tools/swig/Makefile +0 -0
  1571. {numpy-1.9.2 → numpy-1.10.0.post2}/tools/swig/pyfragments.swg +0 -0
  1572. {numpy-1.9.2 → numpy-1.10.0.post2}/tools/swig/test/Array1.cxx +0 -0
  1573. {numpy-1.9.2 → numpy-1.10.0.post2}/tools/swig/test/Array1.h +0 -0
  1574. {numpy-1.9.2 → numpy-1.10.0.post2}/tools/swig/test/Array2.cxx +0 -0
  1575. {numpy-1.9.2 → numpy-1.10.0.post2}/tools/swig/test/Array2.h +0 -0
  1576. {numpy-1.9.2 → numpy-1.10.0.post2}/tools/swig/test/Farray.cxx +0 -0
  1577. {numpy-1.9.2 → numpy-1.10.0.post2}/tools/swig/test/Farray.h +0 -0
  1578. {numpy-1.9.2 → numpy-1.10.0.post2}/tools/swig/test/Farray.i +0 -0
  1579. {numpy-1.9.2 → numpy-1.10.0.post2}/tools/swig/test/Fortran.cxx +0 -0
  1580. {numpy-1.9.2 → numpy-1.10.0.post2}/tools/swig/test/Fortran.h +0 -0
  1581. {numpy-1.9.2 → numpy-1.10.0.post2}/tools/swig/test/Fortran.i +0 -0
  1582. {numpy-1.9.2 → numpy-1.10.0.post2}/tools/swig/test/Matrix.cxx +0 -0
  1583. {numpy-1.9.2 → numpy-1.10.0.post2}/tools/swig/test/Matrix.h +0 -0
  1584. {numpy-1.9.2 → numpy-1.10.0.post2}/tools/swig/test/Matrix.i +0 -0
  1585. {numpy-1.9.2 → numpy-1.10.0.post2}/tools/swig/test/SuperTensor.cxx +0 -0
  1586. {numpy-1.9.2 → numpy-1.10.0.post2}/tools/swig/test/SuperTensor.h +0 -0
  1587. {numpy-1.9.2 → numpy-1.10.0.post2}/tools/swig/test/SuperTensor.i +0 -0
  1588. {numpy-1.9.2 → numpy-1.10.0.post2}/tools/swig/test/Tensor.cxx +0 -0
  1589. {numpy-1.9.2 → numpy-1.10.0.post2}/tools/swig/test/Tensor.h +0 -0
  1590. {numpy-1.9.2 → numpy-1.10.0.post2}/tools/swig/test/Tensor.i +0 -0
  1591. {numpy-1.9.2 → numpy-1.10.0.post2}/tools/swig/test/Vector.cxx +0 -0
  1592. {numpy-1.9.2 → numpy-1.10.0.post2}/tools/swig/test/Vector.h +0 -0
  1593. {numpy-1.9.2 → numpy-1.10.0.post2}/tools/swig/test/Vector.i +0 -0
@@ -0,0 +1,4628 @@
1
+ /*
2
+ Python Multiarray Module -- A useful collection of functions for creating and
3
+ using ndarrays
4
+
5
+ Original file
6
+ Copyright (c) 1995, 1996, 1997 Jim Hugunin, hugunin@mit.edu
7
+
8
+ Modified for numpy in 2005
9
+
10
+ Travis E. Oliphant
11
+ oliphant@ee.byu.edu
12
+ Brigham Young University
13
+ */
14
+
15
+ /* $Id: multiarraymodule.c,v 1.36 2005/09/14 00:14:00 teoliphant Exp $ */
16
+
17
+ #define PY_SSIZE_T_CLEAN
18
+ #include "Python.h"
19
+ #include "structmember.h"
20
+
21
+ #define NPY_NO_DEPRECATED_API NPY_API_VERSION
22
+ #define _MULTIARRAYMODULE
23
+ #include <numpy/npy_common.h>
24
+ #include "numpy/arrayobject.h"
25
+ #include "numpy/arrayscalars.h"
26
+
27
+ #include "numpy/npy_math.h"
28
+
29
+ #include "npy_config.h"
30
+ #include "npy_pycompat.h"
31
+ #include "npy_import.h"
32
+
33
+ NPY_NO_EXPORT int NPY_NUMUSERTYPES = 0;
34
+
35
+ /* Internal APIs */
36
+ #include "arraytypes.h"
37
+ #include "arrayobject.h"
38
+ #include "hashdescr.h"
39
+ #include "descriptor.h"
40
+ #include "calculation.h"
41
+ #include "number.h"
42
+ #include "scalartypes.h"
43
+ #include "numpymemoryview.h"
44
+ #include "convert_datatype.h"
45
+ #include "conversion_utils.h"
46
+ #include "nditer_pywrap.h"
47
+ #include "methods.h"
48
+ #include "_datetime.h"
49
+ #include "datetime_strings.h"
50
+ #include "datetime_busday.h"
51
+ #include "datetime_busdaycal.h"
52
+ #include "item_selection.h"
53
+ #include "shape.h"
54
+ #include "ctors.h"
55
+ #include "array_assign.h"
56
+ #include "common.h"
57
+ #include "ufunc_override.h"
58
+ #include "multiarraymodule.h"
59
+ #include "cblasfuncs.h"
60
+ #include "vdot.h"
61
+ #include "templ_common.h" /* for npy_mul_with_overflow_intp */
62
+ #include "compiled_base.h"
63
+
64
+ /* Only here for API compatibility */
65
+ NPY_NO_EXPORT PyTypeObject PyBigArray_Type;
66
+
67
+
68
+ /*NUMPY_API
69
+ * Get Priority from object
70
+ */
71
+ NPY_NO_EXPORT double
72
+ PyArray_GetPriority(PyObject *obj, double default_)
73
+ {
74
+ PyObject *ret;
75
+ double priority = NPY_PRIORITY;
76
+
77
+ if (PyArray_CheckExact(obj)) {
78
+ return priority;
79
+ }
80
+ else if (PyArray_CheckAnyScalarExact(obj)) {
81
+ return NPY_SCALAR_PRIORITY;
82
+ }
83
+
84
+ ret = PyArray_GetAttrString_SuppressException(obj, "__array_priority__");
85
+ if (ret == NULL) {
86
+ return default_;
87
+ }
88
+
89
+ priority = PyFloat_AsDouble(ret);
90
+ Py_DECREF(ret);
91
+ return priority;
92
+ }
93
+
94
+ /*NUMPY_API
95
+ * Multiply a List of ints
96
+ */
97
+ NPY_NO_EXPORT int
98
+ PyArray_MultiplyIntList(int *l1, int n)
99
+ {
100
+ int s = 1;
101
+
102
+ while (n--) {
103
+ s *= (*l1++);
104
+ }
105
+ return s;
106
+ }
107
+
108
+ /*NUMPY_API
109
+ * Multiply a List
110
+ */
111
+ NPY_NO_EXPORT npy_intp
112
+ PyArray_MultiplyList(npy_intp *l1, int n)
113
+ {
114
+ npy_intp s = 1;
115
+
116
+ while (n--) {
117
+ s *= (*l1++);
118
+ }
119
+ return s;
120
+ }
121
+
122
+ /*NUMPY_API
123
+ * Multiply a List of Non-negative numbers with over-flow detection.
124
+ */
125
+ NPY_NO_EXPORT npy_intp
126
+ PyArray_OverflowMultiplyList(npy_intp *l1, int n)
127
+ {
128
+ npy_intp prod = 1;
129
+ int i;
130
+
131
+ for (i = 0; i < n; i++) {
132
+ npy_intp dim = l1[i];
133
+
134
+ if (dim == 0) {
135
+ return 0;
136
+ }
137
+ if (npy_mul_with_overflow_intp(&prod, prod, dim)) {
138
+ return -1;
139
+ }
140
+ }
141
+ return prod;
142
+ }
143
+
144
+ /*NUMPY_API
145
+ * Produce a pointer into array
146
+ */
147
+ NPY_NO_EXPORT void *
148
+ PyArray_GetPtr(PyArrayObject *obj, npy_intp* ind)
149
+ {
150
+ int n = PyArray_NDIM(obj);
151
+ npy_intp *strides = PyArray_STRIDES(obj);
152
+ char *dptr = PyArray_DATA(obj);
153
+
154
+ while (n--) {
155
+ dptr += (*strides++) * (*ind++);
156
+ }
157
+ return (void *)dptr;
158
+ }
159
+
160
+ /*NUMPY_API
161
+ * Compare Lists
162
+ */
163
+ NPY_NO_EXPORT int
164
+ PyArray_CompareLists(npy_intp *l1, npy_intp *l2, int n)
165
+ {
166
+ int i;
167
+
168
+ for (i = 0; i < n; i++) {
169
+ if (l1[i] != l2[i]) {
170
+ return 0;
171
+ }
172
+ }
173
+ return 1;
174
+ }
175
+
176
+ /*
177
+ * simulates a C-style 1-3 dimensional array which can be accesed using
178
+ * ptr[i] or ptr[i][j] or ptr[i][j][k] -- requires pointer allocation
179
+ * for 2-d and 3-d.
180
+ *
181
+ * For 2-d and up, ptr is NOT equivalent to a statically defined
182
+ * 2-d or 3-d array. In particular, it cannot be passed into a
183
+ * function that requires a true pointer to a fixed-size array.
184
+ */
185
+
186
+ /*NUMPY_API
187
+ * Simulate a C-array
188
+ * steals a reference to typedescr -- can be NULL
189
+ */
190
+ NPY_NO_EXPORT int
191
+ PyArray_AsCArray(PyObject **op, void *ptr, npy_intp *dims, int nd,
192
+ PyArray_Descr* typedescr)
193
+ {
194
+ PyArrayObject *ap;
195
+ npy_intp n, m, i, j;
196
+ char **ptr2;
197
+ char ***ptr3;
198
+
199
+ if ((nd < 1) || (nd > 3)) {
200
+ PyErr_SetString(PyExc_ValueError,
201
+ "C arrays of only 1-3 dimensions available");
202
+ Py_XDECREF(typedescr);
203
+ return -1;
204
+ }
205
+ if ((ap = (PyArrayObject*)PyArray_FromAny(*op, typedescr, nd, nd,
206
+ NPY_ARRAY_CARRAY, NULL)) == NULL) {
207
+ return -1;
208
+ }
209
+ switch(nd) {
210
+ case 1:
211
+ *((char **)ptr) = PyArray_DATA(ap);
212
+ break;
213
+ case 2:
214
+ n = PyArray_DIMS(ap)[0];
215
+ ptr2 = (char **)PyArray_malloc(n * sizeof(char *));
216
+ if (!ptr2) {
217
+ goto fail;
218
+ }
219
+ for (i = 0; i < n; i++) {
220
+ ptr2[i] = PyArray_BYTES(ap) + i*PyArray_STRIDES(ap)[0];
221
+ }
222
+ *((char ***)ptr) = ptr2;
223
+ break;
224
+ case 3:
225
+ n = PyArray_DIMS(ap)[0];
226
+ m = PyArray_DIMS(ap)[1];
227
+ ptr3 = (char ***)PyArray_malloc(n*(m+1) * sizeof(char *));
228
+ if (!ptr3) {
229
+ goto fail;
230
+ }
231
+ for (i = 0; i < n; i++) {
232
+ ptr3[i] = (char **) &ptr3[n + m * i];
233
+ for (j = 0; j < m; j++) {
234
+ ptr3[i][j] = PyArray_BYTES(ap) + i*PyArray_STRIDES(ap)[0] + j*PyArray_STRIDES(ap)[1];
235
+ }
236
+ }
237
+ *((char ****)ptr) = ptr3;
238
+ }
239
+ memcpy(dims, PyArray_DIMS(ap), nd*sizeof(npy_intp));
240
+ *op = (PyObject *)ap;
241
+ return 0;
242
+
243
+ fail:
244
+ PyErr_SetString(PyExc_MemoryError, "no memory");
245
+ return -1;
246
+ }
247
+
248
+ /* Deprecated --- Use PyArray_AsCArray instead */
249
+
250
+ /*NUMPY_API
251
+ * Convert to a 1D C-array
252
+ */
253
+ NPY_NO_EXPORT int
254
+ PyArray_As1D(PyObject **op, char **ptr, int *d1, int typecode)
255
+ {
256
+ npy_intp newd1;
257
+ PyArray_Descr *descr;
258
+ static const char msg[] = "PyArray_As1D: use PyArray_AsCArray.";
259
+
260
+ /* 2008-07-14, 1.5 */
261
+ if (DEPRECATE(msg) < 0) {
262
+ return -1;
263
+ }
264
+ descr = PyArray_DescrFromType(typecode);
265
+ if (PyArray_AsCArray(op, (void *)ptr, &newd1, 1, descr) == -1) {
266
+ return -1;
267
+ }
268
+ *d1 = (int) newd1;
269
+ return 0;
270
+ }
271
+
272
+ /*NUMPY_API
273
+ * Convert to a 2D C-array
274
+ */
275
+ NPY_NO_EXPORT int
276
+ PyArray_As2D(PyObject **op, char ***ptr, int *d1, int *d2, int typecode)
277
+ {
278
+ npy_intp newdims[2];
279
+ PyArray_Descr *descr;
280
+ static const char msg[] = "PyArray_As1D: use PyArray_AsCArray.";
281
+
282
+ /* 2008-07-14, 1.5 */
283
+ if (DEPRECATE(msg) < 0) {
284
+ return -1;
285
+ }
286
+ descr = PyArray_DescrFromType(typecode);
287
+ if (PyArray_AsCArray(op, (void *)ptr, newdims, 2, descr) == -1) {
288
+ return -1;
289
+ }
290
+ *d1 = (int ) newdims[0];
291
+ *d2 = (int ) newdims[1];
292
+ return 0;
293
+ }
294
+
295
+ /* End Deprecated */
296
+
297
+ /*NUMPY_API
298
+ * Free pointers created if As2D is called
299
+ */
300
+ NPY_NO_EXPORT int
301
+ PyArray_Free(PyObject *op, void *ptr)
302
+ {
303
+ PyArrayObject *ap = (PyArrayObject *)op;
304
+
305
+ if ((PyArray_NDIM(ap) < 1) || (PyArray_NDIM(ap) > 3)) {
306
+ return -1;
307
+ }
308
+ if (PyArray_NDIM(ap) >= 2) {
309
+ PyArray_free(ptr);
310
+ }
311
+ Py_DECREF(ap);
312
+ return 0;
313
+ }
314
+
315
+
316
+ /*
317
+ * Concatenates a list of ndarrays.
318
+ */
319
+ NPY_NO_EXPORT PyArrayObject *
320
+ PyArray_ConcatenateArrays(int narrays, PyArrayObject **arrays, int axis)
321
+ {
322
+ PyTypeObject *subtype = &PyArray_Type;
323
+ double priority = NPY_PRIORITY;
324
+ int iarrays, idim, ndim;
325
+ npy_intp shape[NPY_MAXDIMS], s, strides[NPY_MAXDIMS];
326
+ int strideperm[NPY_MAXDIMS];
327
+ PyArray_Descr *dtype = NULL;
328
+ PyArrayObject *ret = NULL;
329
+ PyArrayObject_fields *sliding_view = NULL;
330
+ int orig_axis = axis;
331
+
332
+ if (narrays <= 0) {
333
+ PyErr_SetString(PyExc_ValueError,
334
+ "need at least one array to concatenate");
335
+ return NULL;
336
+ }
337
+
338
+ /* All the arrays must have the same 'ndim' */
339
+ ndim = PyArray_NDIM(arrays[0]);
340
+
341
+ if (ndim == 0) {
342
+ PyErr_SetString(PyExc_ValueError,
343
+ "zero-dimensional arrays cannot be concatenated");
344
+ return NULL;
345
+ }
346
+
347
+ /* Handle standard Python negative indexing */
348
+ if (axis < 0) {
349
+ axis += ndim;
350
+ }
351
+
352
+ if (axis < 0 || axis >= ndim) {
353
+ PyErr_Format(PyExc_IndexError,
354
+ "axis %d out of bounds [0, %d)", orig_axis, ndim);
355
+ return NULL;
356
+ }
357
+
358
+ /*
359
+ * Figure out the final concatenated shape starting from the first
360
+ * array's shape.
361
+ */
362
+ memcpy(shape, PyArray_SHAPE(arrays[0]), ndim * sizeof(shape[0]));
363
+ for (iarrays = 1; iarrays < narrays; ++iarrays) {
364
+ npy_intp *arr_shape;
365
+
366
+ if (PyArray_NDIM(arrays[iarrays]) != ndim) {
367
+ PyErr_SetString(PyExc_ValueError,
368
+ "all the input arrays must have same "
369
+ "number of dimensions");
370
+ return NULL;
371
+ }
372
+ arr_shape = PyArray_SHAPE(arrays[iarrays]);
373
+
374
+ for (idim = 0; idim < ndim; ++idim) {
375
+ /* Build up the size of the concatenation axis */
376
+ if (idim == axis) {
377
+ shape[idim] += arr_shape[idim];
378
+ }
379
+ /* Validate that the rest of the dimensions match */
380
+ else if (shape[idim] != arr_shape[idim]) {
381
+ PyErr_SetString(PyExc_ValueError,
382
+ "all the input array dimensions "
383
+ "except for the concatenation axis "
384
+ "must match exactly");
385
+ return NULL;
386
+ }
387
+ }
388
+ }
389
+
390
+ /* Get the priority subtype for the array */
391
+ for (iarrays = 0; iarrays < narrays; ++iarrays) {
392
+ if (Py_TYPE(arrays[iarrays]) != subtype) {
393
+ double pr = PyArray_GetPriority((PyObject *)(arrays[iarrays]), 0.0);
394
+ if (pr > priority) {
395
+ priority = pr;
396
+ subtype = Py_TYPE(arrays[iarrays]);
397
+ }
398
+ }
399
+ }
400
+
401
+ /* Get the resulting dtype from combining all the arrays */
402
+ dtype = PyArray_ResultType(narrays, arrays, 0, NULL);
403
+ if (dtype == NULL) {
404
+ return NULL;
405
+ }
406
+
407
+ /*
408
+ * Figure out the permutation to apply to the strides to match
409
+ * the memory layout of the input arrays, using ambiguity
410
+ * resolution rules matching that of the NpyIter.
411
+ */
412
+ PyArray_CreateMultiSortedStridePerm(narrays, arrays, ndim, strideperm);
413
+ s = dtype->elsize;
414
+ for (idim = ndim-1; idim >= 0; --idim) {
415
+ int iperm = strideperm[idim];
416
+ strides[iperm] = s;
417
+ s *= shape[iperm];
418
+ }
419
+
420
+ /* Allocate the array for the result. This steals the 'dtype' reference. */
421
+ ret = (PyArrayObject *)PyArray_NewFromDescr(subtype,
422
+ dtype,
423
+ ndim,
424
+ shape,
425
+ strides,
426
+ NULL,
427
+ 0,
428
+ NULL);
429
+ if (ret == NULL) {
430
+ return NULL;
431
+ }
432
+
433
+ /*
434
+ * Create a view which slides through ret for assigning the
435
+ * successive input arrays.
436
+ */
437
+ sliding_view = (PyArrayObject_fields *)PyArray_View(ret,
438
+ NULL, &PyArray_Type);
439
+ if (sliding_view == NULL) {
440
+ Py_DECREF(ret);
441
+ return NULL;
442
+ }
443
+ for (iarrays = 0; iarrays < narrays; ++iarrays) {
444
+ /* Set the dimension to match the input array's */
445
+ sliding_view->dimensions[axis] = PyArray_SHAPE(arrays[iarrays])[axis];
446
+
447
+ /* Copy the data for this array */
448
+ if (PyArray_AssignArray((PyArrayObject *)sliding_view, arrays[iarrays],
449
+ NULL, NPY_SAME_KIND_CASTING) < 0) {
450
+ Py_DECREF(sliding_view);
451
+ Py_DECREF(ret);
452
+ return NULL;
453
+ }
454
+
455
+ /* Slide to the start of the next window */
456
+ sliding_view->data += sliding_view->dimensions[axis] *
457
+ sliding_view->strides[axis];
458
+ }
459
+
460
+ Py_DECREF(sliding_view);
461
+ return ret;
462
+ }
463
+
464
+ /*
465
+ * Concatenates a list of ndarrays, flattening each in the specified order.
466
+ */
467
+ NPY_NO_EXPORT PyArrayObject *
468
+ PyArray_ConcatenateFlattenedArrays(int narrays, PyArrayObject **arrays,
469
+ NPY_ORDER order)
470
+ {
471
+ PyTypeObject *subtype = &PyArray_Type;
472
+ double priority = NPY_PRIORITY;
473
+ int iarrays;
474
+ npy_intp stride;
475
+ npy_intp shape = 0;
476
+ PyArray_Descr *dtype = NULL;
477
+ PyArrayObject *ret = NULL;
478
+ PyArrayObject_fields *sliding_view = NULL;
479
+
480
+ if (narrays <= 0) {
481
+ PyErr_SetString(PyExc_ValueError,
482
+ "need at least one array to concatenate");
483
+ return NULL;
484
+ }
485
+
486
+ /*
487
+ * Figure out the final concatenated shape starting from the first
488
+ * array's shape.
489
+ */
490
+ for (iarrays = 0; iarrays < narrays; ++iarrays) {
491
+ shape += PyArray_SIZE(arrays[iarrays]);
492
+ /* Check for overflow */
493
+ if (shape < 0) {
494
+ PyErr_SetString(PyExc_ValueError,
495
+ "total number of elements "
496
+ "too large to concatenate");
497
+ return NULL;
498
+ }
499
+ }
500
+
501
+ /* Get the priority subtype for the array */
502
+ for (iarrays = 0; iarrays < narrays; ++iarrays) {
503
+ if (Py_TYPE(arrays[iarrays]) != subtype) {
504
+ double pr = PyArray_GetPriority((PyObject *)(arrays[iarrays]), 0.0);
505
+ if (pr > priority) {
506
+ priority = pr;
507
+ subtype = Py_TYPE(arrays[iarrays]);
508
+ }
509
+ }
510
+ }
511
+
512
+ /* Get the resulting dtype from combining all the arrays */
513
+ dtype = PyArray_ResultType(narrays, arrays, 0, NULL);
514
+ if (dtype == NULL) {
515
+ return NULL;
516
+ }
517
+
518
+ stride = dtype->elsize;
519
+
520
+ /* Allocate the array for the result. This steals the 'dtype' reference. */
521
+ ret = (PyArrayObject *)PyArray_NewFromDescr(subtype,
522
+ dtype,
523
+ 1,
524
+ &shape,
525
+ &stride,
526
+ NULL,
527
+ 0,
528
+ NULL);
529
+ if (ret == NULL) {
530
+ return NULL;
531
+ }
532
+
533
+ /*
534
+ * Create a view which slides through ret for assigning the
535
+ * successive input arrays.
536
+ */
537
+ sliding_view = (PyArrayObject_fields *)PyArray_View(ret,
538
+ NULL, &PyArray_Type);
539
+ if (sliding_view == NULL) {
540
+ Py_DECREF(ret);
541
+ return NULL;
542
+ }
543
+
544
+ for (iarrays = 0; iarrays < narrays; ++iarrays) {
545
+ /* Adjust the window dimensions for this array */
546
+ sliding_view->dimensions[0] = PyArray_SIZE(arrays[iarrays]);
547
+
548
+ /* Copy the data for this array */
549
+ if (PyArray_CopyAsFlat((PyArrayObject *)sliding_view, arrays[iarrays],
550
+ order) < 0) {
551
+ Py_DECREF(sliding_view);
552
+ Py_DECREF(ret);
553
+ return NULL;
554
+ }
555
+
556
+ /* Slide to the start of the next window */
557
+ sliding_view->data +=
558
+ sliding_view->strides[0] * PyArray_SIZE(arrays[iarrays]);
559
+ }
560
+
561
+ Py_DECREF(sliding_view);
562
+ return ret;
563
+ }
564
+
565
+
566
+ /*NUMPY_API
567
+ * Concatenate
568
+ *
569
+ * Concatenate an arbitrary Python sequence into an array.
570
+ * op is a python object supporting the sequence interface.
571
+ * Its elements will be concatenated together to form a single
572
+ * multidimensional array. If axis is NPY_MAXDIMS or bigger, then
573
+ * each sequence object will be flattened before concatenation
574
+ */
575
+ NPY_NO_EXPORT PyObject *
576
+ PyArray_Concatenate(PyObject *op, int axis)
577
+ {
578
+ int iarrays, narrays;
579
+ PyArrayObject **arrays;
580
+ PyArrayObject *ret;
581
+
582
+ if (!PySequence_Check(op)) {
583
+ PyErr_SetString(PyExc_TypeError,
584
+ "The first input argument needs to be a sequence");
585
+ return NULL;
586
+ }
587
+
588
+ /* Convert the input list into arrays */
589
+ narrays = PySequence_Size(op);
590
+ if (narrays < 0) {
591
+ return NULL;
592
+ }
593
+ arrays = PyArray_malloc(narrays * sizeof(arrays[0]));
594
+ if (arrays == NULL) {
595
+ PyErr_NoMemory();
596
+ return NULL;
597
+ }
598
+ for (iarrays = 0; iarrays < narrays; ++iarrays) {
599
+ PyObject *item = PySequence_GetItem(op, iarrays);
600
+ if (item == NULL) {
601
+ narrays = iarrays;
602
+ goto fail;
603
+ }
604
+ arrays[iarrays] = (PyArrayObject *)PyArray_FromAny(item, NULL,
605
+ 0, 0, 0, NULL);
606
+ Py_DECREF(item);
607
+ if (arrays[iarrays] == NULL) {
608
+ narrays = iarrays;
609
+ goto fail;
610
+ }
611
+ }
612
+
613
+ if (axis >= NPY_MAXDIMS) {
614
+ ret = PyArray_ConcatenateFlattenedArrays(narrays, arrays, NPY_CORDER);
615
+ }
616
+ else {
617
+ ret = PyArray_ConcatenateArrays(narrays, arrays, axis);
618
+ }
619
+
620
+ for (iarrays = 0; iarrays < narrays; ++iarrays) {
621
+ Py_DECREF(arrays[iarrays]);
622
+ }
623
+ PyArray_free(arrays);
624
+
625
+ return (PyObject *)ret;
626
+
627
+ fail:
628
+ /* 'narrays' was set to how far we got in the conversion */
629
+ for (iarrays = 0; iarrays < narrays; ++iarrays) {
630
+ Py_DECREF(arrays[iarrays]);
631
+ }
632
+ PyArray_free(arrays);
633
+
634
+ return NULL;
635
+ }
636
+
637
+ static int
638
+ _signbit_set(PyArrayObject *arr)
639
+ {
640
+ static char bitmask = (char) 0x80;
641
+ char *ptr; /* points to the npy_byte to test */
642
+ char byteorder;
643
+ int elsize;
644
+
645
+ elsize = PyArray_DESCR(arr)->elsize;
646
+ byteorder = PyArray_DESCR(arr)->byteorder;
647
+ ptr = PyArray_DATA(arr);
648
+ if (elsize > 1 &&
649
+ (byteorder == NPY_LITTLE ||
650
+ (byteorder == NPY_NATIVE &&
651
+ PyArray_ISNBO(NPY_LITTLE)))) {
652
+ ptr += elsize - 1;
653
+ }
654
+ return ((*ptr & bitmask) != 0);
655
+ }
656
+
657
+
658
+ /*NUMPY_API
659
+ * ScalarKind
660
+ *
661
+ * Returns the scalar kind of a type number, with an
662
+ * optional tweak based on the scalar value itself.
663
+ * If no scalar is provided, it returns INTPOS_SCALAR
664
+ * for both signed and unsigned integers, otherwise
665
+ * it checks the sign of any signed integer to choose
666
+ * INTNEG_SCALAR when appropriate.
667
+ */
668
+ NPY_NO_EXPORT NPY_SCALARKIND
669
+ PyArray_ScalarKind(int typenum, PyArrayObject **arr)
670
+ {
671
+ NPY_SCALARKIND ret = NPY_NOSCALAR;
672
+
673
+ if ((unsigned int)typenum < NPY_NTYPES) {
674
+ ret = _npy_scalar_kinds_table[typenum];
675
+ /* Signed integer types are INTNEG in the table */
676
+ if (ret == NPY_INTNEG_SCALAR) {
677
+ if (!arr || !_signbit_set(*arr)) {
678
+ ret = NPY_INTPOS_SCALAR;
679
+ }
680
+ }
681
+ } else if (PyTypeNum_ISUSERDEF(typenum)) {
682
+ PyArray_Descr* descr = PyArray_DescrFromType(typenum);
683
+
684
+ if (descr->f->scalarkind) {
685
+ ret = descr->f->scalarkind((arr ? *arr : NULL));
686
+ }
687
+ Py_DECREF(descr);
688
+ }
689
+
690
+ return ret;
691
+ }
692
+
693
+ /*NUMPY_API
694
+ *
695
+ * Determines whether the data type 'thistype', with
696
+ * scalar kind 'scalar', can be coerced into 'neededtype'.
697
+ */
698
+ NPY_NO_EXPORT int
699
+ PyArray_CanCoerceScalar(int thistype, int neededtype,
700
+ NPY_SCALARKIND scalar)
701
+ {
702
+ PyArray_Descr* from;
703
+ int *castlist;
704
+
705
+ /* If 'thistype' is not a scalar, it must be safely castable */
706
+ if (scalar == NPY_NOSCALAR) {
707
+ return PyArray_CanCastSafely(thistype, neededtype);
708
+ }
709
+ if ((unsigned int)neededtype < NPY_NTYPES) {
710
+ NPY_SCALARKIND neededscalar;
711
+
712
+ if (scalar == NPY_OBJECT_SCALAR) {
713
+ return PyArray_CanCastSafely(thistype, neededtype);
714
+ }
715
+
716
+ /*
717
+ * The lookup table gives us exactly what we need for
718
+ * this comparison, which PyArray_ScalarKind would not.
719
+ *
720
+ * The rule is that positive scalars can be coerced
721
+ * to a signed ints, but negative scalars cannot be coerced
722
+ * to unsigned ints.
723
+ * _npy_scalar_kinds_table[int]==NEGINT > POSINT,
724
+ * so 1 is returned, but
725
+ * _npy_scalar_kinds_table[uint]==POSINT < NEGINT,
726
+ * so 0 is returned, as required.
727
+ *
728
+ */
729
+ neededscalar = _npy_scalar_kinds_table[neededtype];
730
+ if (neededscalar >= scalar) {
731
+ return 1;
732
+ }
733
+ if (!PyTypeNum_ISUSERDEF(thistype)) {
734
+ return 0;
735
+ }
736
+ }
737
+
738
+ from = PyArray_DescrFromType(thistype);
739
+ if (from->f->cancastscalarkindto
740
+ && (castlist = from->f->cancastscalarkindto[scalar])) {
741
+ while (*castlist != NPY_NOTYPE) {
742
+ if (*castlist++ == neededtype) {
743
+ Py_DECREF(from);
744
+ return 1;
745
+ }
746
+ }
747
+ }
748
+ Py_DECREF(from);
749
+
750
+ return 0;
751
+ }
752
+
753
+ /*
754
+ * Make a new empty array, of the passed size, of a type that takes the
755
+ * priority of ap1 and ap2 into account.
756
+ */
757
+ static PyArrayObject *
758
+ new_array_for_sum(PyArrayObject *ap1, PyArrayObject *ap2, PyArrayObject* out,
759
+ int nd, npy_intp dimensions[], int typenum)
760
+ {
761
+ PyArrayObject *ret;
762
+ PyTypeObject *subtype;
763
+ double prior1, prior2;
764
+ /*
765
+ * Need to choose an output array that can hold a sum
766
+ * -- use priority to determine which subtype.
767
+ */
768
+ if (Py_TYPE(ap2) != Py_TYPE(ap1)) {
769
+ prior2 = PyArray_GetPriority((PyObject *)ap2, 0.0);
770
+ prior1 = PyArray_GetPriority((PyObject *)ap1, 0.0);
771
+ subtype = (prior2 > prior1 ? Py_TYPE(ap2) : Py_TYPE(ap1));
772
+ }
773
+ else {
774
+ prior1 = prior2 = 0.0;
775
+ subtype = Py_TYPE(ap1);
776
+ }
777
+ if (out) {
778
+ int d;
779
+ /* verify that out is usable */
780
+ if (Py_TYPE(out) != subtype ||
781
+ PyArray_NDIM(out) != nd ||
782
+ PyArray_TYPE(out) != typenum ||
783
+ !PyArray_ISCARRAY(out)) {
784
+ PyErr_SetString(PyExc_ValueError,
785
+ "output array is not acceptable "
786
+ "(must have the right type, nr dimensions, and be a C-Array)");
787
+ return 0;
788
+ }
789
+ for (d = 0; d < nd; ++d) {
790
+ if (dimensions[d] != PyArray_DIM(out, d)) {
791
+ PyErr_SetString(PyExc_ValueError,
792
+ "output array has wrong dimensions");
793
+ return 0;
794
+ }
795
+ }
796
+ Py_INCREF(out);
797
+ return out;
798
+ }
799
+
800
+ ret = (PyArrayObject *)PyArray_New(subtype, nd, dimensions,
801
+ typenum, NULL, NULL, 0, 0,
802
+ (PyObject *)
803
+ (prior2 > prior1 ? ap2 : ap1));
804
+ return ret;
805
+ }
806
+
807
+ /* Could perhaps be redone to not make contiguous arrays */
808
+
809
+ /*NUMPY_API
810
+ * Numeric.innerproduct(a,v)
811
+ */
812
+ NPY_NO_EXPORT PyObject *
813
+ PyArray_InnerProduct(PyObject *op1, PyObject *op2)
814
+ {
815
+ PyArrayObject *ap1, *ap2, *ret = NULL;
816
+ PyArrayIterObject *it1, *it2;
817
+ npy_intp i, j, l;
818
+ int typenum, nd, axis;
819
+ npy_intp is1, is2, os;
820
+ char *op;
821
+ npy_intp dimensions[NPY_MAXDIMS];
822
+ PyArray_DotFunc *dot;
823
+ PyArray_Descr *typec;
824
+ NPY_BEGIN_THREADS_DEF;
825
+
826
+ typenum = PyArray_ObjectType(op1, 0);
827
+ typenum = PyArray_ObjectType(op2, typenum);
828
+
829
+ typec = PyArray_DescrFromType(typenum);
830
+ if (typec == NULL) {
831
+ return NULL;
832
+ }
833
+ Py_INCREF(typec);
834
+ ap1 = (PyArrayObject *)PyArray_FromAny(op1, typec, 0, 0,
835
+ NPY_ARRAY_ALIGNED, NULL);
836
+ if (ap1 == NULL) {
837
+ Py_DECREF(typec);
838
+ return NULL;
839
+ }
840
+ ap2 = (PyArrayObject *)PyArray_FromAny(op2, typec, 0, 0,
841
+ NPY_ARRAY_ALIGNED, NULL);
842
+ if (ap2 == NULL) {
843
+ Py_DECREF(ap1);
844
+ return NULL;
845
+ }
846
+
847
+ #if defined(HAVE_CBLAS)
848
+ if (PyArray_NDIM(ap1) <= 2 && PyArray_NDIM(ap2) <= 2 &&
849
+ (NPY_DOUBLE == typenum || NPY_CDOUBLE == typenum ||
850
+ NPY_FLOAT == typenum || NPY_CFLOAT == typenum)) {
851
+ return cblas_innerproduct(typenum, ap1, ap2);
852
+ }
853
+ #endif
854
+
855
+ if (PyArray_NDIM(ap1) == 0 || PyArray_NDIM(ap2) == 0) {
856
+ ret = (PyArray_NDIM(ap1) == 0 ? ap1 : ap2);
857
+ ret = (PyArrayObject *)Py_TYPE(ret)->tp_as_number->nb_multiply(
858
+ (PyObject *)ap1, (PyObject *)ap2);
859
+ Py_DECREF(ap1);
860
+ Py_DECREF(ap2);
861
+ return (PyObject *)ret;
862
+ }
863
+
864
+ l = PyArray_DIMS(ap1)[PyArray_NDIM(ap1) - 1];
865
+ if (PyArray_DIMS(ap2)[PyArray_NDIM(ap2) - 1] != l) {
866
+ dot_alignment_error(ap1, PyArray_NDIM(ap1) - 1,
867
+ ap2, PyArray_NDIM(ap2) - 1);
868
+ goto fail;
869
+ }
870
+
871
+ nd = PyArray_NDIM(ap1) + PyArray_NDIM(ap2) - 2;
872
+ j = 0;
873
+ for (i = 0; i < PyArray_NDIM(ap1) - 1; i++) {
874
+ dimensions[j++] = PyArray_DIMS(ap1)[i];
875
+ }
876
+ for (i = 0; i < PyArray_NDIM(ap2) - 1; i++) {
877
+ dimensions[j++] = PyArray_DIMS(ap2)[i];
878
+ }
879
+
880
+ /*
881
+ * Need to choose an output array that can hold a sum
882
+ * -- use priority to determine which subtype.
883
+ */
884
+ ret = new_array_for_sum(ap1, ap2, NULL, nd, dimensions, typenum);
885
+ if (ret == NULL) {
886
+ goto fail;
887
+ }
888
+ /* Ensure that multiarray.inner(<Nx0>,<Mx0>) -> zeros((N,M)) */
889
+ if (PyArray_SIZE(ap1) == 0 && PyArray_SIZE(ap2) == 0) {
890
+ memset(PyArray_DATA(ret), 0, PyArray_NBYTES(ret));
891
+ }
892
+
893
+ dot = (PyArray_DESCR(ret)->f->dotfunc);
894
+ if (dot == NULL) {
895
+ PyErr_SetString(PyExc_ValueError,
896
+ "dot not available for this type");
897
+ goto fail;
898
+ }
899
+ is1 = PyArray_STRIDES(ap1)[PyArray_NDIM(ap1) - 1];
900
+ is2 = PyArray_STRIDES(ap2)[PyArray_NDIM(ap2) - 1];
901
+ op = PyArray_DATA(ret);
902
+ os = PyArray_DESCR(ret)->elsize;
903
+ axis = PyArray_NDIM(ap1) - 1;
904
+ it1 = (PyArrayIterObject *) PyArray_IterAllButAxis((PyObject *)ap1, &axis);
905
+ axis = PyArray_NDIM(ap2) - 1;
906
+ it2 = (PyArrayIterObject *) PyArray_IterAllButAxis((PyObject *)ap2, &axis);
907
+ NPY_BEGIN_THREADS_DESCR(PyArray_DESCR(ap2));
908
+ while (it1->index < it1->size) {
909
+ while (it2->index < it2->size) {
910
+ dot(it1->dataptr, is1, it2->dataptr, is2, op, l, ret);
911
+ op += os;
912
+ PyArray_ITER_NEXT(it2);
913
+ }
914
+ PyArray_ITER_NEXT(it1);
915
+ PyArray_ITER_RESET(it2);
916
+ }
917
+ NPY_END_THREADS_DESCR(PyArray_DESCR(ap2));
918
+ Py_DECREF(it1);
919
+ Py_DECREF(it2);
920
+ if (PyErr_Occurred()) {
921
+ goto fail;
922
+ }
923
+ Py_DECREF(ap1);
924
+ Py_DECREF(ap2);
925
+ return (PyObject *)ret;
926
+
927
+ fail:
928
+ Py_XDECREF(ap1);
929
+ Py_XDECREF(ap2);
930
+ Py_XDECREF(ret);
931
+ return NULL;
932
+ }
933
+
934
+ /*NUMPY_API
935
+ * Numeric.matrixproduct(a,v)
936
+ * just like inner product but does the swapaxes stuff on the fly
937
+ */
938
+ NPY_NO_EXPORT PyObject *
939
+ PyArray_MatrixProduct(PyObject *op1, PyObject *op2)
940
+ {
941
+ return PyArray_MatrixProduct2(op1, op2, NULL);
942
+ }
943
+
944
+ /*NUMPY_API
945
+ * Numeric.matrixproduct2(a,v,out)
946
+ * just like inner product but does the swapaxes stuff on the fly
947
+ */
948
+ NPY_NO_EXPORT PyObject *
949
+ PyArray_MatrixProduct2(PyObject *op1, PyObject *op2, PyArrayObject* out)
950
+ {
951
+ PyArrayObject *ap1, *ap2, *ret = NULL;
952
+ PyArrayIterObject *it1, *it2;
953
+ npy_intp i, j, l;
954
+ int typenum, nd, axis, matchDim;
955
+ npy_intp is1, is2, os;
956
+ char *op;
957
+ npy_intp dimensions[NPY_MAXDIMS];
958
+ PyArray_DotFunc *dot;
959
+ PyArray_Descr *typec = NULL;
960
+ NPY_BEGIN_THREADS_DEF;
961
+
962
+ typenum = PyArray_ObjectType(op1, 0);
963
+ typenum = PyArray_ObjectType(op2, typenum);
964
+ typec = PyArray_DescrFromType(typenum);
965
+ if (typec == NULL) {
966
+ PyErr_SetString(PyExc_ValueError, "Cannot find a common data type.");
967
+ return NULL;
968
+ }
969
+
970
+ Py_INCREF(typec);
971
+ ap1 = (PyArrayObject *)PyArray_FromAny(op1, typec, 0, 0,
972
+ NPY_ARRAY_ALIGNED, NULL);
973
+ if (ap1 == NULL) {
974
+ Py_DECREF(typec);
975
+ return NULL;
976
+ }
977
+ ap2 = (PyArrayObject *)PyArray_FromAny(op2, typec, 0, 0,
978
+ NPY_ARRAY_ALIGNED, NULL);
979
+ if (ap2 == NULL) {
980
+ Py_DECREF(ap1);
981
+ return NULL;
982
+ }
983
+
984
+ #if defined(HAVE_CBLAS)
985
+ if (PyArray_NDIM(ap1) <= 2 && PyArray_NDIM(ap2) <= 2 &&
986
+ (NPY_DOUBLE == typenum || NPY_CDOUBLE == typenum ||
987
+ NPY_FLOAT == typenum || NPY_CFLOAT == typenum)) {
988
+ return cblas_matrixproduct(typenum, ap1, ap2, out);
989
+ }
990
+ #endif
991
+
992
+ if (PyArray_NDIM(ap1) == 0 || PyArray_NDIM(ap2) == 0) {
993
+ ret = (PyArray_NDIM(ap1) == 0 ? ap1 : ap2);
994
+ ret = (PyArrayObject *)Py_TYPE(ret)->tp_as_number->nb_multiply(
995
+ (PyObject *)ap1, (PyObject *)ap2);
996
+ Py_DECREF(ap1);
997
+ Py_DECREF(ap2);
998
+ return (PyObject *)ret;
999
+ }
1000
+ l = PyArray_DIMS(ap1)[PyArray_NDIM(ap1) - 1];
1001
+ if (PyArray_NDIM(ap2) > 1) {
1002
+ matchDim = PyArray_NDIM(ap2) - 2;
1003
+ }
1004
+ else {
1005
+ matchDim = 0;
1006
+ }
1007
+ if (PyArray_DIMS(ap2)[matchDim] != l) {
1008
+ dot_alignment_error(ap1, PyArray_NDIM(ap1) - 1, ap2, matchDim);
1009
+ goto fail;
1010
+ }
1011
+ nd = PyArray_NDIM(ap1) + PyArray_NDIM(ap2) - 2;
1012
+ if (nd > NPY_MAXDIMS) {
1013
+ PyErr_SetString(PyExc_ValueError, "dot: too many dimensions in result");
1014
+ goto fail;
1015
+ }
1016
+ j = 0;
1017
+ for (i = 0; i < PyArray_NDIM(ap1) - 1; i++) {
1018
+ dimensions[j++] = PyArray_DIMS(ap1)[i];
1019
+ }
1020
+ for (i = 0; i < PyArray_NDIM(ap2) - 2; i++) {
1021
+ dimensions[j++] = PyArray_DIMS(ap2)[i];
1022
+ }
1023
+ if(PyArray_NDIM(ap2) > 1) {
1024
+ dimensions[j++] = PyArray_DIMS(ap2)[PyArray_NDIM(ap2)-1];
1025
+ }
1026
+
1027
+ is1 = PyArray_STRIDES(ap1)[PyArray_NDIM(ap1)-1];
1028
+ is2 = PyArray_STRIDES(ap2)[matchDim];
1029
+ /* Choose which subtype to return */
1030
+ ret = new_array_for_sum(ap1, ap2, out, nd, dimensions, typenum);
1031
+ if (ret == NULL) {
1032
+ goto fail;
1033
+ }
1034
+ /* Ensure that multiarray.dot(<Nx0>,<0xM>) -> zeros((N,M)) */
1035
+ if (PyArray_SIZE(ap1) == 0 && PyArray_SIZE(ap2) == 0) {
1036
+ memset(PyArray_DATA(ret), 0, PyArray_NBYTES(ret));
1037
+ }
1038
+
1039
+ dot = PyArray_DESCR(ret)->f->dotfunc;
1040
+ if (dot == NULL) {
1041
+ PyErr_SetString(PyExc_ValueError,
1042
+ "dot not available for this type");
1043
+ goto fail;
1044
+ }
1045
+
1046
+ op = PyArray_DATA(ret);
1047
+ os = PyArray_DESCR(ret)->elsize;
1048
+ axis = PyArray_NDIM(ap1)-1;
1049
+ it1 = (PyArrayIterObject *)
1050
+ PyArray_IterAllButAxis((PyObject *)ap1, &axis);
1051
+ if (it1 == NULL) {
1052
+ goto fail;
1053
+ }
1054
+ it2 = (PyArrayIterObject *)
1055
+ PyArray_IterAllButAxis((PyObject *)ap2, &matchDim);
1056
+ if (it2 == NULL) {
1057
+ Py_DECREF(it1);
1058
+ goto fail;
1059
+ }
1060
+ NPY_BEGIN_THREADS_DESCR(PyArray_DESCR(ap2));
1061
+ while (it1->index < it1->size) {
1062
+ while (it2->index < it2->size) {
1063
+ dot(it1->dataptr, is1, it2->dataptr, is2, op, l, ret);
1064
+ op += os;
1065
+ PyArray_ITER_NEXT(it2);
1066
+ }
1067
+ PyArray_ITER_NEXT(it1);
1068
+ PyArray_ITER_RESET(it2);
1069
+ }
1070
+ NPY_END_THREADS_DESCR(PyArray_DESCR(ap2));
1071
+ Py_DECREF(it1);
1072
+ Py_DECREF(it2);
1073
+ if (PyErr_Occurred()) {
1074
+ /* only for OBJECT arrays */
1075
+ goto fail;
1076
+ }
1077
+ Py_DECREF(ap1);
1078
+ Py_DECREF(ap2);
1079
+ return (PyObject *)ret;
1080
+
1081
+ fail:
1082
+ Py_XDECREF(ap1);
1083
+ Py_XDECREF(ap2);
1084
+ Py_XDECREF(ret);
1085
+ return NULL;
1086
+ }
1087
+
1088
+
1089
+ /*NUMPY_API
1090
+ * Copy and Transpose
1091
+ *
1092
+ * Could deprecate this function, as there isn't a speed benefit over
1093
+ * calling Transpose and then Copy.
1094
+ */
1095
+ NPY_NO_EXPORT PyObject *
1096
+ PyArray_CopyAndTranspose(PyObject *op)
1097
+ {
1098
+ PyArrayObject *arr, *tmp, *ret;
1099
+ int i;
1100
+ npy_intp new_axes_values[NPY_MAXDIMS];
1101
+ PyArray_Dims new_axes;
1102
+
1103
+ /* Make sure we have an array */
1104
+ arr = (PyArrayObject *)PyArray_FromAny(op, NULL, 0, 0, 0, NULL);
1105
+ if (arr == NULL) {
1106
+ return NULL;
1107
+ }
1108
+
1109
+ if (PyArray_NDIM(arr) > 1) {
1110
+ /* Set up the transpose operation */
1111
+ new_axes.len = PyArray_NDIM(arr);
1112
+ for (i = 0; i < new_axes.len; ++i) {
1113
+ new_axes_values[i] = new_axes.len - i - 1;
1114
+ }
1115
+ new_axes.ptr = new_axes_values;
1116
+
1117
+ /* Do the transpose (always returns a view) */
1118
+ tmp = (PyArrayObject *)PyArray_Transpose(arr, &new_axes);
1119
+ if (tmp == NULL) {
1120
+ Py_DECREF(arr);
1121
+ return NULL;
1122
+ }
1123
+ }
1124
+ else {
1125
+ tmp = arr;
1126
+ arr = NULL;
1127
+ }
1128
+
1129
+ /* TODO: Change this to NPY_KEEPORDER for NumPy 2.0 */
1130
+ ret = (PyArrayObject *)PyArray_NewCopy(tmp, NPY_CORDER);
1131
+
1132
+ Py_XDECREF(arr);
1133
+ Py_DECREF(tmp);
1134
+ return (PyObject *)ret;
1135
+ }
1136
+
1137
+ /*
1138
+ * Implementation which is common between PyArray_Correlate
1139
+ * and PyArray_Correlate2.
1140
+ *
1141
+ * inverted is set to 1 if computed correlate(ap2, ap1), 0 otherwise
1142
+ */
1143
+ static PyArrayObject*
1144
+ _pyarray_correlate(PyArrayObject *ap1, PyArrayObject *ap2, int typenum,
1145
+ int mode, int *inverted)
1146
+ {
1147
+ PyArrayObject *ret;
1148
+ npy_intp length;
1149
+ npy_intp i, n1, n2, n, n_left, n_right;
1150
+ npy_intp is1, is2, os;
1151
+ char *ip1, *ip2, *op;
1152
+ PyArray_DotFunc *dot;
1153
+
1154
+ NPY_BEGIN_THREADS_DEF;
1155
+
1156
+ n1 = PyArray_DIMS(ap1)[0];
1157
+ n2 = PyArray_DIMS(ap2)[0];
1158
+ if (n1 < n2) {
1159
+ ret = ap1;
1160
+ ap1 = ap2;
1161
+ ap2 = ret;
1162
+ ret = NULL;
1163
+ i = n1;
1164
+ n1 = n2;
1165
+ n2 = i;
1166
+ *inverted = 1;
1167
+ } else {
1168
+ *inverted = 0;
1169
+ }
1170
+
1171
+ length = n1;
1172
+ n = n2;
1173
+ switch(mode) {
1174
+ case 0:
1175
+ length = length - n + 1;
1176
+ n_left = n_right = 0;
1177
+ break;
1178
+ case 1:
1179
+ n_left = (npy_intp)(n/2);
1180
+ n_right = n - n_left - 1;
1181
+ break;
1182
+ case 2:
1183
+ n_right = n - 1;
1184
+ n_left = n - 1;
1185
+ length = length + n - 1;
1186
+ break;
1187
+ default:
1188
+ PyErr_SetString(PyExc_ValueError, "mode must be 0, 1, or 2");
1189
+ return NULL;
1190
+ }
1191
+
1192
+ /*
1193
+ * Need to choose an output array that can hold a sum
1194
+ * -- use priority to determine which subtype.
1195
+ */
1196
+ ret = new_array_for_sum(ap1, ap2, NULL, 1, &length, typenum);
1197
+ if (ret == NULL) {
1198
+ return NULL;
1199
+ }
1200
+ dot = PyArray_DESCR(ret)->f->dotfunc;
1201
+ if (dot == NULL) {
1202
+ PyErr_SetString(PyExc_ValueError,
1203
+ "function not available for this data type");
1204
+ goto clean_ret;
1205
+ }
1206
+
1207
+ NPY_BEGIN_THREADS_DESCR(PyArray_DESCR(ret));
1208
+ is1 = PyArray_STRIDES(ap1)[0];
1209
+ is2 = PyArray_STRIDES(ap2)[0];
1210
+ op = PyArray_DATA(ret);
1211
+ os = PyArray_DESCR(ret)->elsize;
1212
+ ip1 = PyArray_DATA(ap1);
1213
+ ip2 = PyArray_BYTES(ap2) + n_left*is2;
1214
+ n = n - n_left;
1215
+ for (i = 0; i < n_left; i++) {
1216
+ dot(ip1, is1, ip2, is2, op, n, ret);
1217
+ n++;
1218
+ ip2 -= is2;
1219
+ op += os;
1220
+ }
1221
+ if (small_correlate(ip1, is1, n1 - n2 + 1, PyArray_TYPE(ap1),
1222
+ ip2, is2, n, PyArray_TYPE(ap2),
1223
+ op, os)) {
1224
+ ip1 += is1 * (n1 - n2 + 1);
1225
+ op += os * (n1 - n2 + 1);
1226
+ }
1227
+ else {
1228
+ for (i = 0; i < (n1 - n2 + 1); i++) {
1229
+ dot(ip1, is1, ip2, is2, op, n, ret);
1230
+ ip1 += is1;
1231
+ op += os;
1232
+ }
1233
+ }
1234
+ for (i = 0; i < n_right; i++) {
1235
+ n--;
1236
+ dot(ip1, is1, ip2, is2, op, n, ret);
1237
+ ip1 += is1;
1238
+ op += os;
1239
+ }
1240
+
1241
+ NPY_END_THREADS_DESCR(PyArray_DESCR(ret));
1242
+ if (PyErr_Occurred()) {
1243
+ goto clean_ret;
1244
+ }
1245
+
1246
+ return ret;
1247
+
1248
+ clean_ret:
1249
+ Py_DECREF(ret);
1250
+ return NULL;
1251
+ }
1252
+
1253
+ /*
1254
+ * Revert a one dimensional array in-place
1255
+ *
1256
+ * Return 0 on success, other value on failure
1257
+ */
1258
+ static int
1259
+ _pyarray_revert(PyArrayObject *ret)
1260
+ {
1261
+ npy_intp length = PyArray_DIM(ret, 0);
1262
+ npy_intp os = PyArray_DESCR(ret)->elsize;
1263
+ char *op = PyArray_DATA(ret);
1264
+ char *sw1 = op;
1265
+ char *sw2;
1266
+
1267
+ if (PyArray_ISNUMBER(ret) && !PyArray_ISCOMPLEX(ret)) {
1268
+ /* Optimization for unstructured dtypes */
1269
+ PyArray_CopySwapNFunc *copyswapn = PyArray_DESCR(ret)->f->copyswapn;
1270
+ sw2 = op + length * os - 1;
1271
+ /* First reverse the whole array byte by byte... */
1272
+ while(sw1 < sw2) {
1273
+ const char tmp = *sw1;
1274
+ *sw1++ = *sw2;
1275
+ *sw2-- = tmp;
1276
+ }
1277
+ /* ...then swap in place every item */
1278
+ copyswapn(op, os, NULL, 0, length, 1, NULL);
1279
+ }
1280
+ else {
1281
+ char *tmp = PyArray_malloc(PyArray_DESCR(ret)->elsize);
1282
+ if (tmp == NULL) {
1283
+ return -1;
1284
+ }
1285
+ sw2 = op + (length - 1) * os;
1286
+ while (sw1 < sw2) {
1287
+ memcpy(tmp, sw1, os);
1288
+ memcpy(sw1, sw2, os);
1289
+ memcpy(sw2, tmp, os);
1290
+ sw1 += os;
1291
+ sw2 -= os;
1292
+ }
1293
+ PyArray_free(tmp);
1294
+ }
1295
+
1296
+ return 0;
1297
+ }
1298
+
1299
+ /*NUMPY_API
1300
+ * correlate(a1,a2,mode)
1301
+ *
1302
+ * This function computes the usual correlation (correlate(a1, a2) !=
1303
+ * correlate(a2, a1), and conjugate the second argument for complex inputs
1304
+ */
1305
+ NPY_NO_EXPORT PyObject *
1306
+ PyArray_Correlate2(PyObject *op1, PyObject *op2, int mode)
1307
+ {
1308
+ PyArrayObject *ap1, *ap2, *ret = NULL;
1309
+ int typenum;
1310
+ PyArray_Descr *typec;
1311
+ int inverted;
1312
+ int st;
1313
+
1314
+ typenum = PyArray_ObjectType(op1, 0);
1315
+ typenum = PyArray_ObjectType(op2, typenum);
1316
+
1317
+ typec = PyArray_DescrFromType(typenum);
1318
+ Py_INCREF(typec);
1319
+ ap1 = (PyArrayObject *)PyArray_FromAny(op1, typec, 1, 1,
1320
+ NPY_ARRAY_DEFAULT, NULL);
1321
+ if (ap1 == NULL) {
1322
+ Py_DECREF(typec);
1323
+ return NULL;
1324
+ }
1325
+ ap2 = (PyArrayObject *)PyArray_FromAny(op2, typec, 1, 1,
1326
+ NPY_ARRAY_DEFAULT, NULL);
1327
+ if (ap2 == NULL) {
1328
+ goto clean_ap1;
1329
+ }
1330
+
1331
+ if (PyArray_ISCOMPLEX(ap2)) {
1332
+ PyArrayObject *cap2;
1333
+ cap2 = (PyArrayObject *)PyArray_Conjugate(ap2, NULL);
1334
+ if (cap2 == NULL) {
1335
+ goto clean_ap2;
1336
+ }
1337
+ Py_DECREF(ap2);
1338
+ ap2 = cap2;
1339
+ }
1340
+
1341
+ ret = _pyarray_correlate(ap1, ap2, typenum, mode, &inverted);
1342
+ if (ret == NULL) {
1343
+ goto clean_ap2;
1344
+ }
1345
+
1346
+ /*
1347
+ * If we inverted input orders, we need to reverse the output array (i.e.
1348
+ * ret = ret[::-1])
1349
+ */
1350
+ if (inverted) {
1351
+ st = _pyarray_revert(ret);
1352
+ if(st) {
1353
+ goto clean_ret;
1354
+ }
1355
+ }
1356
+
1357
+ Py_DECREF(ap1);
1358
+ Py_DECREF(ap2);
1359
+ return (PyObject *)ret;
1360
+
1361
+ clean_ret:
1362
+ Py_DECREF(ret);
1363
+ clean_ap2:
1364
+ Py_DECREF(ap2);
1365
+ clean_ap1:
1366
+ Py_DECREF(ap1);
1367
+ return NULL;
1368
+ }
1369
+
1370
+ /*NUMPY_API
1371
+ * Numeric.correlate(a1,a2,mode)
1372
+ */
1373
+ NPY_NO_EXPORT PyObject *
1374
+ PyArray_Correlate(PyObject *op1, PyObject *op2, int mode)
1375
+ {
1376
+ PyArrayObject *ap1, *ap2, *ret = NULL;
1377
+ int typenum;
1378
+ int unused;
1379
+ PyArray_Descr *typec;
1380
+
1381
+ typenum = PyArray_ObjectType(op1, 0);
1382
+ typenum = PyArray_ObjectType(op2, typenum);
1383
+
1384
+ typec = PyArray_DescrFromType(typenum);
1385
+ Py_INCREF(typec);
1386
+ ap1 = (PyArrayObject *)PyArray_FromAny(op1, typec, 1, 1,
1387
+ NPY_ARRAY_DEFAULT, NULL);
1388
+ if (ap1 == NULL) {
1389
+ Py_DECREF(typec);
1390
+ return NULL;
1391
+ }
1392
+ ap2 = (PyArrayObject *)PyArray_FromAny(op2, typec, 1, 1,
1393
+ NPY_ARRAY_DEFAULT, NULL);
1394
+ if (ap2 == NULL) {
1395
+ goto fail;
1396
+ }
1397
+
1398
+ ret = _pyarray_correlate(ap1, ap2, typenum, mode, &unused);
1399
+ if(ret == NULL) {
1400
+ goto fail;
1401
+ }
1402
+ Py_DECREF(ap1);
1403
+ Py_DECREF(ap2);
1404
+ return (PyObject *)ret;
1405
+
1406
+ fail:
1407
+ Py_XDECREF(ap1);
1408
+ Py_XDECREF(ap2);
1409
+ Py_XDECREF(ret);
1410
+ return NULL;
1411
+ }
1412
+
1413
+
1414
+ static PyObject *
1415
+ array_putmask(PyObject *NPY_UNUSED(module), PyObject *args, PyObject *kwds)
1416
+ {
1417
+ PyObject *mask, *values;
1418
+ PyObject *array;
1419
+
1420
+ static char *kwlist[] = {"arr", "mask", "values", NULL};
1421
+
1422
+ if (!PyArg_ParseTupleAndKeywords(args, kwds, "O!OO:putmask", kwlist,
1423
+ &PyArray_Type, &array, &mask, &values)) {
1424
+ return NULL;
1425
+ }
1426
+ return PyArray_PutMask((PyArrayObject *)array, values, mask);
1427
+ }
1428
+
1429
+ /*
1430
+ * Compare the field dictionaries for two types.
1431
+ *
1432
+ * Return 1 if the contents are the same, 0 if not.
1433
+ */
1434
+ static int
1435
+ _equivalent_fields(PyObject *field1, PyObject *field2) {
1436
+
1437
+ int same, val;
1438
+
1439
+ if (field1 == field2) {
1440
+ return 1;
1441
+ }
1442
+ if (field1 == NULL || field2 == NULL) {
1443
+ return 0;
1444
+ }
1445
+ #if defined(NPY_PY3K)
1446
+ val = PyObject_RichCompareBool(field1, field2, Py_EQ);
1447
+ if (val != 1 || PyErr_Occurred()) {
1448
+ #else
1449
+ val = PyObject_Compare(field1, field2);
1450
+ if (val != 0 || PyErr_Occurred()) {
1451
+ #endif
1452
+ same = 0;
1453
+ }
1454
+ else {
1455
+ same = 1;
1456
+ }
1457
+ PyErr_Clear();
1458
+ return same;
1459
+ }
1460
+
1461
+ /*
1462
+ * Compare the subarray data for two types.
1463
+ * Return 1 if they are the same, 0 if not.
1464
+ */
1465
+ static int
1466
+ _equivalent_subarrays(PyArray_ArrayDescr *sub1, PyArray_ArrayDescr *sub2)
1467
+ {
1468
+ int val;
1469
+
1470
+ if (sub1 == sub2) {
1471
+ return 1;
1472
+
1473
+ }
1474
+ if (sub1 == NULL || sub2 == NULL) {
1475
+ return 0;
1476
+ }
1477
+
1478
+ #if defined(NPY_PY3K)
1479
+ val = PyObject_RichCompareBool(sub1->shape, sub2->shape, Py_EQ);
1480
+ if (val != 1 || PyErr_Occurred()) {
1481
+ #else
1482
+ val = PyObject_Compare(sub1->shape, sub2->shape);
1483
+ if (val != 0 || PyErr_Occurred()) {
1484
+ #endif
1485
+ PyErr_Clear();
1486
+ return 0;
1487
+ }
1488
+
1489
+ return PyArray_EquivTypes(sub1->base, sub2->base);
1490
+ }
1491
+
1492
+
1493
+ /*NUMPY_API
1494
+ *
1495
+ * This function returns true if the two typecodes are
1496
+ * equivalent (same basic kind and same itemsize).
1497
+ */
1498
+ NPY_NO_EXPORT unsigned char
1499
+ PyArray_EquivTypes(PyArray_Descr *type1, PyArray_Descr *type2)
1500
+ {
1501
+ int type_num1, type_num2, size1, size2;
1502
+
1503
+ if (type1 == type2) {
1504
+ return NPY_TRUE;
1505
+ }
1506
+
1507
+ type_num1 = type1->type_num;
1508
+ type_num2 = type2->type_num;
1509
+ size1 = type1->elsize;
1510
+ size2 = type2->elsize;
1511
+
1512
+ if (size1 != size2) {
1513
+ return NPY_FALSE;
1514
+ }
1515
+ if (PyArray_ISNBO(type1->byteorder) != PyArray_ISNBO(type2->byteorder)) {
1516
+ return NPY_FALSE;
1517
+ }
1518
+ if (type1->subarray || type2->subarray) {
1519
+ return ((type_num1 == type_num2)
1520
+ && _equivalent_subarrays(type1->subarray, type2->subarray));
1521
+ }
1522
+ if (type_num1 == NPY_VOID
1523
+ || type_num2 == NPY_VOID) {
1524
+ return ((type_num1 == type_num2)
1525
+ && _equivalent_fields(type1->fields, type2->fields));
1526
+ }
1527
+ if (type_num1 == NPY_DATETIME
1528
+ || type_num1 == NPY_DATETIME
1529
+ || type_num2 == NPY_TIMEDELTA
1530
+ || type_num2 == NPY_TIMEDELTA) {
1531
+ return ((type_num1 == type_num2)
1532
+ && has_equivalent_datetime_metadata(type1, type2));
1533
+ }
1534
+ return type1->kind == type2->kind;
1535
+ }
1536
+
1537
+ /*NUMPY_API*/
1538
+ NPY_NO_EXPORT unsigned char
1539
+ PyArray_EquivTypenums(int typenum1, int typenum2)
1540
+ {
1541
+ PyArray_Descr *d1, *d2;
1542
+ npy_bool ret;
1543
+
1544
+ if (typenum1 == typenum2) {
1545
+ return NPY_SUCCEED;
1546
+ }
1547
+
1548
+ d1 = PyArray_DescrFromType(typenum1);
1549
+ d2 = PyArray_DescrFromType(typenum2);
1550
+ ret = PyArray_EquivTypes(d1, d2);
1551
+ Py_DECREF(d1);
1552
+ Py_DECREF(d2);
1553
+ return ret;
1554
+ }
1555
+
1556
+ /*** END C-API FUNCTIONS **/
1557
+ /*
1558
+ * NPY_RELAXED_STRIDES_CHECKING: If the strides logic is changed, the
1559
+ * order specific stride setting is not necessary.
1560
+ */
1561
+ static NPY_STEALS_REF_TO_ARG(1) PyObject *
1562
+ _prepend_ones(PyArrayObject *arr, int nd, int ndmin, NPY_ORDER order)
1563
+ {
1564
+ npy_intp newdims[NPY_MAXDIMS];
1565
+ npy_intp newstrides[NPY_MAXDIMS];
1566
+ npy_intp newstride;
1567
+ int i, k, num;
1568
+ PyArrayObject *ret;
1569
+ PyArray_Descr *dtype;
1570
+
1571
+ if (order == NPY_FORTRANORDER || PyArray_ISFORTRAN(arr) || PyArray_NDIM(arr) == 0) {
1572
+ newstride = PyArray_DESCR(arr)->elsize;
1573
+ }
1574
+ else {
1575
+ newstride = PyArray_STRIDES(arr)[0] * PyArray_DIMS(arr)[0];
1576
+ }
1577
+
1578
+ num = ndmin - nd;
1579
+ for (i = 0; i < num; i++) {
1580
+ newdims[i] = 1;
1581
+ newstrides[i] = newstride;
1582
+ }
1583
+ for (i = num; i < ndmin; i++) {
1584
+ k = i - num;
1585
+ newdims[i] = PyArray_DIMS(arr)[k];
1586
+ newstrides[i] = PyArray_STRIDES(arr)[k];
1587
+ }
1588
+ dtype = PyArray_DESCR(arr);
1589
+ Py_INCREF(dtype);
1590
+ ret = (PyArrayObject *)PyArray_NewFromDescr(Py_TYPE(arr),
1591
+ dtype, ndmin, newdims, newstrides,
1592
+ PyArray_DATA(arr),
1593
+ PyArray_FLAGS(arr),
1594
+ (PyObject *)arr);
1595
+ if (ret == NULL) {
1596
+ Py_DECREF(arr);
1597
+ return NULL;
1598
+ }
1599
+ /* steals a reference to arr --- so don't increment here */
1600
+ if (PyArray_SetBaseObject(ret, (PyObject *)arr) < 0) {
1601
+ Py_DECREF(ret);
1602
+ return NULL;
1603
+ }
1604
+
1605
+ return (PyObject *)ret;
1606
+ }
1607
+
1608
+
1609
+ #define STRIDING_OK(op, order) \
1610
+ ((order) == NPY_ANYORDER || \
1611
+ (order) == NPY_KEEPORDER || \
1612
+ ((order) == NPY_CORDER && PyArray_IS_C_CONTIGUOUS(op)) || \
1613
+ ((order) == NPY_FORTRANORDER && PyArray_IS_F_CONTIGUOUS(op)))
1614
+
1615
+ static PyObject *
1616
+ _array_fromobject(PyObject *NPY_UNUSED(ignored), PyObject *args, PyObject *kws)
1617
+ {
1618
+ PyObject *op;
1619
+ PyArrayObject *oparr = NULL, *ret = NULL;
1620
+ npy_bool subok = NPY_FALSE;
1621
+ npy_bool copy = NPY_TRUE;
1622
+ int ndmin = 0, nd;
1623
+ PyArray_Descr *type = NULL;
1624
+ PyArray_Descr *oldtype = NULL;
1625
+ NPY_ORDER order = NPY_KEEPORDER;
1626
+ int flags = 0;
1627
+
1628
+ static char *kwd[]= {"object", "dtype", "copy", "order", "subok",
1629
+ "ndmin", NULL};
1630
+
1631
+ if (PyTuple_GET_SIZE(args) > 2) {
1632
+ PyErr_SetString(PyExc_ValueError,
1633
+ "only 2 non-keyword arguments accepted");
1634
+ return NULL;
1635
+ }
1636
+
1637
+ /* super-fast path for ndarray argument calls */
1638
+ if (PyTuple_GET_SIZE(args) == 0) {
1639
+ goto full_path;
1640
+ }
1641
+ op = PyTuple_GET_ITEM(args, 0);
1642
+ if (PyArray_CheckExact(op)) {
1643
+ PyObject * dtype_obj = Py_None;
1644
+ oparr = (PyArrayObject *)op;
1645
+ /* get dtype which can be positional */
1646
+ if (PyTuple_GET_SIZE(args) == 2) {
1647
+ dtype_obj = PyTuple_GET_ITEM(args, 1);
1648
+ }
1649
+ else if (kws) {
1650
+ dtype_obj = PyDict_GetItem(kws, npy_ma_str_dtype);
1651
+ if (dtype_obj == NULL) {
1652
+ dtype_obj = Py_None;
1653
+ }
1654
+ }
1655
+ if (dtype_obj != Py_None) {
1656
+ goto full_path;
1657
+ }
1658
+
1659
+ /* array(ndarray) */
1660
+ if (kws == NULL) {
1661
+ ret = (PyArrayObject *)PyArray_NewCopy(oparr, order);
1662
+ goto finish;
1663
+ }
1664
+ else {
1665
+ /* fast path for copy=False rest default (np.asarray) */
1666
+ PyObject * copy_obj, * order_obj, *ndmin_obj;
1667
+ copy_obj = PyDict_GetItem(kws, npy_ma_str_copy);
1668
+ if (copy_obj != Py_False) {
1669
+ goto full_path;
1670
+ }
1671
+ copy = NPY_FALSE;
1672
+
1673
+ /* order does not matter for contiguous 1d arrays */
1674
+ if (PyArray_NDIM((PyArrayObject*)op) > 1 ||
1675
+ !PyArray_IS_C_CONTIGUOUS((PyArrayObject*)op)) {
1676
+ order_obj = PyDict_GetItem(kws, npy_ma_str_order);
1677
+ if (order_obj != Py_None && order_obj != NULL) {
1678
+ goto full_path;
1679
+ }
1680
+ }
1681
+
1682
+ ndmin_obj = PyDict_GetItem(kws, npy_ma_str_ndmin);
1683
+ if (ndmin_obj) {
1684
+ ndmin = PyLong_AsLong(ndmin_obj);
1685
+ if (ndmin == -1 && PyErr_Occurred()) {
1686
+ goto clean_type;
1687
+ }
1688
+ else if (ndmin > NPY_MAXDIMS) {
1689
+ goto full_path;
1690
+ }
1691
+ }
1692
+
1693
+ /* copy=False with default dtype, order and ndim */
1694
+ if (STRIDING_OK(oparr, order)) {
1695
+ ret = oparr;
1696
+ Py_INCREF(ret);
1697
+ goto finish;
1698
+ }
1699
+ }
1700
+ }
1701
+
1702
+ full_path:
1703
+ if(!PyArg_ParseTupleAndKeywords(args, kws, "O|O&O&O&O&i", kwd,
1704
+ &op,
1705
+ PyArray_DescrConverter2, &type,
1706
+ PyArray_BoolConverter, &copy,
1707
+ PyArray_OrderConverter, &order,
1708
+ PyArray_BoolConverter, &subok,
1709
+ &ndmin)) {
1710
+ goto clean_type;
1711
+ }
1712
+
1713
+ if (ndmin > NPY_MAXDIMS) {
1714
+ PyErr_Format(PyExc_ValueError,
1715
+ "ndmin bigger than allowable number of dimensions "
1716
+ "NPY_MAXDIMS (=%d)", NPY_MAXDIMS);
1717
+ goto clean_type;
1718
+ }
1719
+ /* fast exit if simple call */
1720
+ if ((subok && PyArray_Check(op)) ||
1721
+ (!subok && PyArray_CheckExact(op))) {
1722
+ oparr = (PyArrayObject *)op;
1723
+ if (type == NULL) {
1724
+ if (!copy && STRIDING_OK(oparr, order)) {
1725
+ ret = oparr;
1726
+ Py_INCREF(ret);
1727
+ goto finish;
1728
+ }
1729
+ else {
1730
+ ret = (PyArrayObject *)PyArray_NewCopy(oparr, order);
1731
+ goto finish;
1732
+ }
1733
+ }
1734
+ /* One more chance */
1735
+ oldtype = PyArray_DESCR(oparr);
1736
+ if (PyArray_EquivTypes(oldtype, type)) {
1737
+ if (!copy && STRIDING_OK(oparr, order)) {
1738
+ Py_INCREF(op);
1739
+ ret = oparr;
1740
+ goto finish;
1741
+ }
1742
+ else {
1743
+ ret = (PyArrayObject *)PyArray_NewCopy(oparr, order);
1744
+ if (oldtype == type || ret == NULL) {
1745
+ goto finish;
1746
+ }
1747
+ Py_INCREF(oldtype);
1748
+ Py_DECREF(PyArray_DESCR(ret));
1749
+ ((PyArrayObject_fields *)ret)->descr = oldtype;
1750
+ goto finish;
1751
+ }
1752
+ }
1753
+ }
1754
+
1755
+ if (copy) {
1756
+ flags = NPY_ARRAY_ENSURECOPY;
1757
+ }
1758
+ if (order == NPY_CORDER) {
1759
+ flags |= NPY_ARRAY_C_CONTIGUOUS;
1760
+ }
1761
+ else if ((order == NPY_FORTRANORDER)
1762
+ /* order == NPY_ANYORDER && */
1763
+ || (PyArray_Check(op) &&
1764
+ PyArray_ISFORTRAN((PyArrayObject *)op))) {
1765
+ flags |= NPY_ARRAY_F_CONTIGUOUS;
1766
+ }
1767
+ if (!subok) {
1768
+ flags |= NPY_ARRAY_ENSUREARRAY;
1769
+ }
1770
+
1771
+ flags |= NPY_ARRAY_FORCECAST;
1772
+ Py_XINCREF(type);
1773
+ ret = (PyArrayObject *)PyArray_CheckFromAny(op, type,
1774
+ 0, 0, flags, NULL);
1775
+
1776
+ finish:
1777
+ Py_XDECREF(type);
1778
+ if (ret == NULL) {
1779
+ return NULL;
1780
+ }
1781
+
1782
+ nd = PyArray_NDIM(ret);
1783
+ if (nd >= ndmin) {
1784
+ return (PyObject *)ret;
1785
+ }
1786
+ /*
1787
+ * create a new array from the same data with ones in the shape
1788
+ * steals a reference to ret
1789
+ */
1790
+ return _prepend_ones(ret, nd, ndmin, order);
1791
+
1792
+ clean_type:
1793
+ Py_XDECREF(type);
1794
+ return NULL;
1795
+ }
1796
+
1797
+ static PyObject *
1798
+ array_copyto(PyObject *NPY_UNUSED(ignored), PyObject *args, PyObject *kwds)
1799
+ {
1800
+
1801
+ static char *kwlist[] = {"dst","src","casting","where",NULL};
1802
+ PyObject *wheremask_in = NULL;
1803
+ PyArrayObject *dst = NULL, *src = NULL, *wheremask = NULL;
1804
+ NPY_CASTING casting = NPY_SAME_KIND_CASTING;
1805
+
1806
+ if (!PyArg_ParseTupleAndKeywords(args, kwds, "O!O&|O&O", kwlist,
1807
+ &PyArray_Type, &dst,
1808
+ &PyArray_Converter, &src,
1809
+ &PyArray_CastingConverter, &casting,
1810
+ &wheremask_in)) {
1811
+ goto fail;
1812
+ }
1813
+
1814
+ if (wheremask_in != NULL) {
1815
+ /* Get the boolean where mask */
1816
+ PyArray_Descr *dtype = PyArray_DescrFromType(NPY_BOOL);
1817
+ if (dtype == NULL) {
1818
+ goto fail;
1819
+ }
1820
+ wheremask = (PyArrayObject *)PyArray_FromAny(wheremask_in,
1821
+ dtype, 0, 0, 0, NULL);
1822
+ if (wheremask == NULL) {
1823
+ goto fail;
1824
+ }
1825
+ }
1826
+
1827
+ if (PyArray_AssignArray(dst, src, wheremask, casting) < 0) {
1828
+ goto fail;
1829
+ }
1830
+
1831
+ Py_XDECREF(src);
1832
+ Py_XDECREF(wheremask);
1833
+
1834
+ Py_RETURN_NONE;
1835
+
1836
+ fail:
1837
+ Py_XDECREF(src);
1838
+ Py_XDECREF(wheremask);
1839
+ return NULL;
1840
+ }
1841
+
1842
+ static PyObject *
1843
+ array_empty(PyObject *NPY_UNUSED(ignored), PyObject *args, PyObject *kwds)
1844
+ {
1845
+
1846
+ static char *kwlist[] = {"shape","dtype","order",NULL};
1847
+ PyArray_Descr *typecode = NULL;
1848
+ PyArray_Dims shape = {NULL, 0};
1849
+ NPY_ORDER order = NPY_CORDER;
1850
+ npy_bool is_f_order;
1851
+ PyArrayObject *ret = NULL;
1852
+
1853
+ if (!PyArg_ParseTupleAndKeywords(args, kwds, "O&|O&O&", kwlist,
1854
+ PyArray_IntpConverter, &shape,
1855
+ PyArray_DescrConverter, &typecode,
1856
+ PyArray_OrderConverter, &order)) {
1857
+ goto fail;
1858
+ }
1859
+
1860
+ switch (order) {
1861
+ case NPY_CORDER:
1862
+ is_f_order = NPY_FALSE;
1863
+ break;
1864
+ case NPY_FORTRANORDER:
1865
+ is_f_order = NPY_TRUE;
1866
+ break;
1867
+ default:
1868
+ PyErr_SetString(PyExc_ValueError,
1869
+ "only 'C' or 'F' order is permitted");
1870
+ goto fail;
1871
+ }
1872
+
1873
+ ret = (PyArrayObject *)PyArray_Empty(shape.len, shape.ptr,
1874
+ typecode, is_f_order);
1875
+
1876
+ PyDimMem_FREE(shape.ptr);
1877
+ return (PyObject *)ret;
1878
+
1879
+ fail:
1880
+ Py_XDECREF(typecode);
1881
+ PyDimMem_FREE(shape.ptr);
1882
+ return NULL;
1883
+ }
1884
+
1885
+ static PyObject *
1886
+ array_empty_like(PyObject *NPY_UNUSED(ignored), PyObject *args, PyObject *kwds)
1887
+ {
1888
+
1889
+ static char *kwlist[] = {"prototype","dtype","order","subok",NULL};
1890
+ PyArrayObject *prototype = NULL;
1891
+ PyArray_Descr *dtype = NULL;
1892
+ NPY_ORDER order = NPY_KEEPORDER;
1893
+ PyArrayObject *ret = NULL;
1894
+ int subok = 1;
1895
+
1896
+ if (!PyArg_ParseTupleAndKeywords(args, kwds, "O&|O&O&i", kwlist,
1897
+ &PyArray_Converter, &prototype,
1898
+ &PyArray_DescrConverter2, &dtype,
1899
+ &PyArray_OrderConverter, &order,
1900
+ &subok)) {
1901
+ goto fail;
1902
+ }
1903
+ /* steals the reference to dtype if it's not NULL */
1904
+ ret = (PyArrayObject *)PyArray_NewLikeArray(prototype,
1905
+ order, dtype, subok);
1906
+ Py_DECREF(prototype);
1907
+
1908
+ return (PyObject *)ret;
1909
+
1910
+ fail:
1911
+ Py_XDECREF(prototype);
1912
+ Py_XDECREF(dtype);
1913
+ return NULL;
1914
+ }
1915
+
1916
+ /*
1917
+ * This function is needed for supporting Pickles of
1918
+ * numpy scalar objects.
1919
+ */
1920
+ static PyObject *
1921
+ array_scalar(PyObject *NPY_UNUSED(ignored), PyObject *args, PyObject *kwds)
1922
+ {
1923
+
1924
+ static char *kwlist[] = {"dtype","obj", NULL};
1925
+ PyArray_Descr *typecode;
1926
+ PyObject *obj = NULL, *tmpobj = NULL;
1927
+ int alloc = 0;
1928
+ void *dptr;
1929
+ PyObject *ret;
1930
+
1931
+
1932
+ if (!PyArg_ParseTupleAndKeywords(args, kwds, "O!|O", kwlist,
1933
+ &PyArrayDescr_Type, &typecode, &obj)) {
1934
+ return NULL;
1935
+ }
1936
+
1937
+ if (PyDataType_FLAGCHK(typecode, NPY_ITEM_IS_POINTER)) {
1938
+ if (obj == NULL) {
1939
+ obj = Py_None;
1940
+ }
1941
+ dptr = &obj;
1942
+ }
1943
+ else {
1944
+ if (obj == NULL) {
1945
+ if (typecode->elsize == 0) {
1946
+ typecode->elsize = 1;
1947
+ }
1948
+ dptr = PyArray_malloc(typecode->elsize);
1949
+ if (dptr == NULL) {
1950
+ return PyErr_NoMemory();
1951
+ }
1952
+ memset(dptr, '\0', typecode->elsize);
1953
+ alloc = 1;
1954
+ }
1955
+ else {
1956
+ #if defined(NPY_PY3K)
1957
+ /* Backward compatibility with Python 2 Numpy pickles */
1958
+ if (PyUnicode_Check(obj)) {
1959
+ tmpobj = PyUnicode_AsLatin1String(obj);
1960
+ obj = tmpobj;
1961
+ if (tmpobj == NULL) {
1962
+ /* More informative error message */
1963
+ PyErr_SetString(PyExc_ValueError,
1964
+ "Failed to encode Numpy scalar data string to "
1965
+ "latin1,\npickle.load(a, encoding='latin1') is "
1966
+ "assumed if unpickling.");
1967
+ return NULL;
1968
+ }
1969
+ }
1970
+ #endif
1971
+
1972
+ if (!PyString_Check(obj)) {
1973
+ PyErr_SetString(PyExc_TypeError,
1974
+ "initializing object must be a string");
1975
+ Py_XDECREF(tmpobj);
1976
+ return NULL;
1977
+ }
1978
+ if (PyString_GET_SIZE(obj) < typecode->elsize) {
1979
+ PyErr_SetString(PyExc_ValueError,
1980
+ "initialization string is too small");
1981
+ Py_XDECREF(tmpobj);
1982
+ return NULL;
1983
+ }
1984
+ dptr = PyString_AS_STRING(obj);
1985
+ }
1986
+ }
1987
+ ret = PyArray_Scalar(dptr, typecode, NULL);
1988
+
1989
+ /* free dptr which contains zeros */
1990
+ if (alloc) {
1991
+ PyArray_free(dptr);
1992
+ }
1993
+ Py_XDECREF(tmpobj);
1994
+ return ret;
1995
+ }
1996
+
1997
+ static PyObject *
1998
+ array_zeros(PyObject *NPY_UNUSED(ignored), PyObject *args, PyObject *kwds)
1999
+ {
2000
+ static char *kwlist[] = {"shape","dtype","order",NULL};
2001
+ PyArray_Descr *typecode = NULL;
2002
+ PyArray_Dims shape = {NULL, 0};
2003
+ NPY_ORDER order = NPY_CORDER;
2004
+ npy_bool is_f_order = NPY_FALSE;
2005
+ PyArrayObject *ret = NULL;
2006
+
2007
+ if (!PyArg_ParseTupleAndKeywords(args, kwds, "O&|O&O&", kwlist,
2008
+ PyArray_IntpConverter, &shape,
2009
+ PyArray_DescrConverter, &typecode,
2010
+ PyArray_OrderConverter, &order)) {
2011
+ goto fail;
2012
+ }
2013
+
2014
+ switch (order) {
2015
+ case NPY_CORDER:
2016
+ is_f_order = NPY_FALSE;
2017
+ break;
2018
+ case NPY_FORTRANORDER:
2019
+ is_f_order = NPY_TRUE;
2020
+ break;
2021
+ default:
2022
+ PyErr_SetString(PyExc_ValueError,
2023
+ "only 'C' or 'F' order is permitted");
2024
+ goto fail;
2025
+ }
2026
+
2027
+ ret = (PyArrayObject *)PyArray_Zeros(shape.len, shape.ptr,
2028
+ typecode, (int) is_f_order);
2029
+
2030
+ PyDimMem_FREE(shape.ptr);
2031
+ return (PyObject *)ret;
2032
+
2033
+ fail:
2034
+ Py_XDECREF(typecode);
2035
+ PyDimMem_FREE(shape.ptr);
2036
+ return (PyObject *)ret;
2037
+ }
2038
+
2039
+ static PyObject *
2040
+ array_count_nonzero(PyObject *NPY_UNUSED(self), PyObject *args, PyObject *kwds)
2041
+ {
2042
+ PyObject *array_in;
2043
+ PyArrayObject *array;
2044
+ npy_intp count;
2045
+
2046
+ if (!PyArg_ParseTuple(args, "O", &array_in)) {
2047
+ return NULL;
2048
+ }
2049
+
2050
+ array = (PyArrayObject *)PyArray_FromAny(array_in, NULL, 0, 0, 0, NULL);
2051
+ if (array == NULL) {
2052
+ return NULL;
2053
+ }
2054
+
2055
+ count = PyArray_CountNonzero(array);
2056
+
2057
+ Py_DECREF(array);
2058
+
2059
+ if (count == -1) {
2060
+ return NULL;
2061
+ }
2062
+ #if defined(NPY_PY3K)
2063
+ return PyLong_FromSsize_t(count);
2064
+ #else
2065
+ return PyInt_FromSsize_t(count);
2066
+ #endif
2067
+ }
2068
+
2069
+ static PyObject *
2070
+ array_fromstring(PyObject *NPY_UNUSED(ignored), PyObject *args, PyObject *keywds)
2071
+ {
2072
+ char *data;
2073
+ Py_ssize_t nin = -1;
2074
+ char *sep = NULL;
2075
+ Py_ssize_t s;
2076
+ static char *kwlist[] = {"string", "dtype", "count", "sep", NULL};
2077
+ PyArray_Descr *descr = NULL;
2078
+
2079
+ if (!PyArg_ParseTupleAndKeywords(args, keywds,
2080
+ "s#|O&" NPY_SSIZE_T_PYFMT "s", kwlist,
2081
+ &data, &s, PyArray_DescrConverter, &descr, &nin, &sep)) {
2082
+ Py_XDECREF(descr);
2083
+ return NULL;
2084
+ }
2085
+ return PyArray_FromString(data, (npy_intp)s, descr, (npy_intp)nin, sep);
2086
+ }
2087
+
2088
+
2089
+
2090
+ static PyObject *
2091
+ array_fromfile(PyObject *NPY_UNUSED(ignored), PyObject *args, PyObject *keywds)
2092
+ {
2093
+ PyObject *file = NULL, *ret;
2094
+ char *sep = "";
2095
+ Py_ssize_t nin = -1;
2096
+ static char *kwlist[] = {"file", "dtype", "count", "sep", NULL};
2097
+ PyArray_Descr *type = NULL;
2098
+ int own;
2099
+ npy_off_t orig_pos;
2100
+ FILE *fp;
2101
+
2102
+ if (!PyArg_ParseTupleAndKeywords(args, keywds,
2103
+ "O|O&" NPY_SSIZE_T_PYFMT "s", kwlist,
2104
+ &file, PyArray_DescrConverter, &type, &nin, &sep)) {
2105
+ Py_XDECREF(type);
2106
+ return NULL;
2107
+ }
2108
+ if (PyString_Check(file) || PyUnicode_Check(file)) {
2109
+ file = npy_PyFile_OpenFile(file, "rb");
2110
+ if (file == NULL) {
2111
+ return NULL;
2112
+ }
2113
+ own = 1;
2114
+ }
2115
+ else {
2116
+ Py_INCREF(file);
2117
+ own = 0;
2118
+ }
2119
+ fp = npy_PyFile_Dup2(file, "rb", &orig_pos);
2120
+ if (fp == NULL) {
2121
+ PyErr_SetString(PyExc_IOError,
2122
+ "first argument must be an open file");
2123
+ Py_DECREF(file);
2124
+ return NULL;
2125
+ }
2126
+ if (type == NULL) {
2127
+ type = PyArray_DescrFromType(NPY_DEFAULT_TYPE);
2128
+ }
2129
+ ret = PyArray_FromFile(fp, type, (npy_intp) nin, sep);
2130
+
2131
+ if (npy_PyFile_DupClose2(file, fp, orig_pos) < 0) {
2132
+ goto fail;
2133
+ }
2134
+ if (own && npy_PyFile_CloseFile(file) < 0) {
2135
+ goto fail;
2136
+ }
2137
+ Py_DECREF(file);
2138
+ return ret;
2139
+
2140
+ fail:
2141
+ Py_DECREF(file);
2142
+ Py_DECREF(ret);
2143
+ return NULL;
2144
+ }
2145
+
2146
+ static PyObject *
2147
+ array_fromiter(PyObject *NPY_UNUSED(ignored), PyObject *args, PyObject *keywds)
2148
+ {
2149
+ PyObject *iter;
2150
+ Py_ssize_t nin = -1;
2151
+ static char *kwlist[] = {"iter", "dtype", "count", NULL};
2152
+ PyArray_Descr *descr = NULL;
2153
+
2154
+ if (!PyArg_ParseTupleAndKeywords(args, keywds,
2155
+ "OO&|" NPY_SSIZE_T_PYFMT, kwlist,
2156
+ &iter, PyArray_DescrConverter, &descr, &nin)) {
2157
+ Py_XDECREF(descr);
2158
+ return NULL;
2159
+ }
2160
+ return PyArray_FromIter(iter, descr, (npy_intp)nin);
2161
+ }
2162
+
2163
+ static PyObject *
2164
+ array_frombuffer(PyObject *NPY_UNUSED(ignored), PyObject *args, PyObject *keywds)
2165
+ {
2166
+ PyObject *obj = NULL;
2167
+ Py_ssize_t nin = -1, offset = 0;
2168
+ static char *kwlist[] = {"buffer", "dtype", "count", "offset", NULL};
2169
+ PyArray_Descr *type = NULL;
2170
+
2171
+ if (!PyArg_ParseTupleAndKeywords(args, keywds,
2172
+ "O|O&" NPY_SSIZE_T_PYFMT NPY_SSIZE_T_PYFMT, kwlist,
2173
+ &obj, PyArray_DescrConverter, &type, &nin, &offset)) {
2174
+ Py_XDECREF(type);
2175
+ return NULL;
2176
+ }
2177
+ if (type == NULL) {
2178
+ type = PyArray_DescrFromType(NPY_DEFAULT_TYPE);
2179
+ }
2180
+ return PyArray_FromBuffer(obj, type, (npy_intp)nin, (npy_intp)offset);
2181
+ }
2182
+
2183
+ static PyObject *
2184
+ array_concatenate(PyObject *NPY_UNUSED(dummy), PyObject *args, PyObject *kwds)
2185
+ {
2186
+ PyObject *a0;
2187
+ int axis = 0;
2188
+ static char *kwlist[] = {"seq", "axis", NULL};
2189
+
2190
+ if (!PyArg_ParseTupleAndKeywords(args, kwds, "O|O&", kwlist,
2191
+ &a0, PyArray_AxisConverter, &axis)) {
2192
+ return NULL;
2193
+ }
2194
+ return PyArray_Concatenate(a0, axis);
2195
+ }
2196
+
2197
+ static PyObject *
2198
+ array_innerproduct(PyObject *NPY_UNUSED(dummy), PyObject *args)
2199
+ {
2200
+ PyObject *b0, *a0;
2201
+
2202
+ if (!PyArg_ParseTuple(args, "OO", &a0, &b0)) {
2203
+ return NULL;
2204
+ }
2205
+ return PyArray_Return((PyArrayObject *)PyArray_InnerProduct(a0, b0));
2206
+ }
2207
+
2208
+ static PyObject *
2209
+ array_matrixproduct(PyObject *NPY_UNUSED(dummy), PyObject *args, PyObject* kwds)
2210
+ {
2211
+ static PyUFuncObject *cached_npy_dot = NULL;
2212
+ int errval;
2213
+ PyObject *override = NULL;
2214
+ PyObject *v, *a, *o = NULL;
2215
+ PyArrayObject *ret;
2216
+ char* kwlist[] = {"a", "b", "out", NULL };
2217
+
2218
+ if (cached_npy_dot == NULL) {
2219
+ PyObject *module = PyImport_ImportModule("numpy.core.multiarray");
2220
+ cached_npy_dot = (PyUFuncObject*)PyDict_GetItemString(
2221
+ PyModule_GetDict(module), "dot");
2222
+
2223
+ Py_INCREF(cached_npy_dot);
2224
+ Py_DECREF(module);
2225
+ }
2226
+
2227
+ errval = PyUFunc_CheckOverride(cached_npy_dot, "__call__", args, kwds,
2228
+ &override, 2);
2229
+ if (errval) {
2230
+ return NULL;
2231
+ }
2232
+ else if (override) {
2233
+ return override;
2234
+ }
2235
+
2236
+ if (!PyArg_ParseTupleAndKeywords(args, kwds, "OO|O", kwlist, &a, &v, &o)) {
2237
+ return NULL;
2238
+ }
2239
+ if (o == Py_None) {
2240
+ o = NULL;
2241
+ }
2242
+ if (o != NULL && !PyArray_Check(o)) {
2243
+ PyErr_SetString(PyExc_TypeError,
2244
+ "'out' must be an array");
2245
+ return NULL;
2246
+ }
2247
+ ret = (PyArrayObject *)PyArray_MatrixProduct2(a, v, (PyArrayObject *)o);
2248
+ return PyArray_Return(ret);
2249
+ }
2250
+
2251
+
2252
+ static PyObject *
2253
+ array_vdot(PyObject *NPY_UNUSED(dummy), PyObject *args)
2254
+ {
2255
+ int typenum;
2256
+ char *ip1, *ip2, *op;
2257
+ npy_intp n, stride1, stride2;
2258
+ PyObject *op1, *op2;
2259
+ npy_intp newdimptr[1] = {-1};
2260
+ PyArray_Dims newdims = {newdimptr, 1};
2261
+ PyArrayObject *ap1 = NULL, *ap2 = NULL, *ret = NULL;
2262
+ PyArray_Descr *type;
2263
+ PyArray_DotFunc *vdot;
2264
+ NPY_BEGIN_THREADS_DEF;
2265
+
2266
+ if (!PyArg_ParseTuple(args, "OO", &op1, &op2)) {
2267
+ return NULL;
2268
+ }
2269
+
2270
+ /*
2271
+ * Conjugating dot product using the BLAS for vectors.
2272
+ * Flattens both op1 and op2 before dotting.
2273
+ */
2274
+ typenum = PyArray_ObjectType(op1, 0);
2275
+ typenum = PyArray_ObjectType(op2, typenum);
2276
+
2277
+ type = PyArray_DescrFromType(typenum);
2278
+ Py_INCREF(type);
2279
+ ap1 = (PyArrayObject *)PyArray_FromAny(op1, type, 0, 0, 0, NULL);
2280
+ if (ap1 == NULL) {
2281
+ Py_DECREF(type);
2282
+ goto fail;
2283
+ }
2284
+
2285
+ op1 = PyArray_Newshape(ap1, &newdims, NPY_CORDER);
2286
+ if (op1 == NULL) {
2287
+ Py_DECREF(type);
2288
+ goto fail;
2289
+ }
2290
+ Py_DECREF(ap1);
2291
+ ap1 = (PyArrayObject *)op1;
2292
+
2293
+ ap2 = (PyArrayObject *)PyArray_FromAny(op2, type, 0, 0, 0, NULL);
2294
+ if (ap2 == NULL) {
2295
+ goto fail;
2296
+ }
2297
+ op2 = PyArray_Newshape(ap2, &newdims, NPY_CORDER);
2298
+ if (op2 == NULL) {
2299
+ goto fail;
2300
+ }
2301
+ Py_DECREF(ap2);
2302
+ ap2 = (PyArrayObject *)op2;
2303
+
2304
+ if (PyArray_DIM(ap2, 0) != PyArray_DIM(ap1, 0)) {
2305
+ PyErr_SetString(PyExc_ValueError,
2306
+ "vectors have different lengths");
2307
+ goto fail;
2308
+ }
2309
+
2310
+ /* array scalar output */
2311
+ ret = new_array_for_sum(ap1, ap2, NULL, 0, (npy_intp *)NULL, typenum);
2312
+ if (ret == NULL) {
2313
+ goto fail;
2314
+ }
2315
+
2316
+ n = PyArray_DIM(ap1, 0);
2317
+ stride1 = PyArray_STRIDE(ap1, 0);
2318
+ stride2 = PyArray_STRIDE(ap2, 0);
2319
+ ip1 = PyArray_DATA(ap1);
2320
+ ip2 = PyArray_DATA(ap2);
2321
+ op = PyArray_DATA(ret);
2322
+
2323
+ switch (typenum) {
2324
+ case NPY_CFLOAT:
2325
+ vdot = (PyArray_DotFunc *)CFLOAT_vdot;
2326
+ break;
2327
+ case NPY_CDOUBLE:
2328
+ vdot = (PyArray_DotFunc *)CDOUBLE_vdot;
2329
+ break;
2330
+ case NPY_CLONGDOUBLE:
2331
+ vdot = (PyArray_DotFunc *)CLONGDOUBLE_vdot;
2332
+ break;
2333
+ case NPY_OBJECT:
2334
+ vdot = (PyArray_DotFunc *)OBJECT_vdot;
2335
+ break;
2336
+ default:
2337
+ vdot = type->f->dotfunc;
2338
+ if (vdot == NULL) {
2339
+ PyErr_SetString(PyExc_ValueError,
2340
+ "function not available for this data type");
2341
+ goto fail;
2342
+ }
2343
+ }
2344
+
2345
+ if (n < 500) {
2346
+ vdot(ip1, stride1, ip2, stride2, op, n, NULL);
2347
+ }
2348
+ else {
2349
+ NPY_BEGIN_THREADS_DESCR(type);
2350
+ vdot(ip1, stride1, ip2, stride2, op, n, NULL);
2351
+ NPY_END_THREADS_DESCR(type);
2352
+ }
2353
+
2354
+ Py_XDECREF(ap1);
2355
+ Py_XDECREF(ap2);
2356
+ return PyArray_Return(ret);
2357
+ fail:
2358
+ Py_XDECREF(ap1);
2359
+ Py_XDECREF(ap2);
2360
+ Py_XDECREF(ret);
2361
+ return NULL;
2362
+ }
2363
+
2364
+
2365
+
2366
+ /*
2367
+ * matmul
2368
+ *
2369
+ * Implements the protocol used by the '@' operator defined in PEP 364.
2370
+ * Not in the NUMPY API at this time, maybe later.
2371
+ *
2372
+ *
2373
+ * in1: Left hand side operand
2374
+ * in2: Right hand side operand
2375
+ * out: Either NULL, or an array into which the output should be placed.
2376
+ *
2377
+ * Returns NULL on error.
2378
+ * Returns NotImplemented on priority override.
2379
+ */
2380
+ static PyObject *
2381
+ array_matmul(PyObject *NPY_UNUSED(m), PyObject *args, PyObject* kwds)
2382
+ {
2383
+ static PyObject *matmul = NULL;
2384
+ int errval;
2385
+ PyObject *override = NULL;
2386
+ PyObject *in1, *in2, *out = NULL;
2387
+ char* kwlist[] = {"a", "b", "out", NULL };
2388
+ PyArrayObject *ap1, *ap2, *ret = NULL;
2389
+ NPY_ORDER order = NPY_KEEPORDER;
2390
+ NPY_CASTING casting = NPY_SAFE_CASTING;
2391
+ PyArray_Descr *dtype;
2392
+ int nd1, nd2, typenum;
2393
+ char *subscripts;
2394
+ PyArrayObject *ops[2];
2395
+
2396
+ npy_cache_import("numpy.core.multiarray", "matmul", &matmul);
2397
+ if (matmul == NULL) {
2398
+ return NULL;
2399
+ }
2400
+
2401
+ errval = PyUFunc_CheckOverride((PyUFuncObject*)matmul, "__call__",
2402
+ args, kwds, &override, 2);
2403
+ if (errval) {
2404
+ return NULL;
2405
+ }
2406
+ else if (override) {
2407
+ return override;
2408
+ }
2409
+
2410
+ if (!PyArg_ParseTupleAndKeywords(args, kwds, "OO|O", kwlist,
2411
+ &in1, &in2, &out)) {
2412
+ return NULL;
2413
+ }
2414
+
2415
+ if (out == Py_None) {
2416
+ out = NULL;
2417
+ }
2418
+ if (out != NULL && !PyArray_Check(out)) {
2419
+ PyErr_SetString(PyExc_TypeError,
2420
+ "'out' must be an array");
2421
+ return NULL;
2422
+ }
2423
+
2424
+ dtype = PyArray_DescrFromObject(in1, NULL);
2425
+ dtype = PyArray_DescrFromObject(in2, dtype);
2426
+ if (dtype == NULL) {
2427
+ PyErr_SetString(PyExc_ValueError,
2428
+ "Cannot find a common data type.");
2429
+ return NULL;
2430
+ }
2431
+ typenum = dtype->type_num;
2432
+
2433
+ if (typenum == NPY_OBJECT) {
2434
+ /* matmul is not currently implemented for object arrays */
2435
+ PyErr_SetString(PyExc_TypeError,
2436
+ "Object arrays are not currently supported");
2437
+ Py_DECREF(dtype);
2438
+ return NULL;
2439
+ }
2440
+
2441
+ ap1 = (PyArrayObject *)PyArray_FromAny(in1, dtype, 0, 0,
2442
+ NPY_ARRAY_ALIGNED, NULL);
2443
+ if (ap1 == NULL) {
2444
+ return NULL;
2445
+ }
2446
+
2447
+ Py_INCREF(dtype);
2448
+ ap2 = (PyArrayObject *)PyArray_FromAny(in2, dtype, 0, 0,
2449
+ NPY_ARRAY_ALIGNED, NULL);
2450
+ if (ap2 == NULL) {
2451
+ Py_DECREF(ap1);
2452
+ return NULL;
2453
+ }
2454
+
2455
+ if (PyArray_NDIM(ap1) == 0 || PyArray_NDIM(ap2) == 0) {
2456
+ /* Scalars are rejected */
2457
+ PyErr_SetString(PyExc_ValueError,
2458
+ "Scalar operands are not allowed, use '*' instead");
2459
+ return NULL;
2460
+ }
2461
+
2462
+ nd1 = PyArray_NDIM(ap1);
2463
+ nd2 = PyArray_NDIM(ap2);
2464
+
2465
+ #if defined(HAVE_CBLAS)
2466
+ if (nd1 <= 2 && nd2 <= 2 &&
2467
+ (NPY_DOUBLE == typenum || NPY_CDOUBLE == typenum ||
2468
+ NPY_FLOAT == typenum || NPY_CFLOAT == typenum)) {
2469
+ return cblas_matrixproduct(typenum, ap1, ap2, (PyArrayObject *)out);
2470
+ }
2471
+ #endif
2472
+
2473
+ /*
2474
+ * Use einsum for the stacked cases. This is a quick implementation
2475
+ * to avoid setting up the proper iterators. Einsum broadcasts, so
2476
+ * we need to check dimensions before the call.
2477
+ */
2478
+ if (nd1 == 1 && nd2 == 1) {
2479
+ /* vector vector */
2480
+ if (PyArray_DIM(ap1, 0) != PyArray_DIM(ap2, 0)) {
2481
+ dot_alignment_error(ap1, 0, ap2, 0);
2482
+ goto fail;
2483
+ }
2484
+ subscripts = "i, i";
2485
+ }
2486
+ else if (nd1 == 1) {
2487
+ /* vector matrix */
2488
+ if (PyArray_DIM(ap1, 0) != PyArray_DIM(ap2, nd2 - 2)) {
2489
+ dot_alignment_error(ap1, 0, ap2, nd2 - 2);
2490
+ goto fail;
2491
+ }
2492
+ subscripts = "i, ...ij";
2493
+ }
2494
+ else if (nd2 == 1) {
2495
+ /* matrix vector */
2496
+ if (PyArray_DIM(ap1, nd1 - 1) != PyArray_DIM(ap2, 0)) {
2497
+ dot_alignment_error(ap1, nd1 - 1, ap2, 0);
2498
+ goto fail;
2499
+ }
2500
+ subscripts = "...i, i";
2501
+ }
2502
+ else {
2503
+ /* matrix * matrix */
2504
+ if (PyArray_DIM(ap1, nd1 - 1) != PyArray_DIM(ap2, nd2 - 2)) {
2505
+ dot_alignment_error(ap1, nd1 - 1, ap2, nd2 - 2);
2506
+ goto fail;
2507
+ }
2508
+ subscripts = "...ij, ...jk";
2509
+ }
2510
+ ops[0] = ap1;
2511
+ ops[1] = ap2;
2512
+ ret = PyArray_EinsteinSum(subscripts, 2, ops, NULL, order, casting,
2513
+ (PyArrayObject *)out);
2514
+ Py_DECREF(ap1);
2515
+ Py_DECREF(ap2);
2516
+
2517
+ /* If no output was supplied, possibly convert to a scalar */
2518
+ if (ret != NULL && out == NULL) {
2519
+ return PyArray_Return((PyArrayObject *)ret);
2520
+ }
2521
+ return (PyObject *)ret;
2522
+
2523
+ fail:
2524
+ Py_XDECREF(ap1);
2525
+ Py_XDECREF(ap2);
2526
+ return NULL;
2527
+ }
2528
+
2529
+
2530
+ static int
2531
+ einsum_sub_op_from_str(PyObject *args, PyObject **str_obj, char **subscripts,
2532
+ PyArrayObject **op)
2533
+ {
2534
+ int i, nop;
2535
+ PyObject *subscripts_str;
2536
+
2537
+ nop = PyTuple_GET_SIZE(args) - 1;
2538
+ if (nop <= 0) {
2539
+ PyErr_SetString(PyExc_ValueError,
2540
+ "must specify the einstein sum subscripts string "
2541
+ "and at least one operand");
2542
+ return -1;
2543
+ }
2544
+ else if (nop >= NPY_MAXARGS) {
2545
+ PyErr_SetString(PyExc_ValueError, "too many operands");
2546
+ return -1;
2547
+ }
2548
+
2549
+ /* Get the subscripts string */
2550
+ subscripts_str = PyTuple_GET_ITEM(args, 0);
2551
+ if (PyUnicode_Check(subscripts_str)) {
2552
+ *str_obj = PyUnicode_AsASCIIString(subscripts_str);
2553
+ if (*str_obj == NULL) {
2554
+ return -1;
2555
+ }
2556
+ subscripts_str = *str_obj;
2557
+ }
2558
+
2559
+ *subscripts = PyBytes_AsString(subscripts_str);
2560
+ if (*subscripts == NULL) {
2561
+ Py_XDECREF(*str_obj);
2562
+ *str_obj = NULL;
2563
+ return -1;
2564
+ }
2565
+
2566
+ /* Set the operands to NULL */
2567
+ for (i = 0; i < nop; ++i) {
2568
+ op[i] = NULL;
2569
+ }
2570
+
2571
+ /* Get the operands */
2572
+ for (i = 0; i < nop; ++i) {
2573
+ PyObject *obj = PyTuple_GET_ITEM(args, i+1);
2574
+
2575
+ op[i] = (PyArrayObject *)PyArray_FromAny(obj,
2576
+ NULL, 0, 0, NPY_ARRAY_ENSUREARRAY, NULL);
2577
+ if (op[i] == NULL) {
2578
+ goto fail;
2579
+ }
2580
+ }
2581
+
2582
+ return nop;
2583
+
2584
+ fail:
2585
+ for (i = 0; i < nop; ++i) {
2586
+ Py_XDECREF(op[i]);
2587
+ op[i] = NULL;
2588
+ }
2589
+
2590
+ return -1;
2591
+ }
2592
+
2593
+ /*
2594
+ * Converts a list of subscripts to a string.
2595
+ *
2596
+ * Returns -1 on error, the number of characters placed in subscripts
2597
+ * otherwise.
2598
+ */
2599
+ static int
2600
+ einsum_list_to_subscripts(PyObject *obj, char *subscripts, int subsize)
2601
+ {
2602
+ int ellipsis = 0, subindex = 0;
2603
+ npy_intp i, size;
2604
+ PyObject *item;
2605
+
2606
+ obj = PySequence_Fast(obj, "the subscripts for each operand must "
2607
+ "be a list or a tuple");
2608
+ if (obj == NULL) {
2609
+ return -1;
2610
+ }
2611
+ size = PySequence_Size(obj);
2612
+
2613
+
2614
+ for (i = 0; i < size; ++i) {
2615
+ item = PySequence_Fast_GET_ITEM(obj, i);
2616
+ /* Ellipsis */
2617
+ if (item == Py_Ellipsis) {
2618
+ if (ellipsis) {
2619
+ PyErr_SetString(PyExc_ValueError,
2620
+ "each subscripts list may have only one ellipsis");
2621
+ Py_DECREF(obj);
2622
+ return -1;
2623
+ }
2624
+ if (subindex + 3 >= subsize) {
2625
+ PyErr_SetString(PyExc_ValueError,
2626
+ "subscripts list is too long");
2627
+ Py_DECREF(obj);
2628
+ return -1;
2629
+ }
2630
+ subscripts[subindex++] = '.';
2631
+ subscripts[subindex++] = '.';
2632
+ subscripts[subindex++] = '.';
2633
+ ellipsis = 1;
2634
+ }
2635
+ /* Subscript */
2636
+ else if (PyInt_Check(item) || PyLong_Check(item)) {
2637
+ long s = PyInt_AsLong(item);
2638
+ if ( s < 0 || s > 2*26) {
2639
+ PyErr_SetString(PyExc_ValueError,
2640
+ "subscript is not within the valid range [0, 52]");
2641
+ Py_DECREF(obj);
2642
+ return -1;
2643
+ }
2644
+ if (s < 26) {
2645
+ subscripts[subindex++] = 'A' + s;
2646
+ }
2647
+ else {
2648
+ subscripts[subindex++] = 'a' + s;
2649
+ }
2650
+ if (subindex >= subsize) {
2651
+ PyErr_SetString(PyExc_ValueError,
2652
+ "subscripts list is too long");
2653
+ Py_DECREF(obj);
2654
+ return -1;
2655
+ }
2656
+ }
2657
+ /* Invalid */
2658
+ else {
2659
+ PyErr_SetString(PyExc_ValueError,
2660
+ "each subscript must be either an integer "
2661
+ "or an ellipsis");
2662
+ Py_DECREF(obj);
2663
+ return -1;
2664
+ }
2665
+ }
2666
+
2667
+ Py_DECREF(obj);
2668
+
2669
+ return subindex;
2670
+ }
2671
+
2672
+ /*
2673
+ * Fills in the subscripts, with maximum size subsize, and op,
2674
+ * with the values in the tuple 'args'.
2675
+ *
2676
+ * Returns -1 on error, number of operands placed in op otherwise.
2677
+ */
2678
+ static int
2679
+ einsum_sub_op_from_lists(PyObject *args,
2680
+ char *subscripts, int subsize, PyArrayObject **op)
2681
+ {
2682
+ int subindex = 0;
2683
+ npy_intp i, nop;
2684
+
2685
+ nop = PyTuple_Size(args)/2;
2686
+
2687
+ if (nop == 0) {
2688
+ PyErr_SetString(PyExc_ValueError, "must provide at least an "
2689
+ "operand and a subscripts list to einsum");
2690
+ return -1;
2691
+ }
2692
+ else if(nop >= NPY_MAXARGS) {
2693
+ PyErr_SetString(PyExc_ValueError, "too many operands");
2694
+ return -1;
2695
+ }
2696
+
2697
+ /* Set the operands to NULL */
2698
+ for (i = 0; i < nop; ++i) {
2699
+ op[i] = NULL;
2700
+ }
2701
+
2702
+ /* Get the operands and build the subscript string */
2703
+ for (i = 0; i < nop; ++i) {
2704
+ PyObject *obj = PyTuple_GET_ITEM(args, 2*i);
2705
+ int n;
2706
+
2707
+ /* Comma between the subscripts for each operand */
2708
+ if (i != 0) {
2709
+ subscripts[subindex++] = ',';
2710
+ if (subindex >= subsize) {
2711
+ PyErr_SetString(PyExc_ValueError,
2712
+ "subscripts list is too long");
2713
+ goto fail;
2714
+ }
2715
+ }
2716
+
2717
+ op[i] = (PyArrayObject *)PyArray_FromAny(obj,
2718
+ NULL, 0, 0, NPY_ARRAY_ENSUREARRAY, NULL);
2719
+ if (op[i] == NULL) {
2720
+ goto fail;
2721
+ }
2722
+
2723
+ obj = PyTuple_GET_ITEM(args, 2*i+1);
2724
+ n = einsum_list_to_subscripts(obj, subscripts+subindex,
2725
+ subsize-subindex);
2726
+ if (n < 0) {
2727
+ goto fail;
2728
+ }
2729
+ subindex += n;
2730
+ }
2731
+
2732
+ /* Add the '->' to the string if provided */
2733
+ if (PyTuple_Size(args) == 2*nop+1) {
2734
+ PyObject *obj;
2735
+ int n;
2736
+
2737
+ if (subindex + 2 >= subsize) {
2738
+ PyErr_SetString(PyExc_ValueError,
2739
+ "subscripts list is too long");
2740
+ goto fail;
2741
+ }
2742
+ subscripts[subindex++] = '-';
2743
+ subscripts[subindex++] = '>';
2744
+
2745
+ obj = PyTuple_GET_ITEM(args, 2*nop);
2746
+ n = einsum_list_to_subscripts(obj, subscripts+subindex,
2747
+ subsize-subindex);
2748
+ if (n < 0) {
2749
+ goto fail;
2750
+ }
2751
+ subindex += n;
2752
+ }
2753
+
2754
+ /* NULL-terminate the subscripts string */
2755
+ subscripts[subindex] = '\0';
2756
+
2757
+ return nop;
2758
+
2759
+ fail:
2760
+ for (i = 0; i < nop; ++i) {
2761
+ Py_XDECREF(op[i]);
2762
+ op[i] = NULL;
2763
+ }
2764
+
2765
+ return -1;
2766
+ }
2767
+
2768
+ static PyObject *
2769
+ array_einsum(PyObject *NPY_UNUSED(dummy), PyObject *args, PyObject *kwds)
2770
+ {
2771
+ char *subscripts = NULL, subscripts_buffer[256];
2772
+ PyObject *str_obj = NULL, *str_key_obj = NULL;
2773
+ PyObject *arg0;
2774
+ int i, nop;
2775
+ PyArrayObject *op[NPY_MAXARGS];
2776
+ NPY_ORDER order = NPY_KEEPORDER;
2777
+ NPY_CASTING casting = NPY_SAFE_CASTING;
2778
+ PyArrayObject *out = NULL;
2779
+ PyArray_Descr *dtype = NULL;
2780
+ PyObject *ret = NULL;
2781
+
2782
+ if (PyTuple_GET_SIZE(args) < 1) {
2783
+ PyErr_SetString(PyExc_ValueError,
2784
+ "must specify the einstein sum subscripts string "
2785
+ "and at least one operand, or at least one operand "
2786
+ "and its corresponding subscripts list");
2787
+ return NULL;
2788
+ }
2789
+ arg0 = PyTuple_GET_ITEM(args, 0);
2790
+
2791
+ /* einsum('i,j', a, b), einsum('i,j->ij', a, b) */
2792
+ if (PyString_Check(arg0) || PyUnicode_Check(arg0)) {
2793
+ nop = einsum_sub_op_from_str(args, &str_obj, &subscripts, op);
2794
+ }
2795
+ /* einsum(a, [0], b, [1]), einsum(a, [0], b, [1], [0,1]) */
2796
+ else {
2797
+ nop = einsum_sub_op_from_lists(args, subscripts_buffer,
2798
+ sizeof(subscripts_buffer), op);
2799
+ subscripts = subscripts_buffer;
2800
+ }
2801
+ if (nop <= 0) {
2802
+ goto finish;
2803
+ }
2804
+
2805
+ /* Get the keyword arguments */
2806
+ if (kwds != NULL) {
2807
+ PyObject *key, *value;
2808
+ Py_ssize_t pos = 0;
2809
+ while (PyDict_Next(kwds, &pos, &key, &value)) {
2810
+ char *str = NULL;
2811
+
2812
+ #if defined(NPY_PY3K)
2813
+ Py_XDECREF(str_key_obj);
2814
+ str_key_obj = PyUnicode_AsASCIIString(key);
2815
+ if (str_key_obj != NULL) {
2816
+ key = str_key_obj;
2817
+ }
2818
+ #endif
2819
+
2820
+ str = PyBytes_AsString(key);
2821
+
2822
+ if (str == NULL) {
2823
+ PyErr_Clear();
2824
+ PyErr_SetString(PyExc_TypeError, "invalid keyword");
2825
+ goto finish;
2826
+ }
2827
+
2828
+ if (strcmp(str,"out") == 0) {
2829
+ if (PyArray_Check(value)) {
2830
+ out = (PyArrayObject *)value;
2831
+ }
2832
+ else {
2833
+ PyErr_SetString(PyExc_TypeError,
2834
+ "keyword parameter out must be an "
2835
+ "array for einsum");
2836
+ goto finish;
2837
+ }
2838
+ }
2839
+ else if (strcmp(str,"order") == 0) {
2840
+ if (!PyArray_OrderConverter(value, &order)) {
2841
+ goto finish;
2842
+ }
2843
+ }
2844
+ else if (strcmp(str,"casting") == 0) {
2845
+ if (!PyArray_CastingConverter(value, &casting)) {
2846
+ goto finish;
2847
+ }
2848
+ }
2849
+ else if (strcmp(str,"dtype") == 0) {
2850
+ if (!PyArray_DescrConverter2(value, &dtype)) {
2851
+ goto finish;
2852
+ }
2853
+ }
2854
+ else {
2855
+ PyErr_Format(PyExc_TypeError,
2856
+ "'%s' is an invalid keyword for einsum",
2857
+ str);
2858
+ goto finish;
2859
+ }
2860
+ }
2861
+ }
2862
+
2863
+ ret = (PyObject *)PyArray_EinsteinSum(subscripts, nop, op, dtype,
2864
+ order, casting, out);
2865
+
2866
+ /* If no output was supplied, possibly convert to a scalar */
2867
+ if (ret != NULL && out == NULL) {
2868
+ ret = PyArray_Return((PyArrayObject *)ret);
2869
+ }
2870
+
2871
+ finish:
2872
+ for (i = 0; i < nop; ++i) {
2873
+ Py_XDECREF(op[i]);
2874
+ }
2875
+ Py_XDECREF(dtype);
2876
+ Py_XDECREF(str_obj);
2877
+ Py_XDECREF(str_key_obj);
2878
+ /* out is a borrowed reference */
2879
+
2880
+ return ret;
2881
+ }
2882
+
2883
+ static PyObject *
2884
+ array_fastCopyAndTranspose(PyObject *NPY_UNUSED(dummy), PyObject *args)
2885
+ {
2886
+ PyObject *a0;
2887
+
2888
+ if (!PyArg_ParseTuple(args, "O", &a0)) {
2889
+ return NULL;
2890
+ }
2891
+ return PyArray_Return((PyArrayObject *)PyArray_CopyAndTranspose(a0));
2892
+ }
2893
+
2894
+ static PyObject *
2895
+ array_correlate(PyObject *NPY_UNUSED(dummy), PyObject *args, PyObject *kwds)
2896
+ {
2897
+ PyObject *shape, *a0;
2898
+ int mode = 0;
2899
+ static char *kwlist[] = {"a", "v", "mode", NULL};
2900
+
2901
+ if (!PyArg_ParseTupleAndKeywords(args, kwds, "OO|i", kwlist,
2902
+ &a0, &shape, &mode)) {
2903
+ return NULL;
2904
+ }
2905
+ return PyArray_Correlate(a0, shape, mode);
2906
+ }
2907
+
2908
+ static PyObject*
2909
+ array_correlate2(PyObject *NPY_UNUSED(dummy), PyObject *args, PyObject *kwds)
2910
+ {
2911
+ PyObject *shape, *a0;
2912
+ int mode = 0;
2913
+ static char *kwlist[] = {"a", "v", "mode", NULL};
2914
+
2915
+ if (!PyArg_ParseTupleAndKeywords(args, kwds, "OO|i", kwlist,
2916
+ &a0, &shape, &mode)) {
2917
+ return NULL;
2918
+ }
2919
+ return PyArray_Correlate2(a0, shape, mode);
2920
+ }
2921
+
2922
+ static PyObject *
2923
+ array_arange(PyObject *NPY_UNUSED(ignored), PyObject *args, PyObject *kws) {
2924
+ PyObject *o_start = NULL, *o_stop = NULL, *o_step = NULL, *range=NULL;
2925
+ static char *kwd[]= {"start", "stop", "step", "dtype", NULL};
2926
+ PyArray_Descr *typecode = NULL;
2927
+
2928
+ if(!PyArg_ParseTupleAndKeywords(args, kws, "O|OOO&", kwd,
2929
+ &o_start,
2930
+ &o_stop,
2931
+ &o_step,
2932
+ PyArray_DescrConverter2, &typecode)) {
2933
+ Py_XDECREF(typecode);
2934
+ return NULL;
2935
+ }
2936
+ range = PyArray_ArangeObj(o_start, o_stop, o_step, typecode);
2937
+ Py_XDECREF(typecode);
2938
+
2939
+ return range;
2940
+ }
2941
+
2942
+ /*NUMPY_API
2943
+ *
2944
+ * Included at the very first so not auto-grabbed and thus not labeled.
2945
+ */
2946
+ NPY_NO_EXPORT unsigned int
2947
+ PyArray_GetNDArrayCVersion(void)
2948
+ {
2949
+ return (unsigned int)NPY_ABI_VERSION;
2950
+ }
2951
+
2952
+ /*NUMPY_API
2953
+ * Returns the built-in (at compilation time) C API version
2954
+ */
2955
+ NPY_NO_EXPORT unsigned int
2956
+ PyArray_GetNDArrayCFeatureVersion(void)
2957
+ {
2958
+ return (unsigned int)NPY_API_VERSION;
2959
+ }
2960
+
2961
+ static PyObject *
2962
+ array__get_ndarray_c_version(PyObject *NPY_UNUSED(dummy), PyObject *args, PyObject *kwds)
2963
+ {
2964
+ static char *kwlist[] = {NULL};
2965
+
2966
+ if(!PyArg_ParseTupleAndKeywords(args, kwds, "", kwlist )) {
2967
+ return NULL;
2968
+ }
2969
+ return PyInt_FromLong( (long) PyArray_GetNDArrayCVersion() );
2970
+ }
2971
+
2972
+ /*NUMPY_API
2973
+ */
2974
+ NPY_NO_EXPORT int
2975
+ PyArray_GetEndianness(void)
2976
+ {
2977
+ const union {
2978
+ npy_uint32 i;
2979
+ char c[4];
2980
+ } bint = {0x01020304};
2981
+
2982
+ if (bint.c[0] == 1) {
2983
+ return NPY_CPU_BIG;
2984
+ }
2985
+ else if (bint.c[0] == 4) {
2986
+ return NPY_CPU_LITTLE;
2987
+ }
2988
+ else {
2989
+ return NPY_CPU_UNKNOWN_ENDIAN;
2990
+ }
2991
+ }
2992
+
2993
+ static PyObject *
2994
+ array__reconstruct(PyObject *NPY_UNUSED(dummy), PyObject *args)
2995
+ {
2996
+
2997
+ PyObject *ret;
2998
+ PyTypeObject *subtype;
2999
+ PyArray_Dims shape = {NULL, 0};
3000
+ PyArray_Descr *dtype = NULL;
3001
+
3002
+ evil_global_disable_warn_O4O8_flag = 1;
3003
+
3004
+ if (!PyArg_ParseTuple(args, "O!O&O&",
3005
+ &PyType_Type, &subtype,
3006
+ PyArray_IntpConverter, &shape,
3007
+ PyArray_DescrConverter, &dtype)) {
3008
+ goto fail;
3009
+ }
3010
+ if (!PyType_IsSubtype(subtype, &PyArray_Type)) {
3011
+ PyErr_SetString(PyExc_TypeError,
3012
+ "_reconstruct: First argument must be a sub-type of ndarray");
3013
+ goto fail;
3014
+ }
3015
+ ret = PyArray_NewFromDescr(subtype, dtype,
3016
+ (int)shape.len, shape.ptr, NULL, NULL, 0, NULL);
3017
+ PyDimMem_FREE(shape.ptr);
3018
+
3019
+ evil_global_disable_warn_O4O8_flag = 0;
3020
+
3021
+ return ret;
3022
+
3023
+ fail:
3024
+ evil_global_disable_warn_O4O8_flag = 0;
3025
+
3026
+ Py_XDECREF(dtype);
3027
+ PyDimMem_FREE(shape.ptr);
3028
+ return NULL;
3029
+ }
3030
+
3031
+ static PyObject *
3032
+ array_set_string_function(PyObject *NPY_UNUSED(self), PyObject *args,
3033
+ PyObject *kwds)
3034
+ {
3035
+ PyObject *op = NULL;
3036
+ int repr = 1;
3037
+ static char *kwlist[] = {"f", "repr", NULL};
3038
+
3039
+ if(!PyArg_ParseTupleAndKeywords(args, kwds, "|Oi", kwlist, &op, &repr)) {
3040
+ return NULL;
3041
+ }
3042
+ /* reset the array_repr function to built-in */
3043
+ if (op == Py_None) {
3044
+ op = NULL;
3045
+ }
3046
+ if (op != NULL && !PyCallable_Check(op)) {
3047
+ PyErr_SetString(PyExc_TypeError,
3048
+ "Argument must be callable.");
3049
+ return NULL;
3050
+ }
3051
+ PyArray_SetStringFunction(op, repr);
3052
+ Py_RETURN_NONE;
3053
+ }
3054
+
3055
+ static PyObject *
3056
+ array_set_ops_function(PyObject *NPY_UNUSED(self), PyObject *NPY_UNUSED(args),
3057
+ PyObject *kwds)
3058
+ {
3059
+ PyObject *oldops = NULL;
3060
+
3061
+ if ((oldops = PyArray_GetNumericOps()) == NULL) {
3062
+ return NULL;
3063
+ }
3064
+ /*
3065
+ * Should probably ensure that objects are at least callable
3066
+ * Leave this to the caller for now --- error will be raised
3067
+ * later when use is attempted
3068
+ */
3069
+ if (kwds && PyArray_SetNumericOps(kwds) == -1) {
3070
+ Py_DECREF(oldops);
3071
+ PyErr_SetString(PyExc_ValueError,
3072
+ "one or more objects not callable");
3073
+ return NULL;
3074
+ }
3075
+ return oldops;
3076
+ }
3077
+
3078
+ static PyObject *
3079
+ array_set_datetimeparse_function(PyObject *NPY_UNUSED(self),
3080
+ PyObject *NPY_UNUSED(args), PyObject *NPY_UNUSED(kwds))
3081
+ {
3082
+ PyErr_SetString(PyExc_RuntimeError, "This function has been removed");
3083
+ return NULL;
3084
+ }
3085
+
3086
+ /*
3087
+ * inner loop with constant size memcpy arguments
3088
+ * this allows the compiler to replace function calls while still handling the
3089
+ * alignment requirements of the platform.
3090
+ */
3091
+ #define INNER_WHERE_LOOP(size) \
3092
+ do { \
3093
+ npy_intp i; \
3094
+ for (i = 0; i < n; i++) { \
3095
+ if (*csrc) { \
3096
+ memcpy(dst, xsrc, size); \
3097
+ } \
3098
+ else { \
3099
+ memcpy(dst, ysrc, size); \
3100
+ } \
3101
+ dst += size; \
3102
+ xsrc += xstride; \
3103
+ ysrc += ystride; \
3104
+ csrc += cstride; \
3105
+ } \
3106
+ } while(0)
3107
+
3108
+
3109
+ /*NUMPY_API
3110
+ * Where
3111
+ */
3112
+ NPY_NO_EXPORT PyObject *
3113
+ PyArray_Where(PyObject *condition, PyObject *x, PyObject *y)
3114
+ {
3115
+ PyArrayObject *arr, *ax, *ay;
3116
+ PyObject *ret = NULL;
3117
+
3118
+ arr = (PyArrayObject *)PyArray_FromAny(condition, NULL, 0, 0, 0, NULL);
3119
+ if (arr == NULL) {
3120
+ return NULL;
3121
+ }
3122
+ if ((x == NULL) && (y == NULL)) {
3123
+ ret = PyArray_Nonzero(arr);
3124
+ Py_DECREF(arr);
3125
+ return ret;
3126
+ }
3127
+ if ((x == NULL) || (y == NULL)) {
3128
+ Py_DECREF(arr);
3129
+ PyErr_SetString(PyExc_ValueError,
3130
+ "either both or neither of x and y should be given");
3131
+ return NULL;
3132
+ }
3133
+
3134
+ ax = (PyArrayObject*)PyArray_FromAny(x, NULL, 0, 0, 0 ,NULL);
3135
+ ay = (PyArrayObject*)PyArray_FromAny(y, NULL, 0, 0, 0 ,NULL);
3136
+ if (ax == NULL || ay == NULL) {
3137
+ goto fail;
3138
+ }
3139
+ else {
3140
+ npy_uint32 flags = NPY_ITER_EXTERNAL_LOOP | NPY_ITER_BUFFERED |
3141
+ NPY_ITER_REFS_OK | NPY_ITER_ZEROSIZE_OK;
3142
+ PyArrayObject * op_in[4] = {
3143
+ NULL, arr, ax, ay
3144
+ };
3145
+ npy_uint32 op_flags[4] = {
3146
+ NPY_ITER_WRITEONLY | NPY_ITER_ALLOCATE | NPY_ITER_NO_SUBTYPE,
3147
+ NPY_ITER_READONLY, NPY_ITER_READONLY, NPY_ITER_READONLY
3148
+ };
3149
+ PyArray_Descr * common_dt = PyArray_ResultType(2, &op_in[0] + 2,
3150
+ 0, NULL);
3151
+ PyArray_Descr * op_dt[4] = {common_dt, PyArray_DescrFromType(NPY_BOOL),
3152
+ common_dt, common_dt};
3153
+ NpyIter * iter;
3154
+ int needs_api;
3155
+ NPY_BEGIN_THREADS_DEF;
3156
+
3157
+ if (common_dt == NULL || op_dt[1] == NULL) {
3158
+ Py_XDECREF(op_dt[1]);
3159
+ Py_XDECREF(common_dt);
3160
+ goto fail;
3161
+ }
3162
+ iter = NpyIter_MultiNew(4, op_in, flags,
3163
+ NPY_KEEPORDER, NPY_UNSAFE_CASTING,
3164
+ op_flags, op_dt);
3165
+ Py_DECREF(op_dt[1]);
3166
+ Py_DECREF(common_dt);
3167
+ if (iter == NULL) {
3168
+ goto fail;
3169
+ }
3170
+
3171
+ needs_api = NpyIter_IterationNeedsAPI(iter);
3172
+
3173
+ /* Get the result from the iterator object array */
3174
+ ret = (PyObject*)NpyIter_GetOperandArray(iter)[0];
3175
+
3176
+ NPY_BEGIN_THREADS_NDITER(iter);
3177
+
3178
+ if (NpyIter_GetIterSize(iter) != 0) {
3179
+ NpyIter_IterNextFunc *iternext = NpyIter_GetIterNext(iter, NULL);
3180
+ npy_intp * innersizeptr = NpyIter_GetInnerLoopSizePtr(iter);
3181
+ char **dataptrarray = NpyIter_GetDataPtrArray(iter);
3182
+
3183
+ do {
3184
+ PyArray_Descr * dtx = NpyIter_GetDescrArray(iter)[2];
3185
+ PyArray_Descr * dty = NpyIter_GetDescrArray(iter)[3];
3186
+ int axswap = PyDataType_ISBYTESWAPPED(dtx);
3187
+ int ayswap = PyDataType_ISBYTESWAPPED(dty);
3188
+ PyArray_CopySwapFunc *copyswapx = dtx->f->copyswap;
3189
+ PyArray_CopySwapFunc *copyswapy = dty->f->copyswap;
3190
+ int native = (axswap == ayswap) && (axswap == 0) && !needs_api;
3191
+ npy_intp n = (*innersizeptr);
3192
+ npy_intp itemsize = NpyIter_GetDescrArray(iter)[0]->elsize;
3193
+ npy_intp cstride = NpyIter_GetInnerStrideArray(iter)[1];
3194
+ npy_intp xstride = NpyIter_GetInnerStrideArray(iter)[2];
3195
+ npy_intp ystride = NpyIter_GetInnerStrideArray(iter)[3];
3196
+ char * dst = dataptrarray[0];
3197
+ char * csrc = dataptrarray[1];
3198
+ char * xsrc = dataptrarray[2];
3199
+ char * ysrc = dataptrarray[3];
3200
+
3201
+ /* constant sizes so compiler replaces memcpy */
3202
+ if (native && itemsize == 16) {
3203
+ INNER_WHERE_LOOP(16);
3204
+ }
3205
+ else if (native && itemsize == 8) {
3206
+ INNER_WHERE_LOOP(8);
3207
+ }
3208
+ else if (native && itemsize == 4) {
3209
+ INNER_WHERE_LOOP(4);
3210
+ }
3211
+ else if (native && itemsize == 2) {
3212
+ INNER_WHERE_LOOP(2);
3213
+ }
3214
+ else if (native && itemsize == 1) {
3215
+ INNER_WHERE_LOOP(1);
3216
+ }
3217
+ else {
3218
+ /* copyswap is faster than memcpy even if we are native */
3219
+ npy_intp i;
3220
+ for (i = 0; i < n; i++) {
3221
+ if (*csrc) {
3222
+ copyswapx(dst, xsrc, axswap, ret);
3223
+ }
3224
+ else {
3225
+ copyswapy(dst, ysrc, ayswap, ret);
3226
+ }
3227
+ dst += itemsize;
3228
+ xsrc += xstride;
3229
+ ysrc += ystride;
3230
+ csrc += cstride;
3231
+ }
3232
+ }
3233
+ } while (iternext(iter));
3234
+ }
3235
+
3236
+ NPY_END_THREADS;
3237
+
3238
+ Py_INCREF(ret);
3239
+ Py_DECREF(arr);
3240
+ Py_DECREF(ax);
3241
+ Py_DECREF(ay);
3242
+
3243
+ if (NpyIter_Deallocate(iter) != NPY_SUCCEED) {
3244
+ Py_DECREF(ret);
3245
+ return NULL;
3246
+ }
3247
+
3248
+ return ret;
3249
+ }
3250
+
3251
+ fail:
3252
+ Py_DECREF(arr);
3253
+ Py_XDECREF(ax);
3254
+ Py_XDECREF(ay);
3255
+ return NULL;
3256
+ }
3257
+
3258
+ #undef INNER_WHERE_LOOP
3259
+
3260
+ static PyObject *
3261
+ array_where(PyObject *NPY_UNUSED(ignored), PyObject *args)
3262
+ {
3263
+ PyObject *obj = NULL, *x = NULL, *y = NULL;
3264
+
3265
+ if (!PyArg_ParseTuple(args, "O|OO", &obj, &x, &y)) {
3266
+ return NULL;
3267
+ }
3268
+ return PyArray_Where(obj, x, y);
3269
+ }
3270
+
3271
+ static PyObject *
3272
+ array_lexsort(PyObject *NPY_UNUSED(ignored), PyObject *args, PyObject *kwds)
3273
+ {
3274
+ int axis = -1;
3275
+ PyObject *obj;
3276
+ static char *kwlist[] = {"keys", "axis", NULL};
3277
+
3278
+ if (!PyArg_ParseTupleAndKeywords(args, kwds, "O|i", kwlist, &obj, &axis)) {
3279
+ return NULL;
3280
+ }
3281
+ return PyArray_Return((PyArrayObject *)PyArray_LexSort(obj, axis));
3282
+ }
3283
+
3284
+ static PyObject *
3285
+ array_can_cast_safely(PyObject *NPY_UNUSED(self), PyObject *args,
3286
+ PyObject *kwds)
3287
+ {
3288
+ PyObject *from_obj = NULL;
3289
+ PyArray_Descr *d1 = NULL;
3290
+ PyArray_Descr *d2 = NULL;
3291
+ npy_bool ret;
3292
+ PyObject *retobj = NULL;
3293
+ NPY_CASTING casting = NPY_SAFE_CASTING;
3294
+ static char *kwlist[] = {"from", "to", "casting", NULL};
3295
+
3296
+ if(!PyArg_ParseTupleAndKeywords(args, kwds, "OO&|O&", kwlist,
3297
+ &from_obj,
3298
+ PyArray_DescrConverter2, &d2,
3299
+ PyArray_CastingConverter, &casting)) {
3300
+ goto finish;
3301
+ }
3302
+ if (d2 == NULL) {
3303
+ PyErr_SetString(PyExc_TypeError,
3304
+ "did not understand one of the types; 'None' not accepted");
3305
+ goto finish;
3306
+ }
3307
+
3308
+ /* If the first parameter is an object or scalar, use CanCastArrayTo */
3309
+ if (PyArray_Check(from_obj)) {
3310
+ ret = PyArray_CanCastArrayTo((PyArrayObject *)from_obj, d2, casting);
3311
+ }
3312
+ else if (PyArray_IsScalar(from_obj, Generic) ||
3313
+ PyArray_IsPythonNumber(from_obj)) {
3314
+ PyArrayObject *arr;
3315
+ arr = (PyArrayObject *)PyArray_FromAny(from_obj,
3316
+ NULL, 0, 0, 0, NULL);
3317
+ if (arr == NULL) {
3318
+ goto finish;
3319
+ }
3320
+ ret = PyArray_CanCastArrayTo(arr, d2, casting);
3321
+ Py_DECREF(arr);
3322
+ }
3323
+ /* Otherwise use CanCastTypeTo */
3324
+ else {
3325
+ if (!PyArray_DescrConverter2(from_obj, &d1) || d1 == NULL) {
3326
+ PyErr_SetString(PyExc_TypeError,
3327
+ "did not understand one of the types; 'None' not accepted");
3328
+ goto finish;
3329
+ }
3330
+ ret = PyArray_CanCastTypeTo(d1, d2, casting);
3331
+ }
3332
+
3333
+ retobj = ret ? Py_True : Py_False;
3334
+ Py_INCREF(retobj);
3335
+
3336
+ finish:
3337
+ Py_XDECREF(d1);
3338
+ Py_XDECREF(d2);
3339
+ return retobj;
3340
+ }
3341
+
3342
+ static PyObject *
3343
+ array_promote_types(PyObject *NPY_UNUSED(dummy), PyObject *args)
3344
+ {
3345
+ PyArray_Descr *d1 = NULL;
3346
+ PyArray_Descr *d2 = NULL;
3347
+ PyObject *ret = NULL;
3348
+ if(!PyArg_ParseTuple(args, "O&O&",
3349
+ PyArray_DescrConverter2, &d1, PyArray_DescrConverter2, &d2)) {
3350
+ goto finish;
3351
+ }
3352
+
3353
+ if (d1 == NULL || d2 == NULL) {
3354
+ PyErr_SetString(PyExc_TypeError,
3355
+ "did not understand one of the types");
3356
+ goto finish;
3357
+ }
3358
+
3359
+ ret = (PyObject *)PyArray_PromoteTypes(d1, d2);
3360
+
3361
+ finish:
3362
+ Py_XDECREF(d1);
3363
+ Py_XDECREF(d2);
3364
+ return ret;
3365
+ }
3366
+
3367
+ static PyObject *
3368
+ array_min_scalar_type(PyObject *NPY_UNUSED(dummy), PyObject *args)
3369
+ {
3370
+ PyObject *array_in = NULL;
3371
+ PyArrayObject *array;
3372
+ PyObject *ret = NULL;
3373
+
3374
+ if(!PyArg_ParseTuple(args, "O", &array_in)) {
3375
+ return NULL;
3376
+ }
3377
+
3378
+ array = (PyArrayObject *)PyArray_FromAny(array_in, NULL, 0, 0, 0, NULL);
3379
+ if (array == NULL) {
3380
+ return NULL;
3381
+ }
3382
+
3383
+ ret = (PyObject *)PyArray_MinScalarType(array);
3384
+ Py_DECREF(array);
3385
+ return ret;
3386
+ }
3387
+
3388
+ static PyObject *
3389
+ array_result_type(PyObject *NPY_UNUSED(dummy), PyObject *args)
3390
+ {
3391
+ npy_intp i, len, narr = 0, ndtypes = 0;
3392
+ PyArrayObject **arr = NULL;
3393
+ PyArray_Descr **dtypes = NULL;
3394
+ PyObject *ret = NULL;
3395
+
3396
+ len = PyTuple_GET_SIZE(args);
3397
+ if (len == 0) {
3398
+ PyErr_SetString(PyExc_ValueError,
3399
+ "at least one array or dtype is required");
3400
+ goto finish;
3401
+ }
3402
+
3403
+ arr = PyArray_malloc(2 * len * sizeof(void *));
3404
+ if (arr == NULL) {
3405
+ return PyErr_NoMemory();
3406
+ }
3407
+ dtypes = (PyArray_Descr**)&arr[len];
3408
+
3409
+ for (i = 0; i < len; ++i) {
3410
+ PyObject *obj = PyTuple_GET_ITEM(args, i);
3411
+ if (PyArray_Check(obj)) {
3412
+ Py_INCREF(obj);
3413
+ arr[narr] = (PyArrayObject *)obj;
3414
+ ++narr;
3415
+ }
3416
+ else if (PyArray_IsScalar(obj, Generic) ||
3417
+ PyArray_IsPythonNumber(obj)) {
3418
+ arr[narr] = (PyArrayObject *)PyArray_FromAny(obj,
3419
+ NULL, 0, 0, 0, NULL);
3420
+ if (arr[narr] == NULL) {
3421
+ goto finish;
3422
+ }
3423
+ ++narr;
3424
+ }
3425
+ else {
3426
+ if (!PyArray_DescrConverter(obj, &dtypes[ndtypes])) {
3427
+ goto finish;
3428
+ }
3429
+ ++ndtypes;
3430
+ }
3431
+ }
3432
+
3433
+ ret = (PyObject *)PyArray_ResultType(narr, arr, ndtypes, dtypes);
3434
+
3435
+ finish:
3436
+ for (i = 0; i < narr; ++i) {
3437
+ Py_DECREF(arr[i]);
3438
+ }
3439
+ for (i = 0; i < ndtypes; ++i) {
3440
+ Py_DECREF(dtypes[i]);
3441
+ }
3442
+ PyArray_free(arr);
3443
+ return ret;
3444
+ }
3445
+
3446
+ static PyObject *
3447
+ array_datetime_data(PyObject *NPY_UNUSED(dummy), PyObject *args)
3448
+ {
3449
+ PyArray_Descr *dtype;
3450
+ PyArray_DatetimeMetaData *meta;
3451
+
3452
+ if(!PyArg_ParseTuple(args, "O&:datetime_data",
3453
+ PyArray_DescrConverter, &dtype)) {
3454
+ return NULL;
3455
+ }
3456
+
3457
+ meta = get_datetime_metadata_from_dtype(dtype);
3458
+ if (meta == NULL) {
3459
+ return NULL;
3460
+ }
3461
+
3462
+ return convert_datetime_metadata_to_tuple(meta);
3463
+ }
3464
+
3465
+ #if !defined(NPY_PY3K)
3466
+ static PyObject *
3467
+ new_buffer(PyObject *NPY_UNUSED(dummy), PyObject *args)
3468
+ {
3469
+ int size;
3470
+
3471
+ if(!PyArg_ParseTuple(args, "i", &size)) {
3472
+ return NULL;
3473
+ }
3474
+ return PyBuffer_New(size);
3475
+ }
3476
+
3477
+ static PyObject *
3478
+ buffer_buffer(PyObject *NPY_UNUSED(dummy), PyObject *args, PyObject *kwds)
3479
+ {
3480
+ PyObject *obj;
3481
+ Py_ssize_t offset = 0, n;
3482
+ Py_ssize_t size = Py_END_OF_BUFFER;
3483
+ void *unused;
3484
+ static char *kwlist[] = {"object", "offset", "size", NULL};
3485
+
3486
+ if (!PyArg_ParseTupleAndKeywords(args, kwds,
3487
+ "O|" NPY_SSIZE_T_PYFMT NPY_SSIZE_T_PYFMT, kwlist,
3488
+ &obj, &offset, &size)) {
3489
+ return NULL;
3490
+ }
3491
+ if (PyObject_AsWriteBuffer(obj, &unused, &n) < 0) {
3492
+ PyErr_Clear();
3493
+ return PyBuffer_FromObject(obj, offset, size);
3494
+ }
3495
+ else {
3496
+ return PyBuffer_FromReadWriteObject(obj, offset, size);
3497
+ }
3498
+ }
3499
+ #endif
3500
+
3501
+ #ifndef _MSC_VER
3502
+ #include <setjmp.h>
3503
+ #include <signal.h>
3504
+ jmp_buf _NPY_SIGSEGV_BUF;
3505
+ static void
3506
+ _SigSegv_Handler(int signum)
3507
+ {
3508
+ longjmp(_NPY_SIGSEGV_BUF, signum);
3509
+ }
3510
+ #endif
3511
+
3512
+ #define _test_code() { \
3513
+ test = *((char*)memptr); \
3514
+ if (!ro) { \
3515
+ *((char *)memptr) = '\0'; \
3516
+ *((char *)memptr) = test; \
3517
+ } \
3518
+ test = *((char*)memptr+size-1); \
3519
+ if (!ro) { \
3520
+ *((char *)memptr+size-1) = '\0'; \
3521
+ *((char *)memptr+size-1) = test; \
3522
+ } \
3523
+ }
3524
+
3525
+ static PyObject *
3526
+ as_buffer(PyObject *NPY_UNUSED(dummy), PyObject *args, PyObject *kwds)
3527
+ {
3528
+ PyObject *mem;
3529
+ Py_ssize_t size;
3530
+ npy_bool ro = NPY_FALSE, check = NPY_TRUE;
3531
+ void *memptr;
3532
+ static char *kwlist[] = {"mem", "size", "readonly", "check", NULL};
3533
+
3534
+ if (!PyArg_ParseTupleAndKeywords(args, kwds,
3535
+ "O" NPY_SSIZE_T_PYFMT "|O&O&", kwlist,
3536
+ &mem, &size, PyArray_BoolConverter, &ro,
3537
+ PyArray_BoolConverter, &check)) {
3538
+ return NULL;
3539
+ }
3540
+ memptr = PyLong_AsVoidPtr(mem);
3541
+ if (memptr == NULL) {
3542
+ return NULL;
3543
+ }
3544
+ if (check) {
3545
+ /*
3546
+ * Try to dereference the start and end of the memory region
3547
+ * Catch segfault and report error if it occurs
3548
+ */
3549
+ char test;
3550
+ int err = 0;
3551
+
3552
+ #ifdef _MSC_VER
3553
+ __try {
3554
+ _test_code();
3555
+ }
3556
+ __except(1) {
3557
+ err = 1;
3558
+ }
3559
+ #else
3560
+ PyOS_sighandler_t _npy_sig_save;
3561
+ _npy_sig_save = PyOS_setsig(SIGSEGV, _SigSegv_Handler);
3562
+ if (setjmp(_NPY_SIGSEGV_BUF) == 0) {
3563
+ _test_code();
3564
+ }
3565
+ else {
3566
+ err = 1;
3567
+ }
3568
+ PyOS_setsig(SIGSEGV, _npy_sig_save);
3569
+ #endif
3570
+ if (err) {
3571
+ PyErr_SetString(PyExc_ValueError,
3572
+ "cannot use memory location as a buffer.");
3573
+ return NULL;
3574
+ }
3575
+ }
3576
+
3577
+
3578
+ #if defined(NPY_PY3K)
3579
+ PyErr_SetString(PyExc_RuntimeError,
3580
+ "XXX -- not implemented!");
3581
+ return NULL;
3582
+ #else
3583
+ if (ro) {
3584
+ return PyBuffer_FromMemory(memptr, size);
3585
+ }
3586
+ return PyBuffer_FromReadWriteMemory(memptr, size);
3587
+ #endif
3588
+ }
3589
+
3590
+ #undef _test_code
3591
+
3592
+ static PyObject *
3593
+ format_longfloat(PyObject *NPY_UNUSED(dummy), PyObject *args, PyObject *kwds)
3594
+ {
3595
+ PyObject *obj;
3596
+ unsigned int precision;
3597
+ npy_longdouble x;
3598
+ static char *kwlist[] = {"x", "precision", NULL};
3599
+ static char repr[100];
3600
+
3601
+ if (!PyArg_ParseTupleAndKeywords(args, kwds, "OI", kwlist,
3602
+ &obj, &precision)) {
3603
+ return NULL;
3604
+ }
3605
+ if (!PyArray_IsScalar(obj, LongDouble)) {
3606
+ PyErr_SetString(PyExc_TypeError,
3607
+ "not a longfloat");
3608
+ return NULL;
3609
+ }
3610
+ x = ((PyLongDoubleScalarObject *)obj)->obval;
3611
+ if (precision > 70) {
3612
+ precision = 70;
3613
+ }
3614
+ format_longdouble(repr, 100, x, precision);
3615
+ return PyUString_FromString(repr);
3616
+ }
3617
+
3618
+ static PyObject *
3619
+ compare_chararrays(PyObject *NPY_UNUSED(dummy), PyObject *args, PyObject *kwds)
3620
+ {
3621
+ PyObject *array;
3622
+ PyObject *other;
3623
+ PyArrayObject *newarr, *newoth;
3624
+ int cmp_op;
3625
+ npy_bool rstrip;
3626
+ char *cmp_str;
3627
+ Py_ssize_t strlength;
3628
+ PyObject *res = NULL;
3629
+ static char msg[] = "comparision must be '==', '!=', '<', '>', '<=', '>='";
3630
+ static char *kwlist[] = {"a1", "a2", "cmp", "rstrip", NULL};
3631
+
3632
+ if (!PyArg_ParseTupleAndKeywords(args, kwds, "OOs#O&", kwlist,
3633
+ &array, &other, &cmp_str, &strlength,
3634
+ PyArray_BoolConverter, &rstrip)) {
3635
+ return NULL;
3636
+ }
3637
+ if (strlength < 1 || strlength > 2) {
3638
+ goto err;
3639
+ }
3640
+ if (strlength > 1) {
3641
+ if (cmp_str[1] != '=') {
3642
+ goto err;
3643
+ }
3644
+ if (cmp_str[0] == '=') {
3645
+ cmp_op = Py_EQ;
3646
+ }
3647
+ else if (cmp_str[0] == '!') {
3648
+ cmp_op = Py_NE;
3649
+ }
3650
+ else if (cmp_str[0] == '<') {
3651
+ cmp_op = Py_LE;
3652
+ }
3653
+ else if (cmp_str[0] == '>') {
3654
+ cmp_op = Py_GE;
3655
+ }
3656
+ else {
3657
+ goto err;
3658
+ }
3659
+ }
3660
+ else {
3661
+ if (cmp_str[0] == '<') {
3662
+ cmp_op = Py_LT;
3663
+ }
3664
+ else if (cmp_str[0] == '>') {
3665
+ cmp_op = Py_GT;
3666
+ }
3667
+ else {
3668
+ goto err;
3669
+ }
3670
+ }
3671
+
3672
+ newarr = (PyArrayObject *)PyArray_FROM_O(array);
3673
+ if (newarr == NULL) {
3674
+ return NULL;
3675
+ }
3676
+ newoth = (PyArrayObject *)PyArray_FROM_O(other);
3677
+ if (newoth == NULL) {
3678
+ Py_DECREF(newarr);
3679
+ return NULL;
3680
+ }
3681
+ if (PyArray_ISSTRING(newarr) && PyArray_ISSTRING(newoth)) {
3682
+ res = _strings_richcompare(newarr, newoth, cmp_op, rstrip != 0);
3683
+ }
3684
+ else {
3685
+ PyErr_SetString(PyExc_TypeError,
3686
+ "comparison of non-string arrays");
3687
+ }
3688
+ Py_DECREF(newarr);
3689
+ Py_DECREF(newoth);
3690
+ return res;
3691
+
3692
+ err:
3693
+ PyErr_SetString(PyExc_ValueError, msg);
3694
+ return NULL;
3695
+ }
3696
+
3697
+ static PyObject *
3698
+ _vec_string_with_args(PyArrayObject* char_array, PyArray_Descr* type,
3699
+ PyObject* method, PyObject* args)
3700
+ {
3701
+ PyObject* broadcast_args[NPY_MAXARGS];
3702
+ PyArrayMultiIterObject* in_iter = NULL;
3703
+ PyArrayObject* result = NULL;
3704
+ PyArrayIterObject* out_iter = NULL;
3705
+ PyObject* args_tuple = NULL;
3706
+ Py_ssize_t i, n, nargs;
3707
+
3708
+ nargs = PySequence_Size(args) + 1;
3709
+ if (nargs == -1 || nargs > NPY_MAXARGS) {
3710
+ PyErr_Format(PyExc_ValueError,
3711
+ "len(args) must be < %d", NPY_MAXARGS - 1);
3712
+ goto err;
3713
+ }
3714
+
3715
+ broadcast_args[0] = (PyObject*)char_array;
3716
+ for (i = 1; i < nargs; i++) {
3717
+ PyObject* item = PySequence_GetItem(args, i-1);
3718
+ if (item == NULL) {
3719
+ goto err;
3720
+ }
3721
+ broadcast_args[i] = item;
3722
+ Py_DECREF(item);
3723
+ }
3724
+ in_iter = (PyArrayMultiIterObject*)PyArray_MultiIterFromObjects
3725
+ (broadcast_args, nargs, 0);
3726
+ if (in_iter == NULL) {
3727
+ goto err;
3728
+ }
3729
+ n = in_iter->numiter;
3730
+
3731
+ result = (PyArrayObject*)PyArray_SimpleNewFromDescr(in_iter->nd,
3732
+ in_iter->dimensions, type);
3733
+ if (result == NULL) {
3734
+ goto err;
3735
+ }
3736
+
3737
+ out_iter = (PyArrayIterObject*)PyArray_IterNew((PyObject*)result);
3738
+ if (out_iter == NULL) {
3739
+ goto err;
3740
+ }
3741
+
3742
+ args_tuple = PyTuple_New(n);
3743
+ if (args_tuple == NULL) {
3744
+ goto err;
3745
+ }
3746
+
3747
+ while (PyArray_MultiIter_NOTDONE(in_iter)) {
3748
+ PyObject* item_result;
3749
+
3750
+ for (i = 0; i < n; i++) {
3751
+ PyArrayIterObject* it = in_iter->iters[i];
3752
+ PyObject* arg = PyArray_ToScalar(PyArray_ITER_DATA(it), it->ao);
3753
+ if (arg == NULL) {
3754
+ goto err;
3755
+ }
3756
+ /* Steals ref to arg */
3757
+ PyTuple_SetItem(args_tuple, i, arg);
3758
+ }
3759
+
3760
+ item_result = PyObject_CallObject(method, args_tuple);
3761
+ if (item_result == NULL) {
3762
+ goto err;
3763
+ }
3764
+
3765
+ if (PyArray_SETITEM(result, PyArray_ITER_DATA(out_iter), item_result)) {
3766
+ Py_DECREF(item_result);
3767
+ PyErr_SetString( PyExc_TypeError,
3768
+ "result array type does not match underlying function");
3769
+ goto err;
3770
+ }
3771
+ Py_DECREF(item_result);
3772
+
3773
+ PyArray_MultiIter_NEXT(in_iter);
3774
+ PyArray_ITER_NEXT(out_iter);
3775
+ }
3776
+
3777
+ Py_DECREF(in_iter);
3778
+ Py_DECREF(out_iter);
3779
+ Py_DECREF(args_tuple);
3780
+
3781
+ return (PyObject*)result;
3782
+
3783
+ err:
3784
+ Py_XDECREF(in_iter);
3785
+ Py_XDECREF(out_iter);
3786
+ Py_XDECREF(args_tuple);
3787
+ Py_XDECREF(result);
3788
+
3789
+ return 0;
3790
+ }
3791
+
3792
+ static PyObject *
3793
+ _vec_string_no_args(PyArrayObject* char_array,
3794
+ PyArray_Descr* type, PyObject* method)
3795
+ {
3796
+ /*
3797
+ * This is a faster version of _vec_string_args to use when there
3798
+ * are no additional arguments to the string method. This doesn't
3799
+ * require a broadcast iterator (and broadcast iterators don't work
3800
+ * with 1 argument anyway).
3801
+ */
3802
+ PyArrayIterObject* in_iter = NULL;
3803
+ PyArrayObject* result = NULL;
3804
+ PyArrayIterObject* out_iter = NULL;
3805
+
3806
+ in_iter = (PyArrayIterObject*)PyArray_IterNew((PyObject*)char_array);
3807
+ if (in_iter == NULL) {
3808
+ goto err;
3809
+ }
3810
+
3811
+ result = (PyArrayObject*)PyArray_SimpleNewFromDescr(
3812
+ PyArray_NDIM(char_array), PyArray_DIMS(char_array), type);
3813
+ if (result == NULL) {
3814
+ goto err;
3815
+ }
3816
+
3817
+ out_iter = (PyArrayIterObject*)PyArray_IterNew((PyObject*)result);
3818
+ if (out_iter == NULL) {
3819
+ goto err;
3820
+ }
3821
+
3822
+ while (PyArray_ITER_NOTDONE(in_iter)) {
3823
+ PyObject* item_result;
3824
+ PyObject* item = PyArray_ToScalar(in_iter->dataptr, in_iter->ao);
3825
+ if (item == NULL) {
3826
+ goto err;
3827
+ }
3828
+
3829
+ item_result = PyObject_CallFunctionObjArgs(method, item, NULL);
3830
+ Py_DECREF(item);
3831
+ if (item_result == NULL) {
3832
+ goto err;
3833
+ }
3834
+
3835
+ if (PyArray_SETITEM(result, PyArray_ITER_DATA(out_iter), item_result)) {
3836
+ Py_DECREF(item_result);
3837
+ PyErr_SetString( PyExc_TypeError,
3838
+ "result array type does not match underlying function");
3839
+ goto err;
3840
+ }
3841
+ Py_DECREF(item_result);
3842
+
3843
+ PyArray_ITER_NEXT(in_iter);
3844
+ PyArray_ITER_NEXT(out_iter);
3845
+ }
3846
+
3847
+ Py_DECREF(in_iter);
3848
+ Py_DECREF(out_iter);
3849
+
3850
+ return (PyObject*)result;
3851
+
3852
+ err:
3853
+ Py_XDECREF(in_iter);
3854
+ Py_XDECREF(out_iter);
3855
+ Py_XDECREF(result);
3856
+
3857
+ return 0;
3858
+ }
3859
+
3860
+ static PyObject *
3861
+ _vec_string(PyObject *NPY_UNUSED(dummy), PyObject *args, PyObject *kwds)
3862
+ {
3863
+ PyArrayObject* char_array = NULL;
3864
+ PyArray_Descr *type = NULL;
3865
+ PyObject* method_name;
3866
+ PyObject* args_seq = NULL;
3867
+
3868
+ PyObject* method = NULL;
3869
+ PyObject* result = NULL;
3870
+
3871
+ if (!PyArg_ParseTuple(args, "O&O&O|O",
3872
+ PyArray_Converter, &char_array,
3873
+ PyArray_DescrConverter, &type,
3874
+ &method_name, &args_seq)) {
3875
+ goto err;
3876
+ }
3877
+
3878
+ if (PyArray_TYPE(char_array) == NPY_STRING) {
3879
+ method = PyObject_GetAttr((PyObject *)&PyString_Type, method_name);
3880
+ }
3881
+ else if (PyArray_TYPE(char_array) == NPY_UNICODE) {
3882
+ method = PyObject_GetAttr((PyObject *)&PyUnicode_Type, method_name);
3883
+ }
3884
+ else {
3885
+ PyErr_SetString(PyExc_TypeError,
3886
+ "string operation on non-string array");
3887
+ goto err;
3888
+ }
3889
+ if (method == NULL) {
3890
+ goto err;
3891
+ }
3892
+
3893
+ if (args_seq == NULL
3894
+ || (PySequence_Check(args_seq) && PySequence_Size(args_seq) == 0)) {
3895
+ result = _vec_string_no_args(char_array, type, method);
3896
+ }
3897
+ else if (PySequence_Check(args_seq)) {
3898
+ result = _vec_string_with_args(char_array, type, method, args_seq);
3899
+ }
3900
+ else {
3901
+ PyErr_SetString(PyExc_TypeError,
3902
+ "'args' must be a sequence of arguments");
3903
+ goto err;
3904
+ }
3905
+ if (result == NULL) {
3906
+ goto err;
3907
+ }
3908
+
3909
+ Py_DECREF(char_array);
3910
+ Py_DECREF(method);
3911
+
3912
+ return (PyObject*)result;
3913
+
3914
+ err:
3915
+ Py_XDECREF(char_array);
3916
+ Py_XDECREF(method);
3917
+
3918
+ return 0;
3919
+ }
3920
+
3921
+ #ifndef __NPY_PRIVATE_NO_SIGNAL
3922
+
3923
+ static NPY_TLS int sigint_buf_init = 0;
3924
+ static NPY_TLS NPY_SIGJMP_BUF _NPY_SIGINT_BUF;
3925
+
3926
+ /*NUMPY_API
3927
+ */
3928
+ NPY_NO_EXPORT void
3929
+ _PyArray_SigintHandler(int signum)
3930
+ {
3931
+ PyOS_setsig(signum, SIG_IGN);
3932
+ /*
3933
+ * jump buffer may be unitialized as SIGINT allowing functions are usually
3934
+ * run in other threads than the master thread that receives the signal
3935
+ */
3936
+ if (sigint_buf_init > 0) {
3937
+ NPY_SIGLONGJMP(_NPY_SIGINT_BUF, signum);
3938
+ }
3939
+ /*
3940
+ * sending SIGINT to the worker threads to cancel them is job of the
3941
+ * application
3942
+ */
3943
+ }
3944
+
3945
+ /*NUMPY_API
3946
+ */
3947
+ NPY_NO_EXPORT void*
3948
+ _PyArray_GetSigintBuf(void)
3949
+ {
3950
+ sigint_buf_init = 1;
3951
+ return (void *)&_NPY_SIGINT_BUF;
3952
+ }
3953
+
3954
+ #else
3955
+
3956
+ NPY_NO_EXPORT void
3957
+ _PyArray_SigintHandler(int signum)
3958
+ {
3959
+ return;
3960
+ }
3961
+
3962
+ NPY_NO_EXPORT void*
3963
+ _PyArray_GetSigintBuf(void)
3964
+ {
3965
+ return NULL;
3966
+ }
3967
+
3968
+ #endif
3969
+
3970
+
3971
+ static PyObject *
3972
+ test_interrupt(PyObject *NPY_UNUSED(self), PyObject *args)
3973
+ {
3974
+ int kind = 0;
3975
+ int a = 0;
3976
+
3977
+ if (!PyArg_ParseTuple(args, "|i", &kind)) {
3978
+ return NULL;
3979
+ }
3980
+ if (kind) {
3981
+ Py_BEGIN_ALLOW_THREADS;
3982
+ while (a >= 0) {
3983
+ if ((a % 1000 == 0) && PyOS_InterruptOccurred()) {
3984
+ break;
3985
+ }
3986
+ a += 1;
3987
+ }
3988
+ Py_END_ALLOW_THREADS;
3989
+ }
3990
+ else {
3991
+ NPY_SIGINT_ON
3992
+ while(a >= 0) {
3993
+ a += 1;
3994
+ }
3995
+ NPY_SIGINT_OFF
3996
+ }
3997
+ return PyInt_FromLong(a);
3998
+ }
3999
+
4000
+ static PyObject *
4001
+ array_may_share_memory(PyObject *NPY_UNUSED(ignored), PyObject *args)
4002
+ {
4003
+ PyArrayObject * self = NULL;
4004
+ PyArrayObject * other = NULL;
4005
+ int overlap;
4006
+
4007
+ if (!PyArg_ParseTuple(args, "O&O&", PyArray_Converter, &self,
4008
+ PyArray_Converter, &other)) {
4009
+ return NULL;
4010
+ }
4011
+
4012
+ overlap = arrays_overlap(self, other);
4013
+ Py_XDECREF(self);
4014
+ Py_XDECREF(other);
4015
+
4016
+ if (overlap) {
4017
+ Py_RETURN_TRUE;
4018
+ }
4019
+ else {
4020
+ Py_RETURN_FALSE;
4021
+ }
4022
+ }
4023
+
4024
+ static struct PyMethodDef array_module_methods[] = {
4025
+ {"_get_ndarray_c_version",
4026
+ (PyCFunction)array__get_ndarray_c_version,
4027
+ METH_VARARGS|METH_KEYWORDS, NULL},
4028
+ {"_reconstruct",
4029
+ (PyCFunction)array__reconstruct,
4030
+ METH_VARARGS, NULL},
4031
+ {"set_string_function",
4032
+ (PyCFunction)array_set_string_function,
4033
+ METH_VARARGS|METH_KEYWORDS, NULL},
4034
+ {"set_numeric_ops",
4035
+ (PyCFunction)array_set_ops_function,
4036
+ METH_VARARGS|METH_KEYWORDS, NULL},
4037
+ {"set_datetimeparse_function",
4038
+ (PyCFunction)array_set_datetimeparse_function,
4039
+ METH_VARARGS|METH_KEYWORDS, NULL},
4040
+ {"set_typeDict",
4041
+ (PyCFunction)array_set_typeDict,
4042
+ METH_VARARGS, NULL},
4043
+ {"array",
4044
+ (PyCFunction)_array_fromobject,
4045
+ METH_VARARGS|METH_KEYWORDS, NULL},
4046
+ {"copyto",
4047
+ (PyCFunction)array_copyto,
4048
+ METH_VARARGS|METH_KEYWORDS, NULL},
4049
+ {"nested_iters",
4050
+ (PyCFunction)NpyIter_NestedIters,
4051
+ METH_VARARGS|METH_KEYWORDS, NULL},
4052
+ {"arange",
4053
+ (PyCFunction)array_arange,
4054
+ METH_VARARGS|METH_KEYWORDS, NULL},
4055
+ {"zeros",
4056
+ (PyCFunction)array_zeros,
4057
+ METH_VARARGS|METH_KEYWORDS, NULL},
4058
+ {"count_nonzero",
4059
+ (PyCFunction)array_count_nonzero,
4060
+ METH_VARARGS|METH_KEYWORDS, NULL},
4061
+ {"empty",
4062
+ (PyCFunction)array_empty,
4063
+ METH_VARARGS|METH_KEYWORDS, NULL},
4064
+ {"empty_like",
4065
+ (PyCFunction)array_empty_like,
4066
+ METH_VARARGS|METH_KEYWORDS, NULL},
4067
+ {"scalar",
4068
+ (PyCFunction)array_scalar,
4069
+ METH_VARARGS|METH_KEYWORDS, NULL},
4070
+ {"where",
4071
+ (PyCFunction)array_where,
4072
+ METH_VARARGS, NULL},
4073
+ {"lexsort",
4074
+ (PyCFunction)array_lexsort,
4075
+ METH_VARARGS | METH_KEYWORDS, NULL},
4076
+ {"putmask",
4077
+ (PyCFunction)array_putmask,
4078
+ METH_VARARGS | METH_KEYWORDS, NULL},
4079
+ {"fromstring",
4080
+ (PyCFunction)array_fromstring,
4081
+ METH_VARARGS|METH_KEYWORDS, NULL},
4082
+ {"fromiter",
4083
+ (PyCFunction)array_fromiter,
4084
+ METH_VARARGS|METH_KEYWORDS, NULL},
4085
+ {"concatenate",
4086
+ (PyCFunction)array_concatenate,
4087
+ METH_VARARGS|METH_KEYWORDS, NULL},
4088
+ {"inner",
4089
+ (PyCFunction)array_innerproduct,
4090
+ METH_VARARGS, NULL},
4091
+ {"dot",
4092
+ (PyCFunction)array_matrixproduct,
4093
+ METH_VARARGS | METH_KEYWORDS, NULL},
4094
+ {"vdot",
4095
+ (PyCFunction)array_vdot,
4096
+ METH_VARARGS | METH_KEYWORDS, NULL},
4097
+ {"matmul",
4098
+ (PyCFunction)array_matmul,
4099
+ METH_VARARGS | METH_KEYWORDS, NULL},
4100
+ {"einsum",
4101
+ (PyCFunction)array_einsum,
4102
+ METH_VARARGS|METH_KEYWORDS, NULL},
4103
+ {"_fastCopyAndTranspose",
4104
+ (PyCFunction)array_fastCopyAndTranspose,
4105
+ METH_VARARGS, NULL},
4106
+ {"correlate",
4107
+ (PyCFunction)array_correlate,
4108
+ METH_VARARGS | METH_KEYWORDS, NULL},
4109
+ {"correlate2",
4110
+ (PyCFunction)array_correlate2,
4111
+ METH_VARARGS | METH_KEYWORDS, NULL},
4112
+ {"frombuffer",
4113
+ (PyCFunction)array_frombuffer,
4114
+ METH_VARARGS | METH_KEYWORDS, NULL},
4115
+ {"fromfile",
4116
+ (PyCFunction)array_fromfile,
4117
+ METH_VARARGS | METH_KEYWORDS, NULL},
4118
+ {"can_cast",
4119
+ (PyCFunction)array_can_cast_safely,
4120
+ METH_VARARGS | METH_KEYWORDS, NULL},
4121
+ {"promote_types",
4122
+ (PyCFunction)array_promote_types,
4123
+ METH_VARARGS, NULL},
4124
+ {"min_scalar_type",
4125
+ (PyCFunction)array_min_scalar_type,
4126
+ METH_VARARGS, NULL},
4127
+ {"result_type",
4128
+ (PyCFunction)array_result_type,
4129
+ METH_VARARGS, NULL},
4130
+ {"may_share_memory",
4131
+ (PyCFunction)array_may_share_memory,
4132
+ METH_VARARGS, NULL},
4133
+ /* Datetime-related functions */
4134
+ {"datetime_data",
4135
+ (PyCFunction)array_datetime_data,
4136
+ METH_VARARGS, NULL},
4137
+ {"datetime_as_string",
4138
+ (PyCFunction)array_datetime_as_string,
4139
+ METH_VARARGS | METH_KEYWORDS, NULL},
4140
+ /* Datetime business-day API */
4141
+ {"busday_offset",
4142
+ (PyCFunction)array_busday_offset,
4143
+ METH_VARARGS | METH_KEYWORDS, NULL},
4144
+ {"busday_count",
4145
+ (PyCFunction)array_busday_count,
4146
+ METH_VARARGS | METH_KEYWORDS, NULL},
4147
+ {"is_busday",
4148
+ (PyCFunction)array_is_busday,
4149
+ METH_VARARGS | METH_KEYWORDS, NULL},
4150
+ #if !defined(NPY_PY3K)
4151
+ {"newbuffer",
4152
+ (PyCFunction)new_buffer,
4153
+ METH_VARARGS, NULL},
4154
+ {"getbuffer",
4155
+ (PyCFunction)buffer_buffer,
4156
+ METH_VARARGS | METH_KEYWORDS, NULL},
4157
+ #endif
4158
+ {"int_asbuffer",
4159
+ (PyCFunction)as_buffer,
4160
+ METH_VARARGS | METH_KEYWORDS, NULL},
4161
+ {"format_longfloat",
4162
+ (PyCFunction)format_longfloat,
4163
+ METH_VARARGS | METH_KEYWORDS, NULL},
4164
+ {"compare_chararrays",
4165
+ (PyCFunction)compare_chararrays,
4166
+ METH_VARARGS | METH_KEYWORDS, NULL},
4167
+ {"_vec_string",
4168
+ (PyCFunction)_vec_string,
4169
+ METH_VARARGS | METH_KEYWORDS, NULL},
4170
+ {"test_interrupt",
4171
+ (PyCFunction)test_interrupt,
4172
+ METH_VARARGS, NULL},
4173
+ {"_insert", (PyCFunction)arr_insert,
4174
+ METH_VARARGS | METH_KEYWORDS,
4175
+ "Insert vals sequentially into equivalent 1-d positions "
4176
+ "indicated by mask."},
4177
+ {"bincount", (PyCFunction)arr_bincount,
4178
+ METH_VARARGS | METH_KEYWORDS, NULL},
4179
+ {"digitize", (PyCFunction)arr_digitize,
4180
+ METH_VARARGS | METH_KEYWORDS, NULL},
4181
+ {"interp", (PyCFunction)arr_interp,
4182
+ METH_VARARGS | METH_KEYWORDS, NULL},
4183
+ {"ravel_multi_index", (PyCFunction)arr_ravel_multi_index,
4184
+ METH_VARARGS | METH_KEYWORDS, NULL},
4185
+ {"unravel_index", (PyCFunction)arr_unravel_index,
4186
+ METH_VARARGS | METH_KEYWORDS, NULL},
4187
+ {"add_docstring", (PyCFunction)arr_add_docstring,
4188
+ METH_VARARGS, NULL},
4189
+ {"packbits", (PyCFunction)io_pack,
4190
+ METH_VARARGS | METH_KEYWORDS, NULL},
4191
+ {"unpackbits", (PyCFunction)io_unpack,
4192
+ METH_VARARGS | METH_KEYWORDS, NULL},
4193
+ {NULL, NULL, 0, NULL} /* sentinel */
4194
+ };
4195
+
4196
+ #include "__multiarray_api.c"
4197
+
4198
+ /* Establish scalar-type hierarchy
4199
+ *
4200
+ * For dual inheritance we need to make sure that the objects being
4201
+ * inherited from have the tp->mro object initialized. This is
4202
+ * not necessarily true for the basic type objects of Python (it is
4203
+ * checked for single inheritance but not dual in PyType_Ready).
4204
+ *
4205
+ * Thus, we call PyType_Ready on the standard Python Types, here.
4206
+ */
4207
+ static int
4208
+ setup_scalartypes(PyObject *NPY_UNUSED(dict))
4209
+ {
4210
+ initialize_casting_tables();
4211
+ initialize_numeric_types();
4212
+
4213
+ if (PyType_Ready(&PyBool_Type) < 0) {
4214
+ return -1;
4215
+ }
4216
+ #if !defined(NPY_PY3K)
4217
+ if (PyType_Ready(&PyInt_Type) < 0) {
4218
+ return -1;
4219
+ }
4220
+ #endif
4221
+ if (PyType_Ready(&PyFloat_Type) < 0) {
4222
+ return -1;
4223
+ }
4224
+ if (PyType_Ready(&PyComplex_Type) < 0) {
4225
+ return -1;
4226
+ }
4227
+ if (PyType_Ready(&PyString_Type) < 0) {
4228
+ return -1;
4229
+ }
4230
+ if (PyType_Ready(&PyUnicode_Type) < 0) {
4231
+ return -1;
4232
+ }
4233
+
4234
+ #define SINGLE_INHERIT(child, parent) \
4235
+ Py##child##ArrType_Type.tp_base = &Py##parent##ArrType_Type; \
4236
+ if (PyType_Ready(&Py##child##ArrType_Type) < 0) { \
4237
+ PyErr_Print(); \
4238
+ PyErr_Format(PyExc_SystemError, \
4239
+ "could not initialize Py%sArrType_Type", \
4240
+ #child); \
4241
+ return -1; \
4242
+ }
4243
+
4244
+ if (PyType_Ready(&PyGenericArrType_Type) < 0) {
4245
+ return -1;
4246
+ }
4247
+ SINGLE_INHERIT(Number, Generic);
4248
+ SINGLE_INHERIT(Integer, Number);
4249
+ SINGLE_INHERIT(Inexact, Number);
4250
+ SINGLE_INHERIT(SignedInteger, Integer);
4251
+ SINGLE_INHERIT(UnsignedInteger, Integer);
4252
+ SINGLE_INHERIT(Floating, Inexact);
4253
+ SINGLE_INHERIT(ComplexFloating, Inexact);
4254
+ SINGLE_INHERIT(Flexible, Generic);
4255
+ SINGLE_INHERIT(Character, Flexible);
4256
+
4257
+ #define DUAL_INHERIT(child, parent1, parent2) \
4258
+ Py##child##ArrType_Type.tp_base = &Py##parent2##ArrType_Type; \
4259
+ Py##child##ArrType_Type.tp_bases = \
4260
+ Py_BuildValue("(OO)", &Py##parent2##ArrType_Type, \
4261
+ &Py##parent1##_Type); \
4262
+ if (PyType_Ready(&Py##child##ArrType_Type) < 0) { \
4263
+ PyErr_Print(); \
4264
+ PyErr_Format(PyExc_SystemError, \
4265
+ "could not initialize Py%sArrType_Type", \
4266
+ #child); \
4267
+ return -1; \
4268
+ } \
4269
+ Py##child##ArrType_Type.tp_hash = Py##parent1##_Type.tp_hash;
4270
+
4271
+ /*
4272
+ * In Py3K, int is no longer a fixed-width integer type, so don't
4273
+ * inherit numpy.int_ from it.
4274
+ */
4275
+ #if defined(NPY_PY3K)
4276
+ #define INHERIT_INT(child, parent2) \
4277
+ SINGLE_INHERIT(child, parent2);
4278
+ #else
4279
+ #define INHERIT_INT(child, parent2) \
4280
+ Py##child##ArrType_Type.tp_flags |= Py_TPFLAGS_INT_SUBCLASS; \
4281
+ DUAL_INHERIT(child, Int, parent2);
4282
+ #endif
4283
+
4284
+ #if defined(NPY_PY3K)
4285
+ #define DUAL_INHERIT_COMPARE(child, parent1, parent2)
4286
+ #else
4287
+ #define DUAL_INHERIT_COMPARE(child, parent1, parent2) \
4288
+ Py##child##ArrType_Type.tp_compare = \
4289
+ Py##parent1##_Type.tp_compare;
4290
+ #endif
4291
+
4292
+ #define DUAL_INHERIT2(child, parent1, parent2) \
4293
+ Py##child##ArrType_Type.tp_base = &Py##parent1##_Type; \
4294
+ Py##child##ArrType_Type.tp_bases = \
4295
+ Py_BuildValue("(OO)", &Py##parent1##_Type, \
4296
+ &Py##parent2##ArrType_Type); \
4297
+ Py##child##ArrType_Type.tp_richcompare = \
4298
+ Py##parent1##_Type.tp_richcompare; \
4299
+ DUAL_INHERIT_COMPARE(child, parent1, parent2) \
4300
+ Py##child##ArrType_Type.tp_hash = Py##parent1##_Type.tp_hash; \
4301
+ if (PyType_Ready(&Py##child##ArrType_Type) < 0) { \
4302
+ PyErr_Print(); \
4303
+ PyErr_Format(PyExc_SystemError, \
4304
+ "could not initialize Py%sArrType_Type", \
4305
+ #child); \
4306
+ return -1; \
4307
+ }
4308
+
4309
+ SINGLE_INHERIT(Bool, Generic);
4310
+ SINGLE_INHERIT(Byte, SignedInteger);
4311
+ SINGLE_INHERIT(Short, SignedInteger);
4312
+
4313
+ #if NPY_SIZEOF_INT == NPY_SIZEOF_LONG
4314
+ INHERIT_INT(Int, SignedInteger);
4315
+ #else
4316
+ SINGLE_INHERIT(Int, SignedInteger);
4317
+ #endif
4318
+
4319
+ INHERIT_INT(Long, SignedInteger);
4320
+
4321
+ #if NPY_SIZEOF_LONGLONG == NPY_SIZEOF_LONG
4322
+ INHERIT_INT(LongLong, SignedInteger);
4323
+ #else
4324
+ SINGLE_INHERIT(LongLong, SignedInteger);
4325
+ #endif
4326
+
4327
+ /* Datetime doesn't fit in any category */
4328
+ SINGLE_INHERIT(Datetime, Generic);
4329
+ /* Timedelta is an integer with an associated unit */
4330
+ SINGLE_INHERIT(Timedelta, SignedInteger);
4331
+
4332
+ /*
4333
+ fprintf(stderr,
4334
+ "tp_free = %p, PyObject_Del = %p, int_tp_free = %p, base.tp_free = %p\n",
4335
+ PyIntArrType_Type.tp_free, PyObject_Del, PyInt_Type.tp_free,
4336
+ PySignedIntegerArrType_Type.tp_free);
4337
+ */
4338
+ SINGLE_INHERIT(UByte, UnsignedInteger);
4339
+ SINGLE_INHERIT(UShort, UnsignedInteger);
4340
+ SINGLE_INHERIT(UInt, UnsignedInteger);
4341
+ SINGLE_INHERIT(ULong, UnsignedInteger);
4342
+ SINGLE_INHERIT(ULongLong, UnsignedInteger);
4343
+
4344
+ SINGLE_INHERIT(Half, Floating);
4345
+ SINGLE_INHERIT(Float, Floating);
4346
+ DUAL_INHERIT(Double, Float, Floating);
4347
+ SINGLE_INHERIT(LongDouble, Floating);
4348
+
4349
+ SINGLE_INHERIT(CFloat, ComplexFloating);
4350
+ DUAL_INHERIT(CDouble, Complex, ComplexFloating);
4351
+ SINGLE_INHERIT(CLongDouble, ComplexFloating);
4352
+
4353
+ DUAL_INHERIT2(String, String, Character);
4354
+ DUAL_INHERIT2(Unicode, Unicode, Character);
4355
+
4356
+ SINGLE_INHERIT(Void, Flexible);
4357
+
4358
+ SINGLE_INHERIT(Object, Generic);
4359
+
4360
+ return 0;
4361
+
4362
+ #undef SINGLE_INHERIT
4363
+ #undef DUAL_INHERIT
4364
+ #undef INHERIT_INT
4365
+ #undef DUAL_INHERIT2
4366
+ #undef DUAL_INHERIT_COMPARE
4367
+
4368
+ /*
4369
+ * Clean up string and unicode array types so they act more like
4370
+ * strings -- get their tables from the standard types.
4371
+ */
4372
+ }
4373
+
4374
+ /* place a flag dictionary in d */
4375
+
4376
+ static void
4377
+ set_flaginfo(PyObject *d)
4378
+ {
4379
+ PyObject *s;
4380
+ PyObject *newd;
4381
+
4382
+ newd = PyDict_New();
4383
+
4384
+ #define _addnew(key, val, one) \
4385
+ PyDict_SetItemString(newd, #key, s=PyInt_FromLong(val)); \
4386
+ Py_DECREF(s); \
4387
+ PyDict_SetItemString(newd, #one, s=PyInt_FromLong(val)); \
4388
+ Py_DECREF(s)
4389
+
4390
+ #define _addone(key, val) \
4391
+ PyDict_SetItemString(newd, #key, s=PyInt_FromLong(val)); \
4392
+ Py_DECREF(s)
4393
+
4394
+ _addnew(OWNDATA, NPY_ARRAY_OWNDATA, O);
4395
+ _addnew(FORTRAN, NPY_ARRAY_F_CONTIGUOUS, F);
4396
+ _addnew(CONTIGUOUS, NPY_ARRAY_C_CONTIGUOUS, C);
4397
+ _addnew(ALIGNED, NPY_ARRAY_ALIGNED, A);
4398
+ _addnew(UPDATEIFCOPY, NPY_ARRAY_UPDATEIFCOPY, U);
4399
+ _addnew(WRITEABLE, NPY_ARRAY_WRITEABLE, W);
4400
+ _addone(C_CONTIGUOUS, NPY_ARRAY_C_CONTIGUOUS);
4401
+ _addone(F_CONTIGUOUS, NPY_ARRAY_F_CONTIGUOUS);
4402
+
4403
+ #undef _addone
4404
+ #undef _addnew
4405
+
4406
+ PyDict_SetItemString(d, "_flagdict", newd);
4407
+ Py_DECREF(newd);
4408
+ return;
4409
+ }
4410
+
4411
+ NPY_VISIBILITY_HIDDEN PyObject * npy_ma_str_array = NULL;
4412
+ NPY_VISIBILITY_HIDDEN PyObject * npy_ma_str_array_prepare = NULL;
4413
+ NPY_VISIBILITY_HIDDEN PyObject * npy_ma_str_array_wrap = NULL;
4414
+ NPY_VISIBILITY_HIDDEN PyObject * npy_ma_str_array_finalize = NULL;
4415
+ NPY_VISIBILITY_HIDDEN PyObject * npy_ma_str_buffer = NULL;
4416
+ NPY_VISIBILITY_HIDDEN PyObject * npy_ma_str_ufunc = NULL;
4417
+ NPY_VISIBILITY_HIDDEN PyObject * npy_ma_str_order = NULL;
4418
+ NPY_VISIBILITY_HIDDEN PyObject * npy_ma_str_copy = NULL;
4419
+ NPY_VISIBILITY_HIDDEN PyObject * npy_ma_str_dtype = NULL;
4420
+ NPY_VISIBILITY_HIDDEN PyObject * npy_ma_str_ndmin = NULL;
4421
+
4422
+ static int
4423
+ intern_strings(void)
4424
+ {
4425
+ npy_ma_str_array = PyUString_InternFromString("__array__");
4426
+ npy_ma_str_array_prepare = PyUString_InternFromString("__array_prepare__");
4427
+ npy_ma_str_array_wrap = PyUString_InternFromString("__array_wrap__");
4428
+ npy_ma_str_array_finalize = PyUString_InternFromString("__array_finalize__");
4429
+ npy_ma_str_buffer = PyUString_InternFromString("__buffer__");
4430
+ npy_ma_str_ufunc = PyUString_InternFromString("__numpy_ufunc__");
4431
+ npy_ma_str_order = PyUString_InternFromString("order");
4432
+ npy_ma_str_copy = PyUString_InternFromString("copy");
4433
+ npy_ma_str_dtype = PyUString_InternFromString("dtype");
4434
+ npy_ma_str_ndmin = PyUString_InternFromString("ndmin");
4435
+
4436
+ return npy_ma_str_array && npy_ma_str_array_prepare &&
4437
+ npy_ma_str_array_wrap && npy_ma_str_array_finalize &&
4438
+ npy_ma_str_array_finalize && npy_ma_str_ufunc &&
4439
+ npy_ma_str_order && npy_ma_str_copy && npy_ma_str_dtype &&
4440
+ npy_ma_str_ndmin;
4441
+ }
4442
+
4443
+
4444
+ #if defined(NPY_PY3K)
4445
+ static struct PyModuleDef moduledef = {
4446
+ PyModuleDef_HEAD_INIT,
4447
+ "multiarray",
4448
+ NULL,
4449
+ -1,
4450
+ array_module_methods,
4451
+ NULL,
4452
+ NULL,
4453
+ NULL,
4454
+ NULL
4455
+ };
4456
+ #endif
4457
+
4458
+ /* Initialization function for the module */
4459
+ #if defined(NPY_PY3K)
4460
+ #define RETVAL m
4461
+ PyMODINIT_FUNC PyInit_multiarray(void) {
4462
+ #else
4463
+ #define RETVAL
4464
+ PyMODINIT_FUNC initmultiarray(void) {
4465
+ #endif
4466
+ PyObject *m, *d, *s;
4467
+ PyObject *c_api;
4468
+
4469
+ /* Create the module and add the functions */
4470
+ #if defined(NPY_PY3K)
4471
+ m = PyModule_Create(&moduledef);
4472
+ #else
4473
+ m = Py_InitModule("multiarray", array_module_methods);
4474
+ #endif
4475
+ if (!m) {
4476
+ goto err;
4477
+ }
4478
+
4479
+ /* Initialize access to the PyDateTime API */
4480
+ numpy_pydatetime_import();
4481
+
4482
+ /* Add some symbolic constants to the module */
4483
+ d = PyModule_GetDict(m);
4484
+ if (!d) {
4485
+ goto err;
4486
+ }
4487
+
4488
+ /*
4489
+ * Before calling PyType_Ready, initialize the tp_hash slot in
4490
+ * PyArray_Type to work around mingw32 not being able initialize
4491
+ * static structure slots with functions from the Python C_API.
4492
+ */
4493
+ PyArray_Type.tp_hash = PyObject_HashNotImplemented;
4494
+ if (PyType_Ready(&PyArray_Type) < 0) {
4495
+ return RETVAL;
4496
+ }
4497
+ if (setup_scalartypes(d) < 0) {
4498
+ goto err;
4499
+ }
4500
+ PyArrayIter_Type.tp_iter = PyObject_SelfIter;
4501
+ NpyIter_Type.tp_iter = PyObject_SelfIter;
4502
+ PyArrayMultiIter_Type.tp_iter = PyObject_SelfIter;
4503
+ PyArrayMultiIter_Type.tp_free = PyArray_free;
4504
+ if (PyType_Ready(&PyArrayIter_Type) < 0) {
4505
+ return RETVAL;
4506
+ }
4507
+ if (PyType_Ready(&PyArrayMapIter_Type) < 0) {
4508
+ return RETVAL;
4509
+ }
4510
+ if (PyType_Ready(&PyArrayMultiIter_Type) < 0) {
4511
+ return RETVAL;
4512
+ }
4513
+ PyArrayNeighborhoodIter_Type.tp_new = PyType_GenericNew;
4514
+ if (PyType_Ready(&PyArrayNeighborhoodIter_Type) < 0) {
4515
+ return RETVAL;
4516
+ }
4517
+ if (PyType_Ready(&NpyIter_Type) < 0) {
4518
+ return RETVAL;
4519
+ }
4520
+
4521
+ PyArrayDescr_Type.tp_hash = PyArray_DescrHash;
4522
+ if (PyType_Ready(&PyArrayDescr_Type) < 0) {
4523
+ return RETVAL;
4524
+ }
4525
+ if (PyType_Ready(&PyArrayFlags_Type) < 0) {
4526
+ return RETVAL;
4527
+ }
4528
+ NpyBusDayCalendar_Type.tp_new = PyType_GenericNew;
4529
+ if (PyType_Ready(&NpyBusDayCalendar_Type) < 0) {
4530
+ return RETVAL;
4531
+ }
4532
+ /* FIXME
4533
+ * There is no error handling here
4534
+ */
4535
+ c_api = NpyCapsule_FromVoidPtr((void *)PyArray_API, NULL);
4536
+ PyDict_SetItemString(d, "_ARRAY_API", c_api);
4537
+ Py_DECREF(c_api);
4538
+ if (PyErr_Occurred()) {
4539
+ goto err;
4540
+ }
4541
+
4542
+ /* Initialize types in numpymemoryview.c */
4543
+ if (_numpymemoryview_init(&s) < 0) {
4544
+ return RETVAL;
4545
+ }
4546
+ if (s != NULL) {
4547
+ PyDict_SetItemString(d, "memorysimpleview", s);
4548
+ }
4549
+
4550
+ /*
4551
+ * PyExc_Exception should catch all the standard errors that are
4552
+ * now raised instead of the string exception "multiarray.error"
4553
+
4554
+ * This is for backward compatibility with existing code.
4555
+ */
4556
+ PyDict_SetItemString (d, "error", PyExc_Exception);
4557
+
4558
+ s = PyUString_FromString("3.1");
4559
+ PyDict_SetItemString(d, "__version__", s);
4560
+ Py_DECREF(s);
4561
+
4562
+ /* FIXME
4563
+ * There is no error handling here
4564
+ */
4565
+ s = NpyCapsule_FromVoidPtr((void *)_datetime_strings, NULL);
4566
+ PyDict_SetItemString(d, "DATETIMEUNITS", s);
4567
+ Py_DECREF(s);
4568
+
4569
+ #define ADDCONST(NAME) \
4570
+ s = PyInt_FromLong(NPY_##NAME); \
4571
+ PyDict_SetItemString(d, #NAME, s); \
4572
+ Py_DECREF(s)
4573
+
4574
+
4575
+ ADDCONST(ALLOW_THREADS);
4576
+ ADDCONST(BUFSIZE);
4577
+ ADDCONST(CLIP);
4578
+
4579
+ ADDCONST(ITEM_HASOBJECT);
4580
+ ADDCONST(LIST_PICKLE);
4581
+ ADDCONST(ITEM_IS_POINTER);
4582
+ ADDCONST(NEEDS_INIT);
4583
+ ADDCONST(NEEDS_PYAPI);
4584
+ ADDCONST(USE_GETITEM);
4585
+ ADDCONST(USE_SETITEM);
4586
+
4587
+ ADDCONST(RAISE);
4588
+ ADDCONST(WRAP);
4589
+ ADDCONST(MAXDIMS);
4590
+ #undef ADDCONST
4591
+
4592
+ Py_INCREF(&PyArray_Type);
4593
+ PyDict_SetItemString(d, "ndarray", (PyObject *)&PyArray_Type);
4594
+ Py_INCREF(&PyArrayIter_Type);
4595
+ PyDict_SetItemString(d, "flatiter", (PyObject *)&PyArrayIter_Type);
4596
+ Py_INCREF(&PyArrayMultiIter_Type);
4597
+ PyDict_SetItemString(d, "nditer", (PyObject *)&NpyIter_Type);
4598
+ Py_INCREF(&NpyIter_Type);
4599
+ PyDict_SetItemString(d, "broadcast",
4600
+ (PyObject *)&PyArrayMultiIter_Type);
4601
+ Py_INCREF(&PyArrayDescr_Type);
4602
+ PyDict_SetItemString(d, "dtype", (PyObject *)&PyArrayDescr_Type);
4603
+
4604
+ Py_INCREF(&PyArrayFlags_Type);
4605
+ PyDict_SetItemString(d, "flagsobj", (PyObject *)&PyArrayFlags_Type);
4606
+
4607
+ /* Business day calendar object */
4608
+ Py_INCREF(&NpyBusDayCalendar_Type);
4609
+ PyDict_SetItemString(d, "busdaycalendar",
4610
+ (PyObject *)&NpyBusDayCalendar_Type);
4611
+ set_flaginfo(d);
4612
+
4613
+ if (!intern_strings()) {
4614
+ goto err;
4615
+ }
4616
+
4617
+ if (set_typeinfo(d) != 0) {
4618
+ goto err;
4619
+ }
4620
+ return RETVAL;
4621
+
4622
+ err:
4623
+ if (!PyErr_Occurred()) {
4624
+ PyErr_SetString(PyExc_RuntimeError,
4625
+ "cannot load multiarray module.");
4626
+ }
4627
+ return RETVAL;
4628
+ }