numpy 1.9.3__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 (1590) 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/source/conf.py +331 -0
  12. numpy-1.10.0.post2/doc/source/dev/development_environment.rst +211 -0
  13. numpy-1.10.0.post2/doc/source/dev/gitwash/development_workflow.rst +534 -0
  14. numpy-1.10.0.post2/doc/source/dev/gitwash/git_links.inc +95 -0
  15. numpy-1.10.0.post2/doc/source/dev/gitwash/index.rst +14 -0
  16. numpy-1.10.0.post2/doc/source/dev/index.rst +11 -0
  17. numpy-1.10.0.post2/doc/source/reference/arrays.classes.rst +490 -0
  18. numpy-1.10.0.post2/doc/source/reference/arrays.dtypes.rst +536 -0
  19. numpy-1.10.0.post2/doc/source/reference/arrays.indexing.rst +549 -0
  20. numpy-1.10.0.post2/doc/source/reference/arrays.interface.rst +337 -0
  21. numpy-1.10.0.post2/doc/source/reference/arrays.ndarray.rst +622 -0
  22. numpy-1.10.0.post2/doc/source/reference/arrays.scalars.rst +291 -0
  23. numpy-1.10.0.post2/doc/source/reference/c-api.array.rst +3393 -0
  24. numpy-1.10.0.post2/doc/source/reference/c-api.config.rst +103 -0
  25. numpy-1.10.0.post2/doc/source/reference/c-api.coremath.rst +420 -0
  26. numpy-1.10.0.post2/doc/source/reference/c-api.dtype.rst +376 -0
  27. numpy-1.10.0.post2/doc/source/reference/c-api.generalized-ufuncs.rst +191 -0
  28. numpy-1.10.0.post2/doc/source/reference/c-api.iterator.rst +1300 -0
  29. numpy-1.10.0.post2/doc/source/reference/c-api.types-and-structures.rst +1240 -0
  30. numpy-1.10.0.post2/doc/source/reference/c-api.ufunc.rst +413 -0
  31. numpy-1.10.0.post2/doc/source/reference/index.rst +43 -0
  32. numpy-1.10.0.post2/doc/source/reference/internals.code-explanations.rst +615 -0
  33. numpy-1.10.0.post2/doc/source/reference/routines.array-manipulation.rst +115 -0
  34. numpy-1.10.0.post2/doc/source/reference/routines.io.rst +78 -0
  35. numpy-1.10.0.post2/doc/source/reference/routines.linalg.rst +91 -0
  36. numpy-1.10.0.post2/doc/source/reference/routines.ma.rst +407 -0
  37. numpy-1.10.0.post2/doc/source/reference/routines.sort.rst +41 -0
  38. numpy-1.10.0.post2/doc/source/reference/routines.statistics.rst +57 -0
  39. numpy-1.10.0.post2/doc/source/reference/swig.interface-file.rst +1066 -0
  40. numpy-1.10.0.post2/doc/source/reference/swig.testing.rst +167 -0
  41. numpy-1.10.0.post2/doc/source/reference/ufuncs.rst +666 -0
  42. numpy-1.10.0.post2/doc/source/release.rst +20 -0
  43. numpy-1.10.0.post2/doc/source/user/basics.io.genfromtxt.rst +531 -0
  44. numpy-1.10.0.post2/doc/source/user/basics.rec.rst +7 -0
  45. numpy-1.10.0.post2/doc/source/user/c-info.beyond-basics.rst +560 -0
  46. numpy-1.10.0.post2/doc/source/user/c-info.how-to-extend.rst +642 -0
  47. numpy-1.10.0.post2/doc/source/user/c-info.python-as-glue.rst +1177 -0
  48. numpy-1.10.0.post2/doc/source/user/c-info.ufunc-tutorial.rst +1211 -0
  49. numpy-1.10.0.post2/doc/source/user/install.rst +194 -0
  50. numpy-1.10.0.post2/numpy/__init__.py +227 -0
  51. numpy-1.10.0.post2/numpy/_build_utils/README +8 -0
  52. numpy-1.10.0.post2/numpy/_build_utils/apple_accelerate.py +21 -0
  53. numpy-1.10.0.post2/numpy/_build_utils/common.py +138 -0
  54. numpy-1.10.0.post2/numpy/_build_utils/src/apple_sgemv_fix.c +227 -0
  55. numpy-1.10.0.post2/numpy/_build_utils/waf.py +531 -0
  56. numpy-1.10.0.post2/numpy/_import_tools.py +353 -0
  57. numpy-1.10.0.post2/numpy/add_newdocs.py +7611 -0
  58. numpy-1.10.0.post2/numpy/compat/_inspect.py +194 -0
  59. numpy-1.10.0.post2/numpy/compat/py3k.py +88 -0
  60. numpy-1.10.0.post2/numpy/compat/setup.py +12 -0
  61. numpy-1.10.0.post2/numpy/core/__init__.py +89 -0
  62. numpy-1.10.0.post2/numpy/core/_internal.py +761 -0
  63. numpy-1.10.0.post2/numpy/core/_methods.py +133 -0
  64. numpy-1.10.0.post2/numpy/core/arrayprint.py +760 -0
  65. numpy-1.10.0.post2/numpy/core/code_generators/cversions.txt +34 -0
  66. numpy-1.10.0.post2/numpy/core/code_generators/generate_ufunc_api.py +219 -0
  67. numpy-1.10.0.post2/numpy/core/code_generators/generate_umath.py +1017 -0
  68. numpy-1.10.0.post2/numpy/core/code_generators/numpy_api.py +415 -0
  69. numpy-1.10.0.post2/numpy/core/code_generators/ufunc_docstrings.py +3442 -0
  70. numpy-1.10.0.post2/numpy/core/defchararray.py +2689 -0
  71. numpy-1.10.0.post2/numpy/core/fromnumeric.py +3089 -0
  72. numpy-1.10.0.post2/numpy/core/function_base.py +203 -0
  73. numpy-1.10.0.post2/numpy/core/getlimits.py +308 -0
  74. numpy-1.10.0.post2/numpy/core/include/numpy/ndarrayobject.h +246 -0
  75. numpy-1.10.0.post2/numpy/core/include/numpy/ndarraytypes.h +1797 -0
  76. numpy-1.10.0.post2/numpy/core/include/numpy/npy_3kcompat.h +448 -0
  77. numpy-1.10.0.post2/numpy/core/include/numpy/npy_common.h +1051 -0
  78. numpy-1.10.0.post2/numpy/core/include/numpy/npy_cpu.h +92 -0
  79. numpy-1.10.0.post2/numpy/core/include/numpy/npy_endian.h +61 -0
  80. numpy-1.10.0.post2/numpy/core/include/numpy/npy_math.h +525 -0
  81. numpy-1.10.0.post2/numpy/core/include/numpy/numpyconfig.h +36 -0
  82. numpy-1.10.0.post2/numpy/core/machar.py +342 -0
  83. numpy-1.10.0.post2/numpy/core/memmap.py +311 -0
  84. numpy-1.10.0.post2/numpy/core/numeric.py +2893 -0
  85. numpy-1.10.0.post2/numpy/core/numerictypes.py +1036 -0
  86. numpy-1.10.0.post2/numpy/core/records.py +846 -0
  87. numpy-1.10.0.post2/numpy/core/setup.py +983 -0
  88. numpy-1.10.0.post2/numpy/core/setup_common.py +352 -0
  89. numpy-1.10.0.post2/numpy/core/shape_base.py +350 -0
  90. numpy-1.10.0.post2/numpy/core/src/multiarray/alloc.c +244 -0
  91. numpy-1.10.0.post2/numpy/core/src/multiarray/arrayobject.c +1858 -0
  92. numpy-1.10.0.post2/numpy/core/src/multiarray/arraytypes.c.src +4738 -0
  93. numpy-1.10.0.post2/numpy/core/src/multiarray/arraytypes.h +37 -0
  94. numpy-1.10.0.post2/numpy/core/src/multiarray/buffer.c +981 -0
  95. numpy-1.10.0.post2/numpy/core/src/multiarray/calculation.c +1224 -0
  96. numpy-1.10.0.post2/numpy/core/src/multiarray/cblasfuncs.c +812 -0
  97. numpy-1.10.0.post2/numpy/core/src/multiarray/cblasfuncs.h +10 -0
  98. numpy-1.10.0.post2/numpy/core/src/multiarray/common.c +911 -0
  99. numpy-1.10.0.post2/numpy/core/src/multiarray/common.h +250 -0
  100. numpy-1.10.0.post2/numpy/core/src/multiarray/compiled_base.c +1664 -0
  101. numpy-1.10.0.post2/numpy/core/src/multiarray/compiled_base.h +24 -0
  102. numpy-1.10.0.post2/numpy/core/src/multiarray/conversion_utils.c +1217 -0
  103. numpy-1.10.0.post2/numpy/core/src/multiarray/convert.c +590 -0
  104. numpy-1.10.0.post2/numpy/core/src/multiarray/convert_datatype.c +2155 -0
  105. numpy-1.10.0.post2/numpy/core/src/multiarray/ctors.c +3838 -0
  106. numpy-1.10.0.post2/numpy/core/src/multiarray/datetime.c +3821 -0
  107. numpy-1.10.0.post2/numpy/core/src/multiarray/datetime_busday.c +1322 -0
  108. numpy-1.10.0.post2/numpy/core/src/multiarray/datetime_busdaycal.c +552 -0
  109. numpy-1.10.0.post2/numpy/core/src/multiarray/datetime_strings.c +1772 -0
  110. numpy-1.10.0.post2/numpy/core/src/multiarray/descriptor.c +3719 -0
  111. numpy-1.10.0.post2/numpy/core/src/multiarray/dtype_transfer.c +4239 -0
  112. numpy-1.10.0.post2/numpy/core/src/multiarray/einsum.c.src +3005 -0
  113. numpy-1.10.0.post2/numpy/core/src/multiarray/getset.c +986 -0
  114. numpy-1.10.0.post2/numpy/core/src/multiarray/hashdescr.c +318 -0
  115. numpy-1.10.0.post2/numpy/core/src/multiarray/item_selection.c +2413 -0
  116. numpy-1.10.0.post2/numpy/core/src/multiarray/iterators.c +2192 -0
  117. numpy-1.10.0.post2/numpy/core/src/multiarray/lowlevel_strided_loops.c.src +1769 -0
  118. numpy-1.10.0.post2/numpy/core/src/multiarray/mapping.c +3380 -0
  119. numpy-1.10.0.post2/numpy/core/src/multiarray/mapping.h +77 -0
  120. numpy-1.10.0.post2/numpy/core/src/multiarray/methods.c +2514 -0
  121. numpy-1.10.0.post2/numpy/core/src/multiarray/multiarray_tests.c.src +1035 -0
  122. numpy-1.10.0.post2/numpy/core/src/multiarray/multiarraymodule.c +4628 -0
  123. numpy-1.10.0.post2/numpy/core/src/multiarray/multiarraymodule.h +15 -0
  124. numpy-1.10.0.post2/numpy/core/src/multiarray/nditer_api.c +2809 -0
  125. numpy-1.10.0.post2/numpy/core/src/multiarray/nditer_constr.c +3160 -0
  126. numpy-1.10.0.post2/numpy/core/src/multiarray/nditer_pywrap.c +2499 -0
  127. numpy-1.10.0.post2/numpy/core/src/multiarray/number.c +1106 -0
  128. numpy-1.10.0.post2/numpy/core/src/multiarray/number.h +77 -0
  129. numpy-1.10.0.post2/numpy/core/src/multiarray/numpymemoryview.c +308 -0
  130. numpy-1.10.0.post2/numpy/core/src/multiarray/numpyos.c +683 -0
  131. numpy-1.10.0.post2/numpy/core/src/multiarray/scalarapi.c +870 -0
  132. numpy-1.10.0.post2/numpy/core/src/multiarray/scalartypes.c.src +4343 -0
  133. numpy-1.10.0.post2/numpy/core/src/multiarray/scalartypes.h +55 -0
  134. numpy-1.10.0.post2/numpy/core/src/multiarray/shape.c +1131 -0
  135. numpy-1.10.0.post2/numpy/core/src/multiarray/ucsnarrow.c +174 -0
  136. numpy-1.10.0.post2/numpy/core/src/multiarray/vdot.c +180 -0
  137. numpy-1.10.0.post2/numpy/core/src/multiarray/vdot.h +18 -0
  138. numpy-1.10.0.post2/numpy/core/src/npymath/ieee754.c.src +808 -0
  139. numpy-1.10.0.post2/numpy/core/src/npymath/npy_math.c.src +597 -0
  140. numpy-1.10.0.post2/numpy/core/src/npymath/npy_math_complex.c.src +1788 -0
  141. numpy-1.10.0.post2/numpy/core/src/npymath/npy_math_private.h +544 -0
  142. numpy-1.10.0.post2/numpy/core/src/npysort/heapsort.c.src +402 -0
  143. numpy-1.10.0.post2/numpy/core/src/npysort/mergesort.c.src +488 -0
  144. numpy-1.10.0.post2/numpy/core/src/npysort/npysort_common.h +360 -0
  145. numpy-1.10.0.post2/numpy/core/src/npysort/quicksort.c.src +523 -0
  146. numpy-1.10.0.post2/numpy/core/src/npysort/selection.c.src +426 -0
  147. numpy-1.10.0.post2/numpy/core/src/private/npy_cblas.h +584 -0
  148. numpy-1.10.0.post2/numpy/core/src/private/npy_config.h +101 -0
  149. numpy-1.10.0.post2/numpy/core/src/private/npy_import.h +32 -0
  150. numpy-1.10.0.post2/numpy/core/src/private/npy_partition.h.src +122 -0
  151. numpy-1.10.0.post2/numpy/core/src/private/npy_sort.h +196 -0
  152. numpy-1.10.0.post2/numpy/core/src/private/templ_common.h.src +43 -0
  153. numpy-1.10.0.post2/numpy/core/src/private/ufunc_override.h +397 -0
  154. numpy-1.10.0.post2/numpy/core/src/umath/funcs.inc.src +356 -0
  155. numpy-1.10.0.post2/numpy/core/src/umath/loops.c.src +2675 -0
  156. numpy-1.10.0.post2/numpy/core/src/umath/loops.h.src +497 -0
  157. numpy-1.10.0.post2/numpy/core/src/umath/operand_flag_tests.c.src +105 -0
  158. numpy-1.10.0.post2/numpy/core/src/umath/scalarmath.c.src +1738 -0
  159. numpy-1.10.0.post2/numpy/core/src/umath/simd.inc.src +903 -0
  160. numpy-1.10.0.post2/numpy/core/src/umath/test_rational.c.src +1404 -0
  161. numpy-1.10.0.post2/numpy/core/src/umath/ufunc_object.c +5703 -0
  162. numpy-1.10.0.post2/numpy/core/src/umath/ufunc_type_resolution.c +2159 -0
  163. numpy-1.10.0.post2/numpy/core/src/umath/umath_tests.c.src +392 -0
  164. numpy-1.10.0.post2/numpy/core/src/umath/umathmodule.c +443 -0
  165. numpy-1.10.0.post2/numpy/core/tests/test_abc.py +47 -0
  166. numpy-1.10.0.post2/numpy/core/tests/test_api.py +515 -0
  167. numpy-1.10.0.post2/numpy/core/tests/test_arrayprint.py +171 -0
  168. numpy-1.10.0.post2/numpy/core/tests/test_datetime.py +1820 -0
  169. numpy-1.10.0.post2/numpy/core/tests/test_defchararray.py +703 -0
  170. numpy-1.10.0.post2/numpy/core/tests/test_deprecations.py +619 -0
  171. numpy-1.10.0.post2/numpy/core/tests/test_dtype.py +578 -0
  172. numpy-1.10.0.post2/numpy/core/tests/test_einsum.py +627 -0
  173. numpy-1.10.0.post2/numpy/core/tests/test_errstate.py +52 -0
  174. numpy-1.10.0.post2/numpy/core/tests/test_function_base.py +142 -0
  175. numpy-1.10.0.post2/numpy/core/tests/test_getlimits.py +77 -0
  176. numpy-1.10.0.post2/numpy/core/tests/test_half.py +436 -0
  177. numpy-1.10.0.post2/numpy/core/tests/test_indexerrors.py +126 -0
  178. numpy-1.10.0.post2/numpy/core/tests/test_indexing.py +1047 -0
  179. numpy-1.10.0.post2/numpy/core/tests/test_item_selection.py +73 -0
  180. numpy-1.10.0.post2/numpy/core/tests/test_machar.py +29 -0
  181. numpy-1.10.0.post2/numpy/core/tests/test_memmap.py +130 -0
  182. numpy-1.10.0.post2/numpy/core/tests/test_multiarray.py +5924 -0
  183. numpy-1.10.0.post2/numpy/core/tests/test_multiarray_assignment.py +84 -0
  184. numpy-1.10.0.post2/numpy/core/tests/test_nditer.py +2638 -0
  185. numpy-1.10.0.post2/numpy/core/tests/test_numeric.py +2204 -0
  186. numpy-1.10.0.post2/numpy/core/tests/test_numerictypes.py +382 -0
  187. numpy-1.10.0.post2/numpy/core/tests/test_print.py +248 -0
  188. numpy-1.10.0.post2/numpy/core/tests/test_records.py +299 -0
  189. numpy-1.10.0.post2/numpy/core/tests/test_regression.py +2177 -0
  190. numpy-1.10.0.post2/numpy/core/tests/test_scalarinherit.py +41 -0
  191. numpy-1.10.0.post2/numpy/core/tests/test_scalarmath.py +316 -0
  192. numpy-1.10.0.post2/numpy/core/tests/test_shape_base.py +319 -0
  193. numpy-1.10.0.post2/numpy/core/tests/test_ufunc.py +1227 -0
  194. numpy-1.10.0.post2/numpy/core/tests/test_umath.py +1933 -0
  195. numpy-1.10.0.post2/numpy/core/tests/test_umath_complex.py +538 -0
  196. numpy-1.10.0.post2/numpy/core/tests/test_unicode.py +360 -0
  197. numpy-1.10.0.post2/numpy/distutils/__init__.py +23 -0
  198. numpy-1.10.0.post2/numpy/distutils/ccompiler.py +690 -0
  199. numpy-1.10.0.post2/numpy/distutils/command/autodist.py +94 -0
  200. numpy-1.10.0.post2/numpy/distutils/command/build.py +47 -0
  201. numpy-1.10.0.post2/numpy/distutils/command/build_clib.py +295 -0
  202. numpy-1.10.0.post2/numpy/distutils/command/build_ext.py +522 -0
  203. numpy-1.10.0.post2/numpy/distutils/command/config.py +437 -0
  204. numpy-1.10.0.post2/numpy/distutils/exec_command.py +651 -0
  205. numpy-1.10.0.post2/numpy/distutils/fcompiler/compaq.py +128 -0
  206. numpy-1.10.0.post2/numpy/distutils/fcompiler/gnu.py +403 -0
  207. numpy-1.10.0.post2/numpy/distutils/fcompiler/intel.py +217 -0
  208. numpy-1.10.0.post2/numpy/distutils/fcompiler/pg.py +63 -0
  209. numpy-1.10.0.post2/numpy/distutils/fcompiler/sun.py +55 -0
  210. numpy-1.10.0.post2/numpy/distutils/intelccompiler.py +95 -0
  211. numpy-1.10.0.post2/numpy/distutils/lib2def.py +116 -0
  212. numpy-1.10.0.post2/numpy/distutils/mingw32ccompiler.py +599 -0
  213. numpy-1.10.0.post2/numpy/distutils/misc_util.py +2306 -0
  214. numpy-1.10.0.post2/numpy/distutils/msvc9compiler.py +23 -0
  215. numpy-1.10.0.post2/numpy/distutils/msvccompiler.py +17 -0
  216. numpy-1.10.0.post2/numpy/distutils/npy_pkg_config.py +451 -0
  217. numpy-1.10.0.post2/numpy/distutils/system_info.py +2397 -0
  218. numpy-1.10.0.post2/numpy/distutils/tests/f2py_ext/tests/test_fib2.py +12 -0
  219. numpy-1.10.0.post2/numpy/distutils/tests/f2py_f90_ext/tests/test_foo.py +11 -0
  220. numpy-1.10.0.post2/numpy/distutils/tests/gen_ext/tests/test_fib3.py +11 -0
  221. numpy-1.10.0.post2/numpy/distutils/tests/pyrex_ext/tests/test_primes.py +13 -0
  222. numpy-1.10.0.post2/numpy/distutils/tests/swig_ext/__init__.py +1 -0
  223. numpy-1.10.0.post2/numpy/distutils/tests/swig_ext/tests/test_example.py +17 -0
  224. numpy-1.10.0.post2/numpy/distutils/tests/swig_ext/tests/test_example2.py +15 -0
  225. numpy-1.10.0.post2/numpy/distutils/tests/test_fcompiler_gnu.py +60 -0
  226. numpy-1.10.0.post2/numpy/distutils/tests/test_fcompiler_intel.py +36 -0
  227. numpy-1.10.0.post2/numpy/distutils/tests/test_misc_util.py +79 -0
  228. numpy-1.10.0.post2/numpy/distutils/tests/test_npy_pkg_config.py +102 -0
  229. numpy-1.10.0.post2/numpy/distutils/tests/test_system_info.py +209 -0
  230. numpy-1.10.0.post2/numpy/distutils/unixccompiler.py +125 -0
  231. numpy-1.10.0.post2/numpy/doc/byteswapping.py +156 -0
  232. numpy-1.10.0.post2/numpy/doc/creation.py +144 -0
  233. numpy-1.10.0.post2/numpy/doc/glossary.py +423 -0
  234. numpy-1.10.0.post2/numpy/doc/indexing.py +439 -0
  235. numpy-1.10.0.post2/numpy/doc/structured_arrays.py +290 -0
  236. numpy-1.10.0.post2/numpy/f2py/__init__.py +49 -0
  237. numpy-1.10.0.post2/numpy/f2py/__main__.py +25 -0
  238. numpy-1.10.0.post2/numpy/f2py/auxfuncs.py +858 -0
  239. numpy-1.10.0.post2/numpy/f2py/capi_maps.py +851 -0
  240. numpy-1.10.0.post2/numpy/f2py/cb_rules.py +554 -0
  241. numpy-1.10.0.post2/numpy/f2py/cfuncs.py +1261 -0
  242. numpy-1.10.0.post2/numpy/f2py/common_rules.py +150 -0
  243. numpy-1.10.0.post2/numpy/f2py/crackfortran.py +3314 -0
  244. numpy-1.10.0.post2/numpy/f2py/diagnose.py +156 -0
  245. numpy-1.10.0.post2/numpy/f2py/f2py2e.py +656 -0
  246. numpy-1.10.0.post2/numpy/f2py/f2py_testing.py +48 -0
  247. numpy-1.10.0.post2/numpy/f2py/f90mod_rules.py +272 -0
  248. numpy-1.10.0.post2/numpy/f2py/func2subr.py +299 -0
  249. numpy-1.10.0.post2/numpy/f2py/rules.py +1475 -0
  250. numpy-1.10.0.post2/numpy/f2py/setup.py +117 -0
  251. numpy-1.10.0.post2/numpy/f2py/src/fortranobject.c +1037 -0
  252. numpy-1.10.0.post2/numpy/f2py/src/fortranobject.h +162 -0
  253. numpy-1.10.0.post2/numpy/f2py/tests/src/array_from_pyobj/wrapmodule.c +223 -0
  254. numpy-1.10.0.post2/numpy/f2py/tests/test_array_from_pyobj.py +593 -0
  255. numpy-1.10.0.post2/numpy/f2py/tests/test_assumed_shape.py +35 -0
  256. numpy-1.10.0.post2/numpy/f2py/tests/test_callback.py +136 -0
  257. numpy-1.10.0.post2/numpy/f2py/tests/test_kind.py +36 -0
  258. numpy-1.10.0.post2/numpy/f2py/tests/test_mixed.py +40 -0
  259. numpy-1.10.0.post2/numpy/f2py/tests/test_regression.py +34 -0
  260. numpy-1.10.0.post2/numpy/f2py/tests/test_return_character.py +148 -0
  261. numpy-1.10.0.post2/numpy/f2py/tests/test_return_complex.py +170 -0
  262. numpy-1.10.0.post2/numpy/f2py/tests/test_return_integer.py +180 -0
  263. numpy-1.10.0.post2/numpy/f2py/tests/test_return_logical.py +189 -0
  264. numpy-1.10.0.post2/numpy/f2py/tests/test_return_real.py +206 -0
  265. numpy-1.10.0.post2/numpy/f2py/tests/test_size.py +44 -0
  266. numpy-1.10.0.post2/numpy/f2py/tests/util.py +367 -0
  267. numpy-1.10.0.post2/numpy/f2py/use_rules.py +115 -0
  268. numpy-1.10.0.post2/numpy/fft/fftpack.c +1501 -0
  269. numpy-1.10.0.post2/numpy/fft/fftpack.h +28 -0
  270. numpy-1.10.0.post2/numpy/fft/fftpack.py +1241 -0
  271. numpy-1.10.0.post2/numpy/fft/fftpack_litemodule.c +363 -0
  272. numpy-1.10.0.post2/numpy/fft/info.py +187 -0
  273. numpy-1.10.0.post2/numpy/fft/setup.py +19 -0
  274. numpy-1.10.0.post2/numpy/fft/tests/test_fftpack.py +166 -0
  275. numpy-1.10.0.post2/numpy/fft/tests/test_helper.py +78 -0
  276. numpy-1.10.0.post2/numpy/lib/_iotools.py +917 -0
  277. numpy-1.10.0.post2/numpy/lib/arraypad.py +1497 -0
  278. numpy-1.10.0.post2/numpy/lib/arraysetops.py +480 -0
  279. numpy-1.10.0.post2/numpy/lib/arrayterator.py +226 -0
  280. numpy-1.10.0.post2/numpy/lib/financial.py +737 -0
  281. numpy-1.10.0.post2/numpy/lib/format.py +814 -0
  282. numpy-1.10.0.post2/numpy/lib/function_base.py +4150 -0
  283. numpy-1.10.0.post2/numpy/lib/index_tricks.py +874 -0
  284. numpy-1.10.0.post2/numpy/lib/info.py +152 -0
  285. numpy-1.10.0.post2/numpy/lib/nanfunctions.py +1237 -0
  286. numpy-1.10.0.post2/numpy/lib/npyio.py +1992 -0
  287. numpy-1.10.0.post2/numpy/lib/polynomial.py +1277 -0
  288. numpy-1.10.0.post2/numpy/lib/recfunctions.py +1003 -0
  289. numpy-1.10.0.post2/numpy/lib/setup.py +12 -0
  290. numpy-1.10.0.post2/numpy/lib/shape_base.py +872 -0
  291. numpy-1.10.0.post2/numpy/lib/stride_tricks.py +200 -0
  292. numpy-1.10.0.post2/numpy/lib/tests/data/py2-objarr.npy +0 -0
  293. numpy-1.10.0.post2/numpy/lib/tests/data/py2-objarr.npz +0 -0
  294. numpy-1.10.0.post2/numpy/lib/tests/data/py3-objarr.npy +0 -0
  295. numpy-1.10.0.post2/numpy/lib/tests/data/py3-objarr.npz +0 -0
  296. numpy-1.10.0.post2/numpy/lib/tests/test__iotools.py +348 -0
  297. numpy-1.10.0.post2/numpy/lib/tests/test__version.py +70 -0
  298. numpy-1.10.0.post2/numpy/lib/tests/test_arraypad.py +1047 -0
  299. numpy-1.10.0.post2/numpy/lib/tests/test_arraysetops.py +309 -0
  300. numpy-1.10.0.post2/numpy/lib/tests/test_financial.py +163 -0
  301. numpy-1.10.0.post2/numpy/lib/tests/test_format.py +841 -0
  302. numpy-1.10.0.post2/numpy/lib/tests/test_function_base.py +2555 -0
  303. numpy-1.10.0.post2/numpy/lib/tests/test_index_tricks.py +326 -0
  304. numpy-1.10.0.post2/numpy/lib/tests/test_io.py +1916 -0
  305. numpy-1.10.0.post2/numpy/lib/tests/test_nanfunctions.py +707 -0
  306. numpy-1.10.0.post2/numpy/lib/tests/test_packbits.py +26 -0
  307. numpy-1.10.0.post2/numpy/lib/tests/test_polynomial.py +188 -0
  308. numpy-1.10.0.post2/numpy/lib/tests/test_recfunctions.py +734 -0
  309. numpy-1.10.0.post2/numpy/lib/tests/test_shape_base.py +386 -0
  310. numpy-1.10.0.post2/numpy/lib/tests/test_stride_tricks.py +405 -0
  311. numpy-1.10.0.post2/numpy/lib/tests/test_twodim_base.py +535 -0
  312. numpy-1.10.0.post2/numpy/lib/tests/test_type_check.py +332 -0
  313. numpy-1.10.0.post2/numpy/lib/twodim_base.py +1007 -0
  314. numpy-1.10.0.post2/numpy/lib/type_check.py +596 -0
  315. numpy-1.10.0.post2/numpy/lib/utils.py +1122 -0
  316. numpy-1.10.0.post2/numpy/linalg/lapack_lite/python_xerbla.c +46 -0
  317. numpy-1.10.0.post2/numpy/linalg/lapack_litemodule.c +358 -0
  318. numpy-1.10.0.post2/numpy/linalg/linalg.py +2406 -0
  319. numpy-1.10.0.post2/numpy/linalg/tests/test_build.py +59 -0
  320. numpy-1.10.0.post2/numpy/linalg/tests/test_linalg.py +1351 -0
  321. numpy-1.10.0.post2/numpy/linalg/tests/test_regression.py +95 -0
  322. numpy-1.10.0.post2/numpy/linalg/umath_linalg.c.src +3236 -0
  323. numpy-1.10.0.post2/numpy/ma/__init__.py +56 -0
  324. numpy-1.10.0.post2/numpy/ma/bench.py +131 -0
  325. numpy-1.10.0.post2/numpy/ma/core.py +7608 -0
  326. numpy-1.10.0.post2/numpy/ma/extras.py +1953 -0
  327. numpy-1.10.0.post2/numpy/ma/mrecords.py +796 -0
  328. numpy-1.10.0.post2/numpy/ma/setup.py +13 -0
  329. numpy-1.10.0.post2/numpy/ma/tests/test_core.py +4100 -0
  330. numpy-1.10.0.post2/numpy/ma/tests/test_extras.py +1132 -0
  331. numpy-1.10.0.post2/numpy/ma/tests/test_mrecords.py +520 -0
  332. numpy-1.10.0.post2/numpy/ma/tests/test_old_ma.py +879 -0
  333. numpy-1.10.0.post2/numpy/ma/tests/test_regression.py +80 -0
  334. numpy-1.10.0.post2/numpy/ma/tests/test_subclassing.py +338 -0
  335. numpy-1.10.0.post2/numpy/ma/testutils.py +289 -0
  336. numpy-1.10.0.post2/numpy/ma/timer_comparison.py +440 -0
  337. numpy-1.10.0.post2/numpy/matlib.py +358 -0
  338. numpy-1.10.0.post2/numpy/matrixlib/defmatrix.py +1232 -0
  339. numpy-1.10.0.post2/numpy/matrixlib/tests/test_defmatrix.py +449 -0
  340. numpy-1.10.0.post2/numpy/matrixlib/tests/test_multiarray.py +23 -0
  341. numpy-1.10.0.post2/numpy/matrixlib/tests/test_numeric.py +23 -0
  342. numpy-1.10.0.post2/numpy/matrixlib/tests/test_regression.py +37 -0
  343. numpy-1.10.0.post2/numpy/polynomial/_polybase.py +962 -0
  344. numpy-1.10.0.post2/numpy/polynomial/chebyshev.py +2056 -0
  345. numpy-1.10.0.post2/numpy/polynomial/hermite.py +1831 -0
  346. numpy-1.10.0.post2/numpy/polynomial/hermite_e.py +1828 -0
  347. numpy-1.10.0.post2/numpy/polynomial/laguerre.py +1780 -0
  348. numpy-1.10.0.post2/numpy/polynomial/legendre.py +1808 -0
  349. numpy-1.10.0.post2/numpy/polynomial/polyutils.py +403 -0
  350. numpy-1.10.0.post2/numpy/random/mtrand/distributions.c +912 -0
  351. numpy-1.10.0.post2/numpy/random/mtrand/mtrand.c +34805 -0
  352. numpy-1.10.0.post2/numpy/random/mtrand/mtrand.pyx +4766 -0
  353. numpy-1.10.0.post2/numpy/random/setup.py +61 -0
  354. numpy-1.10.0.post2/numpy/random/tests/test_random.py +723 -0
  355. numpy-1.10.0.post2/numpy/random/tests/test_regression.py +117 -0
  356. numpy-1.10.0.post2/numpy/setup.py +29 -0
  357. numpy-1.10.0.post2/numpy/testing/__init__.py +15 -0
  358. numpy-1.10.0.post2/numpy/testing/decorators.py +271 -0
  359. numpy-1.10.0.post2/numpy/testing/noseclasses.py +353 -0
  360. numpy-1.10.0.post2/numpy/testing/nosetester.py +511 -0
  361. numpy-1.10.0.post2/numpy/testing/print_coercion_tables.py +91 -0
  362. numpy-1.10.0.post2/numpy/testing/setup.py +20 -0
  363. numpy-1.10.0.post2/numpy/testing/tests/test_decorators.py +182 -0
  364. numpy-1.10.0.post2/numpy/testing/tests/test_utils.py +781 -0
  365. numpy-1.10.0.post2/numpy/testing/utils.py +1831 -0
  366. numpy-1.10.0.post2/numpy/tests/test_ctypeslib.py +106 -0
  367. numpy-1.10.0.post2/numpy/tests/test_matlib.py +55 -0
  368. numpy-1.10.0.post2/numpy/tests/test_scripts.py +69 -0
  369. numpy-1.10.0.post2/numpy/version.py +10 -0
  370. numpy-1.10.0.post2/setup.py +260 -0
  371. numpy-1.10.0.post2/site.cfg.example +193 -0
  372. numpy-1.10.0.post2/tmp.txt +789 -0
  373. numpy-1.10.0.post2/tools/swig/README +145 -0
  374. numpy-1.10.0.post2/tools/swig/numpy.i +3161 -0
  375. numpy-1.10.0.post2/tools/swig/test/Array.i +135 -0
  376. numpy-1.10.0.post2/tools/swig/test/ArrayZ.cxx +131 -0
  377. numpy-1.10.0.post2/tools/swig/test/ArrayZ.h +56 -0
  378. numpy-1.10.0.post2/tools/swig/test/Flat.cxx +36 -0
  379. numpy-1.10.0.post2/tools/swig/test/Flat.h +34 -0
  380. numpy-1.10.0.post2/tools/swig/test/Flat.i +36 -0
  381. numpy-1.10.0.post2/tools/swig/test/Makefile +37 -0
  382. numpy-1.10.0.post2/tools/swig/test/setup.py +71 -0
  383. numpy-1.10.0.post2/tools/swig/test/testArray.py +385 -0
  384. numpy-1.10.0.post2/tools/swig/test/testFarray.py +159 -0
  385. numpy-1.10.0.post2/tools/swig/test/testFlat.py +200 -0
  386. numpy-1.10.0.post2/tools/swig/test/testFortran.py +173 -0
  387. numpy-1.10.0.post2/tools/swig/test/testMatrix.py +362 -0
  388. numpy-1.10.0.post2/tools/swig/test/testSuperTensor.py +388 -0
  389. numpy-1.10.0.post2/tools/swig/test/testTensor.py +402 -0
  390. numpy-1.10.0.post2/tools/swig/test/testVector.py +381 -0
  391. numpy-1.9.3/INSTALL.txt +0 -138
  392. numpy-1.9.3/LICENSE.txt +0 -30
  393. numpy-1.9.3/MANIFEST.in +0 -26
  394. numpy-1.9.3/PKG-INFO +0 -39
  395. numpy-1.9.3/doc/release/1.9.3-notes.rst +0 -23
  396. numpy-1.9.3/doc/source/conf.py +0 -331
  397. numpy-1.9.3/doc/source/dev/gitwash/branch_list.png +0 -0
  398. numpy-1.9.3/doc/source/dev/gitwash/branch_list_compare.png +0 -0
  399. numpy-1.9.3/doc/source/dev/gitwash/development_workflow.rst +0 -568
  400. numpy-1.9.3/doc/source/dev/gitwash/git_links.inc +0 -88
  401. numpy-1.9.3/doc/source/dev/gitwash/index.rst +0 -14
  402. numpy-1.9.3/doc/source/dev/index.rst +0 -10
  403. numpy-1.9.3/doc/source/reference/arrays.classes.rst +0 -427
  404. numpy-1.9.3/doc/source/reference/arrays.dtypes.rst +0 -534
  405. numpy-1.9.3/doc/source/reference/arrays.indexing.rst +0 -550
  406. numpy-1.9.3/doc/source/reference/arrays.interface.rst +0 -336
  407. numpy-1.9.3/doc/source/reference/arrays.ndarray.rst +0 -609
  408. numpy-1.9.3/doc/source/reference/arrays.scalars.rst +0 -291
  409. numpy-1.9.3/doc/source/reference/c-api.array.rst +0 -3362
  410. numpy-1.9.3/doc/source/reference/c-api.config.rst +0 -103
  411. numpy-1.9.3/doc/source/reference/c-api.coremath.rst +0 -420
  412. numpy-1.9.3/doc/source/reference/c-api.dtype.rst +0 -376
  413. numpy-1.9.3/doc/source/reference/c-api.generalized-ufuncs.rst +0 -171
  414. numpy-1.9.3/doc/source/reference/c-api.iterator.rst +0 -1298
  415. numpy-1.9.3/doc/source/reference/c-api.types-and-structures.rst +0 -1204
  416. numpy-1.9.3/doc/source/reference/c-api.ufunc.rst +0 -399
  417. numpy-1.9.3/doc/source/reference/index.rst +0 -44
  418. numpy-1.9.3/doc/source/reference/internals.code-explanations.rst +0 -666
  419. numpy-1.9.3/doc/source/reference/routines.array-manipulation.rst +0 -113
  420. numpy-1.9.3/doc/source/reference/routines.io.rst +0 -74
  421. numpy-1.9.3/doc/source/reference/routines.linalg.rst +0 -88
  422. numpy-1.9.3/doc/source/reference/routines.ma.rst +0 -405
  423. numpy-1.9.3/doc/source/reference/routines.sort.rst +0 -42
  424. numpy-1.9.3/doc/source/reference/routines.statistics.rst +0 -55
  425. numpy-1.9.3/doc/source/reference/swig.interface-file.rst +0 -1055
  426. numpy-1.9.3/doc/source/reference/swig.testing.rst +0 -166
  427. numpy-1.9.3/doc/source/reference/ufuncs.rst +0 -651
  428. numpy-1.9.3/doc/source/release.rst +0 -19
  429. numpy-1.9.3/doc/source/user/basics.io.genfromtxt.rst +0 -531
  430. numpy-1.9.3/doc/source/user/basics.rec.rst +0 -7
  431. numpy-1.9.3/doc/source/user/c-info.beyond-basics.rst +0 -560
  432. numpy-1.9.3/doc/source/user/c-info.how-to-extend.rst +0 -642
  433. numpy-1.9.3/doc/source/user/c-info.python-as-glue.rst +0 -1528
  434. numpy-1.9.3/doc/source/user/c-info.ufunc-tutorial.rst +0 -1211
  435. numpy-1.9.3/doc/source/user/install.rst +0 -180
  436. numpy-1.9.3/numpy/__init__.py +0 -216
  437. numpy-1.9.3/numpy/_import_tools.py +0 -348
  438. numpy-1.9.3/numpy/add_newdocs.py +0 -7518
  439. numpy-1.9.3/numpy/compat/_inspect.py +0 -221
  440. numpy-1.9.3/numpy/compat/py3k.py +0 -89
  441. numpy-1.9.3/numpy/compat/setup.py +0 -12
  442. numpy-1.9.3/numpy/core/__init__.py +0 -78
  443. numpy-1.9.3/numpy/core/_internal.py +0 -570
  444. numpy-1.9.3/numpy/core/_methods.py +0 -134
  445. numpy-1.9.3/numpy/core/arrayprint.py +0 -752
  446. numpy-1.9.3/numpy/core/blasdot/_dotblas.c +0 -1255
  447. numpy-1.9.3/numpy/core/blasdot/apple_sgemv_patch.c +0 -216
  448. numpy-1.9.3/numpy/core/blasdot/cblas.h +0 -578
  449. numpy-1.9.3/numpy/core/code_generators/cversions.txt +0 -31
  450. numpy-1.9.3/numpy/core/code_generators/generate_ufunc_api.py +0 -219
  451. numpy-1.9.3/numpy/core/code_generators/generate_umath.py +0 -972
  452. numpy-1.9.3/numpy/core/code_generators/numpy_api.py +0 -412
  453. numpy-1.9.3/numpy/core/code_generators/ufunc_docstrings.py +0 -3419
  454. numpy-1.9.3/numpy/core/defchararray.py +0 -2687
  455. numpy-1.9.3/numpy/core/fromnumeric.py +0 -2938
  456. numpy-1.9.3/numpy/core/function_base.py +0 -190
  457. numpy-1.9.3/numpy/core/getlimits.py +0 -306
  458. numpy-1.9.3/numpy/core/include/numpy/fenv/fenv.c +0 -38
  459. numpy-1.9.3/numpy/core/include/numpy/fenv/fenv.h +0 -224
  460. numpy-1.9.3/numpy/core/include/numpy/ndarrayobject.h +0 -237
  461. numpy-1.9.3/numpy/core/include/numpy/ndarraytypes.h +0 -1820
  462. numpy-1.9.3/numpy/core/include/numpy/npy_3kcompat.h +0 -506
  463. numpy-1.9.3/numpy/core/include/numpy/npy_common.h +0 -1038
  464. numpy-1.9.3/numpy/core/include/numpy/npy_cpu.h +0 -122
  465. numpy-1.9.3/numpy/core/include/numpy/npy_endian.h +0 -49
  466. numpy-1.9.3/numpy/core/include/numpy/npy_math.h +0 -479
  467. numpy-1.9.3/numpy/core/include/numpy/numpyconfig.h +0 -35
  468. numpy-1.9.3/numpy/core/machar.py +0 -338
  469. numpy-1.9.3/numpy/core/memmap.py +0 -308
  470. numpy-1.9.3/numpy/core/numeric.py +0 -2842
  471. numpy-1.9.3/numpy/core/numerictypes.py +0 -1042
  472. numpy-1.9.3/numpy/core/records.py +0 -804
  473. numpy-1.9.3/numpy/core/setup.py +0 -1016
  474. numpy-1.9.3/numpy/core/setup_common.py +0 -330
  475. numpy-1.9.3/numpy/core/shape_base.py +0 -277
  476. numpy-1.9.3/numpy/core/src/multiarray/alloc.c +0 -241
  477. numpy-1.9.3/numpy/core/src/multiarray/arrayobject.c +0 -1791
  478. numpy-1.9.3/numpy/core/src/multiarray/arraytypes.c.src +0 -4372
  479. numpy-1.9.3/numpy/core/src/multiarray/arraytypes.h +0 -13
  480. numpy-1.9.3/numpy/core/src/multiarray/buffer.c +0 -954
  481. numpy-1.9.3/numpy/core/src/multiarray/calculation.c +0 -1229
  482. numpy-1.9.3/numpy/core/src/multiarray/common.c +0 -798
  483. numpy-1.9.3/numpy/core/src/multiarray/common.h +0 -328
  484. numpy-1.9.3/numpy/core/src/multiarray/conversion_utils.c +0 -1240
  485. numpy-1.9.3/numpy/core/src/multiarray/convert.c +0 -589
  486. numpy-1.9.3/numpy/core/src/multiarray/convert_datatype.c +0 -2199
  487. numpy-1.9.3/numpy/core/src/multiarray/ctors.c +0 -3785
  488. numpy-1.9.3/numpy/core/src/multiarray/datetime.c +0 -3823
  489. numpy-1.9.3/numpy/core/src/multiarray/datetime_busday.c +0 -1322
  490. numpy-1.9.3/numpy/core/src/multiarray/datetime_busdaycal.c +0 -552
  491. numpy-1.9.3/numpy/core/src/multiarray/datetime_strings.c +0 -1772
  492. numpy-1.9.3/numpy/core/src/multiarray/descriptor.c +0 -3658
  493. numpy-1.9.3/numpy/core/src/multiarray/dtype_transfer.c +0 -4232
  494. numpy-1.9.3/numpy/core/src/multiarray/einsum.c.src +0 -3013
  495. numpy-1.9.3/numpy/core/src/multiarray/getset.c +0 -984
  496. numpy-1.9.3/numpy/core/src/multiarray/hashdescr.c +0 -319
  497. numpy-1.9.3/numpy/core/src/multiarray/item_selection.c +0 -2711
  498. numpy-1.9.3/numpy/core/src/multiarray/iterators.c +0 -2160
  499. numpy-1.9.3/numpy/core/src/multiarray/lowlevel_strided_loops.c.src +0 -1767
  500. numpy-1.9.3/numpy/core/src/multiarray/mapping.c +0 -3316
  501. numpy-1.9.3/numpy/core/src/multiarray/mapping.h +0 -73
  502. numpy-1.9.3/numpy/core/src/multiarray/methods.c +0 -2497
  503. numpy-1.9.3/numpy/core/src/multiarray/multiarray_tests.c.src +0 -977
  504. numpy-1.9.3/numpy/core/src/multiarray/multiarraymodule.c +0 -4200
  505. numpy-1.9.3/numpy/core/src/multiarray/multiarraymodule.h +0 -4
  506. numpy-1.9.3/numpy/core/src/multiarray/nditer_api.c +0 -2809
  507. numpy-1.9.3/numpy/core/src/multiarray/nditer_constr.c +0 -3159
  508. numpy-1.9.3/numpy/core/src/multiarray/nditer_pywrap.c +0 -2492
  509. numpy-1.9.3/numpy/core/src/multiarray/number.c +0 -1057
  510. numpy-1.9.3/numpy/core/src/multiarray/number.h +0 -76
  511. numpy-1.9.3/numpy/core/src/multiarray/numpymemoryview.c +0 -309
  512. numpy-1.9.3/numpy/core/src/multiarray/numpyos.c +0 -683
  513. numpy-1.9.3/numpy/core/src/multiarray/scalarapi.c +0 -861
  514. numpy-1.9.3/numpy/core/src/multiarray/scalartypes.c.src +0 -4270
  515. numpy-1.9.3/numpy/core/src/multiarray/scalartypes.h +0 -52
  516. numpy-1.9.3/numpy/core/src/multiarray/shape.c +0 -1141
  517. numpy-1.9.3/numpy/core/src/multiarray/ucsnarrow.c +0 -173
  518. numpy-1.9.3/numpy/core/src/npymath/ieee754.c.src +0 -814
  519. numpy-1.9.3/numpy/core/src/npymath/npy_math.c.src +0 -527
  520. numpy-1.9.3/numpy/core/src/npymath/npy_math_complex.c.src +0 -291
  521. numpy-1.9.3/numpy/core/src/npymath/npy_math_private.h +0 -539
  522. numpy-1.9.3/numpy/core/src/npysort/heapsort.c.src +0 -341
  523. numpy-1.9.3/numpy/core/src/npysort/mergesort.c.src +0 -428
  524. numpy-1.9.3/numpy/core/src/npysort/npysort_common.h +0 -367
  525. numpy-1.9.3/numpy/core/src/npysort/quicksort.c.src +0 -363
  526. numpy-1.9.3/numpy/core/src/npysort/selection.c.src +0 -474
  527. numpy-1.9.3/numpy/core/src/private/npy_config.h +0 -68
  528. numpy-1.9.3/numpy/core/src/private/npy_partition.h.src +0 -138
  529. numpy-1.9.3/numpy/core/src/private/npy_sort.h +0 -194
  530. numpy-1.9.3/numpy/core/src/private/scalarmathmodule.h.src +0 -42
  531. numpy-1.9.3/numpy/core/src/private/ufunc_override.h +0 -384
  532. numpy-1.9.3/numpy/core/src/scalarmathmodule.c.src +0 -1980
  533. numpy-1.9.3/numpy/core/src/umath/funcs.inc.src +0 -715
  534. numpy-1.9.3/numpy/core/src/umath/loops.c.src +0 -2654
  535. numpy-1.9.3/numpy/core/src/umath/loops.h.src +0 -501
  536. numpy-1.9.3/numpy/core/src/umath/operand_flag_tests.c.src +0 -105
  537. numpy-1.9.3/numpy/core/src/umath/simd.inc.src +0 -881
  538. numpy-1.9.3/numpy/core/src/umath/test_rational.c.src +0 -1404
  539. numpy-1.9.3/numpy/core/src/umath/ufunc_object.c +0 -5520
  540. numpy-1.9.3/numpy/core/src/umath/ufunc_type_resolution.c +0 -2164
  541. numpy-1.9.3/numpy/core/src/umath/umath_tests.c.src +0 -341
  542. numpy-1.9.3/numpy/core/src/umath/umathmodule.c +0 -561
  543. numpy-1.9.3/numpy/core/tests/test_abc.py +0 -45
  544. numpy-1.9.3/numpy/core/tests/test_api.py +0 -514
  545. numpy-1.9.3/numpy/core/tests/test_arrayprint.py +0 -167
  546. numpy-1.9.3/numpy/core/tests/test_blasdot.py +0 -249
  547. numpy-1.9.3/numpy/core/tests/test_datetime.py +0 -1781
  548. numpy-1.9.3/numpy/core/tests/test_defchararray.py +0 -642
  549. numpy-1.9.3/numpy/core/tests/test_deprecations.py +0 -512
  550. numpy-1.9.3/numpy/core/tests/test_dtype.py +0 -542
  551. numpy-1.9.3/numpy/core/tests/test_einsum.py +0 -583
  552. numpy-1.9.3/numpy/core/tests/test_errstate.py +0 -51
  553. numpy-1.9.3/numpy/core/tests/test_function_base.py +0 -111
  554. numpy-1.9.3/numpy/core/tests/test_getlimits.py +0 -86
  555. numpy-1.9.3/numpy/core/tests/test_half.py +0 -439
  556. numpy-1.9.3/numpy/core/tests/test_indexerrors.py +0 -127
  557. numpy-1.9.3/numpy/core/tests/test_indexing.py +0 -1014
  558. numpy-1.9.3/numpy/core/tests/test_item_selection.py +0 -70
  559. numpy-1.9.3/numpy/core/tests/test_machar.py +0 -30
  560. numpy-1.9.3/numpy/core/tests/test_memmap.py +0 -127
  561. numpy-1.9.3/numpy/core/tests/test_multiarray.py +0 -4645
  562. numpy-1.9.3/numpy/core/tests/test_multiarray_assignment.py +0 -80
  563. numpy-1.9.3/numpy/core/tests/test_nditer.py +0 -2630
  564. numpy-1.9.3/numpy/core/tests/test_numeric.py +0 -2117
  565. numpy-1.9.3/numpy/core/tests/test_numerictypes.py +0 -377
  566. numpy-1.9.3/numpy/core/tests/test_print.py +0 -245
  567. numpy-1.9.3/numpy/core/tests/test_records.py +0 -185
  568. numpy-1.9.3/numpy/core/tests/test_regression.py +0 -2115
  569. numpy-1.9.3/numpy/core/tests/test_scalarinherit.py +0 -34
  570. numpy-1.9.3/numpy/core/tests/test_scalarmath.py +0 -275
  571. numpy-1.9.3/numpy/core/tests/test_shape_base.py +0 -250
  572. numpy-1.9.3/numpy/core/tests/test_ufunc.py +0 -1153
  573. numpy-1.9.3/numpy/core/tests/test_umath.py +0 -1695
  574. numpy-1.9.3/numpy/core/tests/test_umath_complex.py +0 -537
  575. numpy-1.9.3/numpy/core/tests/test_unicode.py +0 -357
  576. numpy-1.9.3/numpy/distutils/__init__.py +0 -39
  577. numpy-1.9.3/numpy/distutils/ccompiler.py +0 -656
  578. numpy-1.9.3/numpy/distutils/command/autodist.py +0 -43
  579. numpy-1.9.3/numpy/distutils/command/build.py +0 -39
  580. numpy-1.9.3/numpy/distutils/command/build_clib.py +0 -284
  581. numpy-1.9.3/numpy/distutils/command/build_ext.py +0 -515
  582. numpy-1.9.3/numpy/distutils/command/config.py +0 -476
  583. numpy-1.9.3/numpy/distutils/exec_command.py +0 -618
  584. numpy-1.9.3/numpy/distutils/fcompiler/compaq.py +0 -128
  585. numpy-1.9.3/numpy/distutils/fcompiler/gnu.py +0 -390
  586. numpy-1.9.3/numpy/distutils/fcompiler/intel.py +0 -205
  587. numpy-1.9.3/numpy/distutils/fcompiler/pg.py +0 -60
  588. numpy-1.9.3/numpy/distutils/fcompiler/sun.py +0 -52
  589. numpy-1.9.3/numpy/distutils/intelccompiler.py +0 -45
  590. numpy-1.9.3/numpy/distutils/lib2def.py +0 -116
  591. numpy-1.9.3/numpy/distutils/mingw32ccompiler.py +0 -582
  592. numpy-1.9.3/numpy/distutils/misc_util.py +0 -2271
  593. numpy-1.9.3/numpy/distutils/npy_pkg_config.py +0 -464
  594. numpy-1.9.3/numpy/distutils/system_info.py +0 -2319
  595. numpy-1.9.3/numpy/distutils/tests/f2py_ext/tests/test_fib2.py +0 -13
  596. numpy-1.9.3/numpy/distutils/tests/f2py_f90_ext/tests/test_foo.py +0 -12
  597. numpy-1.9.3/numpy/distutils/tests/gen_ext/tests/test_fib3.py +0 -12
  598. numpy-1.9.3/numpy/distutils/tests/pyrex_ext/tests/test_primes.py +0 -14
  599. numpy-1.9.3/numpy/distutils/tests/swig_ext/tests/test_example.py +0 -18
  600. numpy-1.9.3/numpy/distutils/tests/swig_ext/tests/test_example2.py +0 -16
  601. numpy-1.9.3/numpy/distutils/tests/test_fcompiler_gnu.py +0 -53
  602. numpy-1.9.3/numpy/distutils/tests/test_fcompiler_intel.py +0 -36
  603. numpy-1.9.3/numpy/distutils/tests/test_misc_util.py +0 -75
  604. numpy-1.9.3/numpy/distutils/tests/test_npy_pkg_config.py +0 -98
  605. numpy-1.9.3/numpy/distutils/unixccompiler.py +0 -113
  606. numpy-1.9.3/numpy/doc/byteswapping.py +0 -147
  607. numpy-1.9.3/numpy/doc/creation.py +0 -144
  608. numpy-1.9.3/numpy/doc/glossary.py +0 -418
  609. numpy-1.9.3/numpy/doc/indexing.py +0 -437
  610. numpy-1.9.3/numpy/doc/structured_arrays.py +0 -223
  611. numpy-1.9.3/numpy/f2py/__init__.py +0 -49
  612. numpy-1.9.3/numpy/f2py/auxfuncs.py +0 -711
  613. numpy-1.9.3/numpy/f2py/capi_maps.py +0 -773
  614. numpy-1.9.3/numpy/f2py/cb_rules.py +0 -539
  615. numpy-1.9.3/numpy/f2py/cfuncs.py +0 -1224
  616. numpy-1.9.3/numpy/f2py/common_rules.py +0 -132
  617. numpy-1.9.3/numpy/f2py/crackfortran.py +0 -2870
  618. numpy-1.9.3/numpy/f2py/diagnose.py +0 -149
  619. numpy-1.9.3/numpy/f2py/f2py2e.py +0 -598
  620. numpy-1.9.3/numpy/f2py/f2py_testing.py +0 -46
  621. numpy-1.9.3/numpy/f2py/f90mod_rules.py +0 -246
  622. numpy-1.9.3/numpy/f2py/func2subr.py +0 -291
  623. numpy-1.9.3/numpy/f2py/rules.py +0 -1448
  624. numpy-1.9.3/numpy/f2py/setup.py +0 -129
  625. numpy-1.9.3/numpy/f2py/src/fortranobject.c +0 -972
  626. numpy-1.9.3/numpy/f2py/src/fortranobject.h +0 -162
  627. numpy-1.9.3/numpy/f2py/tests/src/array_from_pyobj/wrapmodule.c +0 -223
  628. numpy-1.9.3/numpy/f2py/tests/test_array_from_pyobj.py +0 -559
  629. numpy-1.9.3/numpy/f2py/tests/test_assumed_shape.py +0 -37
  630. numpy-1.9.3/numpy/f2py/tests/test_callback.py +0 -132
  631. numpy-1.9.3/numpy/f2py/tests/test_kind.py +0 -36
  632. numpy-1.9.3/numpy/f2py/tests/test_mixed.py +0 -41
  633. numpy-1.9.3/numpy/f2py/tests/test_regression.py +0 -32
  634. numpy-1.9.3/numpy/f2py/tests/test_return_character.py +0 -142
  635. numpy-1.9.3/numpy/f2py/tests/test_return_complex.py +0 -169
  636. numpy-1.9.3/numpy/f2py/tests/test_return_integer.py +0 -178
  637. numpy-1.9.3/numpy/f2py/tests/test_return_logical.py +0 -187
  638. numpy-1.9.3/numpy/f2py/tests/test_return_real.py +0 -203
  639. numpy-1.9.3/numpy/f2py/tests/test_size.py +0 -47
  640. numpy-1.9.3/numpy/f2py/tests/util.py +0 -353
  641. numpy-1.9.3/numpy/f2py/use_rules.py +0 -109
  642. numpy-1.9.3/numpy/fft/fftpack.c +0 -1501
  643. numpy-1.9.3/numpy/fft/fftpack.h +0 -28
  644. numpy-1.9.3/numpy/fft/fftpack.py +0 -1169
  645. numpy-1.9.3/numpy/fft/fftpack_litemodule.c +0 -371
  646. numpy-1.9.3/numpy/fft/info.py +0 -179
  647. numpy-1.9.3/numpy/fft/setup.py +0 -20
  648. numpy-1.9.3/numpy/fft/tests/test_fftpack.py +0 -75
  649. numpy-1.9.3/numpy/fft/tests/test_helper.py +0 -78
  650. numpy-1.9.3/numpy/lib/_iotools.py +0 -891
  651. numpy-1.9.3/numpy/lib/arraypad.py +0 -1475
  652. numpy-1.9.3/numpy/lib/arraysetops.py +0 -464
  653. numpy-1.9.3/numpy/lib/arrayterator.py +0 -226
  654. numpy-1.9.3/numpy/lib/financial.py +0 -737
  655. numpy-1.9.3/numpy/lib/format.py +0 -771
  656. numpy-1.9.3/numpy/lib/function_base.py +0 -3884
  657. numpy-1.9.3/numpy/lib/index_tricks.py +0 -869
  658. numpy-1.9.3/numpy/lib/info.py +0 -151
  659. numpy-1.9.3/numpy/lib/nanfunctions.py +0 -1158
  660. numpy-1.9.3/numpy/lib/npyio.py +0 -1871
  661. numpy-1.9.3/numpy/lib/polynomial.py +0 -1271
  662. numpy-1.9.3/numpy/lib/recfunctions.py +0 -1003
  663. numpy-1.9.3/numpy/lib/setup.py +0 -23
  664. numpy-1.9.3/numpy/lib/shape_base.py +0 -865
  665. numpy-1.9.3/numpy/lib/src/_compiled_base.c +0 -1761
  666. numpy-1.9.3/numpy/lib/stride_tricks.py +0 -123
  667. numpy-1.9.3/numpy/lib/tests/test__iotools.py +0 -326
  668. numpy-1.9.3/numpy/lib/tests/test__version.py +0 -57
  669. numpy-1.9.3/numpy/lib/tests/test_arraypad.py +0 -560
  670. numpy-1.9.3/numpy/lib/tests/test_arraysetops.py +0 -301
  671. numpy-1.9.3/numpy/lib/tests/test_financial.py +0 -160
  672. numpy-1.9.3/numpy/lib/tests/test_format.py +0 -716
  673. numpy-1.9.3/numpy/lib/tests/test_function_base.py +0 -2145
  674. numpy-1.9.3/numpy/lib/tests/test_index_tricks.py +0 -289
  675. numpy-1.9.3/numpy/lib/tests/test_io.py +0 -1754
  676. numpy-1.9.3/numpy/lib/tests/test_nanfunctions.py +0 -774
  677. numpy-1.9.3/numpy/lib/tests/test_polynomial.py +0 -177
  678. numpy-1.9.3/numpy/lib/tests/test_recfunctions.py +0 -705
  679. numpy-1.9.3/numpy/lib/tests/test_shape_base.py +0 -368
  680. numpy-1.9.3/numpy/lib/tests/test_stride_tricks.py +0 -238
  681. numpy-1.9.3/numpy/lib/tests/test_twodim_base.py +0 -504
  682. numpy-1.9.3/numpy/lib/tests/test_type_check.py +0 -328
  683. numpy-1.9.3/numpy/lib/twodim_base.py +0 -1003
  684. numpy-1.9.3/numpy/lib/type_check.py +0 -605
  685. numpy-1.9.3/numpy/lib/utils.py +0 -1176
  686. numpy-1.9.3/numpy/linalg/lapack_lite/python_xerbla.c +0 -47
  687. numpy-1.9.3/numpy/linalg/lapack_litemodule.c +0 -362
  688. numpy-1.9.3/numpy/linalg/linalg.py +0 -2136
  689. numpy-1.9.3/numpy/linalg/tests/test_build.py +0 -53
  690. numpy-1.9.3/numpy/linalg/tests/test_linalg.py +0 -1156
  691. numpy-1.9.3/numpy/linalg/tests/test_regression.py +0 -90
  692. numpy-1.9.3/numpy/linalg/umath_linalg.c.src +0 -3210
  693. numpy-1.9.3/numpy/ma/__init__.py +0 -58
  694. numpy-1.9.3/numpy/ma/bench.py +0 -166
  695. numpy-1.9.3/numpy/ma/core.py +0 -7374
  696. numpy-1.9.3/numpy/ma/extras.py +0 -1932
  697. numpy-1.9.3/numpy/ma/mrecords.py +0 -734
  698. numpy-1.9.3/numpy/ma/setup.py +0 -20
  699. numpy-1.9.3/numpy/ma/tests/test_core.py +0 -3706
  700. numpy-1.9.3/numpy/ma/tests/test_extras.py +0 -954
  701. numpy-1.9.3/numpy/ma/tests/test_mrecords.py +0 -521
  702. numpy-1.9.3/numpy/ma/tests/test_old_ma.py +0 -869
  703. numpy-1.9.3/numpy/ma/tests/test_regression.py +0 -75
  704. numpy-1.9.3/numpy/ma/tests/test_subclassing.py +0 -236
  705. numpy-1.9.3/numpy/ma/testutils.py +0 -240
  706. numpy-1.9.3/numpy/ma/timer_comparison.py +0 -459
  707. numpy-1.9.3/numpy/matlib.py +0 -358
  708. numpy-1.9.3/numpy/matrixlib/defmatrix.py +0 -1094
  709. numpy-1.9.3/numpy/matrixlib/tests/test_defmatrix.py +0 -400
  710. numpy-1.9.3/numpy/matrixlib/tests/test_multiarray.py +0 -18
  711. numpy-1.9.3/numpy/matrixlib/tests/test_numeric.py +0 -10
  712. numpy-1.9.3/numpy/matrixlib/tests/test_regression.py +0 -34
  713. numpy-1.9.3/numpy/polynomial/_polybase.py +0 -962
  714. numpy-1.9.3/numpy/polynomial/chebyshev.py +0 -2056
  715. numpy-1.9.3/numpy/polynomial/hermite.py +0 -1789
  716. numpy-1.9.3/numpy/polynomial/hermite_e.py +0 -1786
  717. numpy-1.9.3/numpy/polynomial/laguerre.py +0 -1781
  718. numpy-1.9.3/numpy/polynomial/legendre.py +0 -1809
  719. numpy-1.9.3/numpy/polynomial/polytemplate.py +0 -927
  720. numpy-1.9.3/numpy/polynomial/polyutils.py +0 -403
  721. numpy-1.9.3/numpy/random/mtrand/distributions.c +0 -892
  722. numpy-1.9.3/numpy/random/mtrand/mtrand.c +0 -36656
  723. numpy-1.9.3/numpy/random/mtrand/mtrand.pyx +0 -4706
  724. numpy-1.9.3/numpy/random/setup.py +0 -74
  725. numpy-1.9.3/numpy/random/tests/test_random.py +0 -707
  726. numpy-1.9.3/numpy/random/tests/test_regression.py +0 -86
  727. numpy-1.9.3/numpy/setup.py +0 -27
  728. numpy-1.9.3/numpy/testing/__init__.py +0 -16
  729. numpy-1.9.3/numpy/testing/decorators.py +0 -271
  730. numpy-1.9.3/numpy/testing/noseclasses.py +0 -353
  731. numpy-1.9.3/numpy/testing/nosetester.py +0 -504
  732. numpy-1.9.3/numpy/testing/print_coercion_tables.py +0 -89
  733. numpy-1.9.3/numpy/testing/setup.py +0 -20
  734. numpy-1.9.3/numpy/testing/tests/test_decorators.py +0 -185
  735. numpy-1.9.3/numpy/testing/tests/test_utils.py +0 -558
  736. numpy-1.9.3/numpy/testing/utils.py +0 -1715
  737. numpy-1.9.3/numpy/tests/test_ctypeslib.py +0 -102
  738. numpy-1.9.3/numpy/tests/test_matlib.py +0 -55
  739. numpy-1.9.3/numpy/version.py +0 -10
  740. numpy-1.9.3/setup.py +0 -251
  741. numpy-1.9.3/site.cfg.example +0 -157
  742. numpy-1.9.3/tools/swig/README +0 -135
  743. numpy-1.9.3/tools/swig/numpy.i +0 -3085
  744. numpy-1.9.3/tools/swig/test/Array.i +0 -102
  745. numpy-1.9.3/tools/swig/test/Makefile +0 -34
  746. numpy-1.9.3/tools/swig/test/setup.py +0 -64
  747. numpy-1.9.3/tools/swig/test/testArray.py +0 -284
  748. numpy-1.9.3/tools/swig/test/testFarray.py +0 -159
  749. numpy-1.9.3/tools/swig/test/testFortran.py +0 -173
  750. numpy-1.9.3/tools/swig/test/testMatrix.py +0 -362
  751. numpy-1.9.3/tools/swig/test/testSuperTensor.py +0 -388
  752. numpy-1.9.3/tools/swig/test/testTensor.py +0 -402
  753. numpy-1.9.3/tools/swig/test/testVector.py +0 -381
  754. {numpy-1.9.3 → numpy-1.10.0.post2}/BENTO_BUILD.txt +0 -0
  755. {numpy-1.9.3 → numpy-1.10.0.post2}/COMPATIBILITY +0 -0
  756. {numpy-1.9.3 → numpy-1.10.0.post2}/DEV_README.txt +0 -0
  757. {numpy-1.9.3 → numpy-1.10.0.post2}/README.txt +0 -0
  758. {numpy-1.9.3 → numpy-1.10.0.post2}/THANKS.txt +0 -0
  759. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/Makefile +0 -0
  760. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/BUGS.txt +0 -0
  761. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/FAQ.txt +0 -0
  762. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/HISTORY.txt +0 -0
  763. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/Makefile +0 -0
  764. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/OLDNEWS.txt +0 -0
  765. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/README.txt +0 -0
  766. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/Release-1.x.txt +0 -0
  767. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/Release-2.x.txt +0 -0
  768. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/Release-3.x.txt +0 -0
  769. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/Release-4.x.txt +0 -0
  770. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/TESTING.txt +0 -0
  771. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/THANKS.txt +0 -0
  772. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/TODO.txt +0 -0
  773. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/apps.tex +0 -0
  774. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/bugs.tex +0 -0
  775. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/collectinput.py +0 -0
  776. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/commands.tex +0 -0
  777. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/default.css +0 -0
  778. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/docutils.conf +0 -0
  779. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/ex1/arr.f +0 -0
  780. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/ex1/bar.f +0 -0
  781. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/ex1/foo.f +0 -0
  782. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/ex1/foobar-smart.f90 +0 -0
  783. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/ex1/foobar.f90 +0 -0
  784. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/ex1/foobarmodule.tex +0 -0
  785. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/ex1/runme +0 -0
  786. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/f2py.1 +0 -0
  787. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/f2py2e.tex +0 -0
  788. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/f2python9-final/README.txt +0 -0
  789. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/f2python9-final/aerostructure.jpg +0 -0
  790. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/f2python9-final/flow.jpg +0 -0
  791. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/f2python9-final/mk_html.sh +0 -0
  792. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/f2python9-final/mk_pdf.sh +0 -0
  793. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/f2python9-final/mk_ps.sh +0 -0
  794. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/f2python9-final/src/examples/exp1.f +0 -0
  795. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/f2python9-final/src/examples/exp1mess.txt +0 -0
  796. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/f2python9-final/src/examples/exp1session.txt +0 -0
  797. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/f2python9-final/src/examples/foo.pyf +0 -0
  798. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/f2python9-final/src/examples/foom.pyf +0 -0
  799. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/f2python9-final/structure.jpg +0 -0
  800. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/fortranobject.tex +0 -0
  801. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/hello.f +0 -0
  802. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/index.html +0 -0
  803. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/intro.tex +0 -0
  804. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/multiarray/array_from_pyobj.c +0 -0
  805. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/multiarray/bar.c +0 -0
  806. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/multiarray/foo.f +0 -0
  807. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/multiarray/fortran_array_from_pyobj.txt +0 -0
  808. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/multiarray/fun.pyf +0 -0
  809. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/multiarray/run.pyf +0 -0
  810. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/multiarray/transpose.txt +0 -0
  811. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/multiarrays.txt +0 -0
  812. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/notes.tex +0 -0
  813. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/oldnews.html +0 -0
  814. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/options.tex +0 -0
  815. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/pyforttest.pyf +0 -0
  816. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/pytest.py +0 -0
  817. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/python9.tex +0 -0
  818. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/signaturefile.tex +0 -0
  819. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/simple.f +0 -0
  820. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/simple_session.dat +0 -0
  821. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/using_F_compiler.txt +0 -0
  822. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/f2py/win32_notes.txt +0 -0
  823. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/postprocess.py +0 -0
  824. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/release/1.3.0-notes.rst +0 -0
  825. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/release/1.4.0-notes.rst +0 -0
  826. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/release/1.5.0-notes.rst +0 -0
  827. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/release/1.6.0-notes.rst +0 -0
  828. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/release/1.6.1-notes.rst +0 -0
  829. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/release/1.6.2-notes.rst +0 -0
  830. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/release/1.7.0-notes.rst +0 -0
  831. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/release/1.7.1-notes.rst +0 -0
  832. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/release/1.7.2-notes.rst +0 -0
  833. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/release/1.8.0-notes.rst +0 -0
  834. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/release/1.8.1-notes.rst +0 -0
  835. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/release/1.8.2-notes.rst +0 -0
  836. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/release/1.9.0-notes.rst +0 -0
  837. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/release/1.9.1-notes.rst +0 -0
  838. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/release/1.9.2-notes.rst +0 -0
  839. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/release/time_based_proposal.rst +0 -0
  840. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/.git +0 -0
  841. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/.gitignore +0 -0
  842. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/Makefile +0 -0
  843. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/README.rst +0 -0
  844. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_static/scipyshiny_small.png +0 -0
  845. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/layout.html +0 -0
  846. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/searchbox.html +0 -0
  847. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/sourcelink.html +0 -0
  848. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/css/extend.css +0 -0
  849. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/css/pygments.css +0 -0
  850. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/css/scipy-central.css +0 -0
  851. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/css/spc-bootstrap.css +0 -0
  852. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/css/spc-extend.css +0 -0
  853. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/all-icons.svg +0 -0
  854. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/contents.png +0 -0
  855. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/create-new-account-icon.png +0 -0
  856. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/external-link-icon-shrunk.png +0 -0
  857. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/external-link-icon.png +0 -0
  858. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/external-link-icon.svg +0 -0
  859. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/external-link-list-icon-tiniest.png +0 -0
  860. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/external-link-list-icon-tiny.png +0 -0
  861. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/external-link-list-icon.png +0 -0
  862. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ad.png +0 -0
  863. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ae.png +0 -0
  864. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-af.png +0 -0
  865. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ag.png +0 -0
  866. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ai.png +0 -0
  867. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-al.png +0 -0
  868. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-am.png +0 -0
  869. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ao.png +0 -0
  870. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-aq.png +0 -0
  871. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ar.png +0 -0
  872. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-as.png +0 -0
  873. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-at.png +0 -0
  874. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-au.png +0 -0
  875. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-aw.png +0 -0
  876. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-az.png +0 -0
  877. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ba.png +0 -0
  878. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-bb.png +0 -0
  879. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-bd.png +0 -0
  880. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-be.png +0 -0
  881. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-bf.png +0 -0
  882. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-bg.png +0 -0
  883. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-bh.png +0 -0
  884. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-bi.png +0 -0
  885. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-bj.png +0 -0
  886. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-bl.png +0 -0
  887. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-bm.png +0 -0
  888. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-bn.png +0 -0
  889. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-bo.png +0 -0
  890. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-br.png +0 -0
  891. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-bs.png +0 -0
  892. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-bt.png +0 -0
  893. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-bw.png +0 -0
  894. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-by.png +0 -0
  895. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-bz.png +0 -0
  896. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ca.png +0 -0
  897. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-cc.png +0 -0
  898. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-cd.png +0 -0
  899. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-cf.png +0 -0
  900. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-cg.png +0 -0
  901. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ch.png +0 -0
  902. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ci.png +0 -0
  903. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ck.png +0 -0
  904. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-cl.png +0 -0
  905. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-cm.png +0 -0
  906. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-cn.png +0 -0
  907. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-co.png +0 -0
  908. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-cr.png +0 -0
  909. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-cu.png +0 -0
  910. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-cv.png +0 -0
  911. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-cw.png +0 -0
  912. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-cx.png +0 -0
  913. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-cy.png +0 -0
  914. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-cz.png +0 -0
  915. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-de.png +0 -0
  916. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-dj.png +0 -0
  917. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-dk.png +0 -0
  918. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-dm.png +0 -0
  919. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-do.png +0 -0
  920. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-dz.png +0 -0
  921. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ec.png +0 -0
  922. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ee.png +0 -0
  923. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-eg.png +0 -0
  924. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-er.png +0 -0
  925. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-es.png +0 -0
  926. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-et.png +0 -0
  927. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-fi.png +0 -0
  928. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-fj.png +0 -0
  929. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-fk.png +0 -0
  930. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-fm.png +0 -0
  931. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-fo.png +0 -0
  932. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-fr.png +0 -0
  933. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ga.png +0 -0
  934. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-gb.png +0 -0
  935. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-gd.png +0 -0
  936. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ge.png +0 -0
  937. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-gf.png +0 -0
  938. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-gg.png +0 -0
  939. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-gh.png +0 -0
  940. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-gi.png +0 -0
  941. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-gl.png +0 -0
  942. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-gm.png +0 -0
  943. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-gn.png +0 -0
  944. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-gq.png +0 -0
  945. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-gr.png +0 -0
  946. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-gs.png +0 -0
  947. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-gt.png +0 -0
  948. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-gu.png +0 -0
  949. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-gw.png +0 -0
  950. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-gy.png +0 -0
  951. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-hk.png +0 -0
  952. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-hm.png +0 -0
  953. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-hn.png +0 -0
  954. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-hr.png +0 -0
  955. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ht.png +0 -0
  956. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-hu.png +0 -0
  957. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-id.png +0 -0
  958. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ie.png +0 -0
  959. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-il.png +0 -0
  960. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-im.png +0 -0
  961. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-in.png +0 -0
  962. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-io.png +0 -0
  963. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-iq.png +0 -0
  964. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ir.png +0 -0
  965. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-is.png +0 -0
  966. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-it.png +0 -0
  967. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-je.png +0 -0
  968. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-jm.png +0 -0
  969. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-jo.png +0 -0
  970. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-jp.png +0 -0
  971. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ke.png +0 -0
  972. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-kg.png +0 -0
  973. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-kh.png +0 -0
  974. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ki.png +0 -0
  975. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-km.png +0 -0
  976. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-kn.png +0 -0
  977. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-kp.png +0 -0
  978. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-kr.png +0 -0
  979. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-kw.png +0 -0
  980. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ky.png +0 -0
  981. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-kz.png +0 -0
  982. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-la.png +0 -0
  983. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-lb.png +0 -0
  984. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-lc.png +0 -0
  985. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-li.png +0 -0
  986. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-lk.png +0 -0
  987. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-lr.png +0 -0
  988. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ls.png +0 -0
  989. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-lt.png +0 -0
  990. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-lu.png +0 -0
  991. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-lv.png +0 -0
  992. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ly.png +0 -0
  993. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ma.png +0 -0
  994. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-mc.png +0 -0
  995. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-md.png +0 -0
  996. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-me.png +0 -0
  997. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-mf.png +0 -0
  998. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-mg.png +0 -0
  999. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-mh.png +0 -0
  1000. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-mk.png +0 -0
  1001. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ml.png +0 -0
  1002. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-mm.png +0 -0
  1003. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-mn.png +0 -0
  1004. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-mo.png +0 -0
  1005. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-mp.png +0 -0
  1006. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-mq.png +0 -0
  1007. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-mr.png +0 -0
  1008. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ms.png +0 -0
  1009. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-mt.png +0 -0
  1010. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-mu.png +0 -0
  1011. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-mv.png +0 -0
  1012. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-mw.png +0 -0
  1013. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-mx.png +0 -0
  1014. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-my.png +0 -0
  1015. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-mz.png +0 -0
  1016. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-na.png +0 -0
  1017. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-nc.png +0 -0
  1018. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ne.png +0 -0
  1019. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-nf.png +0 -0
  1020. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ng.png +0 -0
  1021. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ni.png +0 -0
  1022. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-nl.png +0 -0
  1023. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-no.png +0 -0
  1024. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-np.png +0 -0
  1025. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-nr.png +0 -0
  1026. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-nu.png +0 -0
  1027. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-nz.png +0 -0
  1028. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-om.png +0 -0
  1029. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-pa.png +0 -0
  1030. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-pe.png +0 -0
  1031. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-pf.png +0 -0
  1032. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-pg.png +0 -0
  1033. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ph.png +0 -0
  1034. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-pk.png +0 -0
  1035. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-pl.png +0 -0
  1036. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-pm.png +0 -0
  1037. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-pn.png +0 -0
  1038. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-pr.png +0 -0
  1039. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ps.png +0 -0
  1040. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-pt.png +0 -0
  1041. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-pw.png +0 -0
  1042. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-py.png +0 -0
  1043. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-qa.png +0 -0
  1044. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-re.png +0 -0
  1045. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ro.png +0 -0
  1046. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-rs.png +0 -0
  1047. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ru.png +0 -0
  1048. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-rw.png +0 -0
  1049. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-sa.png +0 -0
  1050. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-sb.png +0 -0
  1051. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-sc.png +0 -0
  1052. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-sd.png +0 -0
  1053. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-se.png +0 -0
  1054. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-sg.png +0 -0
  1055. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-sh.png +0 -0
  1056. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-si.png +0 -0
  1057. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-sj.png +0 -0
  1058. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-sk.png +0 -0
  1059. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-sl.png +0 -0
  1060. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-sm.png +0 -0
  1061. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-sn.png +0 -0
  1062. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-so.png +0 -0
  1063. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-sr.png +0 -0
  1064. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-st.png +0 -0
  1065. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-sv.png +0 -0
  1066. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-sy.png +0 -0
  1067. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-sz.png +0 -0
  1068. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-tc.png +0 -0
  1069. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-td.png +0 -0
  1070. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-tf.png +0 -0
  1071. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-tg.png +0 -0
  1072. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-th.png +0 -0
  1073. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-tj.png +0 -0
  1074. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-tk.png +0 -0
  1075. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-tl.png +0 -0
  1076. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-tm.png +0 -0
  1077. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-tn.png +0 -0
  1078. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-to.png +0 -0
  1079. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-tr.png +0 -0
  1080. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-tt.png +0 -0
  1081. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-tv.png +0 -0
  1082. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-tw.png +0 -0
  1083. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-tz.png +0 -0
  1084. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ua.png +0 -0
  1085. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ug.png +0 -0
  1086. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-um.png +0 -0
  1087. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-us.png +0 -0
  1088. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-uy.png +0 -0
  1089. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-uz.png +0 -0
  1090. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-va.png +0 -0
  1091. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-vc.png +0 -0
  1092. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ve.png +0 -0
  1093. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-vg.png +0 -0
  1094. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-vi.png +0 -0
  1095. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-vn.png +0 -0
  1096. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-vu.png +0 -0
  1097. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-wf.png +0 -0
  1098. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ws.png +0 -0
  1099. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-ye.png +0 -0
  1100. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-za.png +0 -0
  1101. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-zm.png +0 -0
  1102. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/flags/flag-zw.png +0 -0
  1103. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/glyphicons-halflings-white.png +0 -0
  1104. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/glyphicons-halflings.png +0 -0
  1105. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/important-icon.png +0 -0
  1106. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/information-icon.png +0 -0
  1107. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/internet-web-browser.png +0 -0
  1108. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/multiple-file-icon-shrunk.png +0 -0
  1109. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/multiple-file-icon.png +0 -0
  1110. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/multiple-file-icon.svg +0 -0
  1111. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/multiple-file-list-icon-tiny.png +0 -0
  1112. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/multiple-file-list-icon.png +0 -0
  1113. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/navigation.png +0 -0
  1114. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/person-list-icon-tiny.png +0 -0
  1115. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/person-list-icon.png +0 -0
  1116. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/scipy-logo.png +0 -0
  1117. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/scipy_org_logo.gif +0 -0
  1118. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/scipycentral_logo.png +0 -0
  1119. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/scipyshiny_small.png +0 -0
  1120. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/send-email-icon.png +0 -0
  1121. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/single-file-icon-shrunk.png +0 -0
  1122. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/single-file-icon.png +0 -0
  1123. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/single-file-icon.svg +0 -0
  1124. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/single-file-list-icon-tiniest.png +0 -0
  1125. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/single-file-list-icon-tiny.png +0 -0
  1126. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/single-file-list-icon.png +0 -0
  1127. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/transparent-pixel.gif +0 -0
  1128. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/img/ui-anim_basic_16x16.gif +0 -0
  1129. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/js/copybutton.js +0 -0
  1130. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/accordion.less +0 -0
  1131. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/alerts.less +0 -0
  1132. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/bootstrap.less +0 -0
  1133. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/breadcrumbs.less +0 -0
  1134. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/button-groups.less +0 -0
  1135. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/buttons.less +0 -0
  1136. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/carousel.less +0 -0
  1137. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/close.less +0 -0
  1138. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/code.less +0 -0
  1139. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/component-animations.less +0 -0
  1140. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/dropdowns.less +0 -0
  1141. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/forms.less +0 -0
  1142. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/grid.less +0 -0
  1143. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/hero-unit.less +0 -0
  1144. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/labels-badges.less +0 -0
  1145. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/layouts.less +0 -0
  1146. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/media.less +0 -0
  1147. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/mixins.less +0 -0
  1148. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/modals.less +0 -0
  1149. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/navbar.less +0 -0
  1150. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/navs.less +0 -0
  1151. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/pager.less +0 -0
  1152. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/pagination.less +0 -0
  1153. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/popovers.less +0 -0
  1154. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/progress-bars.less +0 -0
  1155. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/reset.less +0 -0
  1156. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/responsive-1200px-min.less +0 -0
  1157. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/responsive-767px-max.less +0 -0
  1158. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/responsive-768px-979px.less +0 -0
  1159. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/responsive-navbar.less +0 -0
  1160. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/responsive-utilities.less +0 -0
  1161. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/responsive.less +0 -0
  1162. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/scaffolding.less +0 -0
  1163. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/sprites.less +0 -0
  1164. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/tables.less +0 -0
  1165. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/thumbnails.less +0 -0
  1166. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/tooltip.less +0 -0
  1167. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/type.less +0 -0
  1168. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/utilities.less +0 -0
  1169. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/variables.less +0 -0
  1170. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/bootstrap/wells.less +0 -0
  1171. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/spc-bootstrap.less +0 -0
  1172. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/spc-content.less +0 -0
  1173. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/spc-extend.less +0 -0
  1174. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/spc-footer.less +0 -0
  1175. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/spc-header.less +0 -0
  1176. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/spc-rightsidebar.less +0 -0
  1177. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/less/spc-utils.less +0 -0
  1178. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/static/scipy.css_t +0 -0
  1179. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/_theme/scipy/theme.conf +0 -0
  1180. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/conf.py +0 -0
  1181. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/index.rst +0 -0
  1182. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/test_autodoc.rst +0 -0
  1183. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/test_autodoc_2.rst +0 -0
  1184. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/test_autodoc_3.rst +0 -0
  1185. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/test_autodoc_4.rst +0 -0
  1186. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/scipy-sphinx-theme/test_optimize.rst +0 -0
  1187. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/_templates/autosummary/class.rst +0 -0
  1188. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/_templates/indexcontent.html +0 -0
  1189. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/_templates/indexsidebar.html +0 -0
  1190. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/_templates/layout.html +0 -0
  1191. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/about.rst +0 -0
  1192. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/bugs.rst +0 -0
  1193. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/contents.rst +0 -0
  1194. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/dev/gitwash/configure_git.rst +0 -0
  1195. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/dev/gitwash/development_setup.rst +0 -0
  1196. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/dev/gitwash/dot2_dot3.rst +0 -0
  1197. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/dev/gitwash/following_latest.rst +0 -0
  1198. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/dev/gitwash/forking_button.png +0 -0
  1199. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/dev/gitwash/git_development.rst +0 -0
  1200. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/dev/gitwash/git_intro.rst +0 -0
  1201. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/dev/gitwash/git_resources.rst +0 -0
  1202. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/dev/gitwash/pull_button.png +0 -0
  1203. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/dev/gitwash_links.txt +0 -0
  1204. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/f2py/advanced.rst +0 -0
  1205. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/f2py/allocarr.f90 +0 -0
  1206. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/f2py/allocarr_session.dat +0 -0
  1207. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/f2py/array.f +0 -0
  1208. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/f2py/array_session.dat +0 -0
  1209. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/f2py/calculate.f +0 -0
  1210. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/f2py/calculate_session.dat +0 -0
  1211. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/f2py/callback.f +0 -0
  1212. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/f2py/callback2.pyf +0 -0
  1213. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/f2py/callback_session.dat +0 -0
  1214. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/f2py/common.f +0 -0
  1215. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/f2py/common_session.dat +0 -0
  1216. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/f2py/compile_session.dat +0 -0
  1217. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/f2py/distutils.rst +0 -0
  1218. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/f2py/extcallback.f +0 -0
  1219. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/f2py/extcallback_session.dat +0 -0
  1220. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/f2py/fib1.f +0 -0
  1221. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/f2py/fib1.pyf +0 -0
  1222. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/f2py/fib2.pyf +0 -0
  1223. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/f2py/fib3.f +0 -0
  1224. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/f2py/ftype.f +0 -0
  1225. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/f2py/ftype_session.dat +0 -0
  1226. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/f2py/getting-started.rst +0 -0
  1227. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/f2py/index.rst +0 -0
  1228. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/f2py/moddata.f90 +0 -0
  1229. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/f2py/moddata_session.dat +0 -0
  1230. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/f2py/python-usage.rst +0 -0
  1231. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/f2py/run_main_session.dat +0 -0
  1232. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/f2py/scalar.f +0 -0
  1233. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/f2py/scalar_session.dat +0 -0
  1234. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/f2py/setup_example.py +0 -0
  1235. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/f2py/signature-file.rst +0 -0
  1236. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/f2py/spam.pyf +0 -0
  1237. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/f2py/spam_session.dat +0 -0
  1238. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/f2py/string.f +0 -0
  1239. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/f2py/string_session.dat +0 -0
  1240. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/f2py/usage.rst +0 -0
  1241. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/f2py/var.pyf +0 -0
  1242. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/f2py/var_session.dat +0 -0
  1243. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/glossary.rst +0 -0
  1244. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/license.rst +0 -0
  1245. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/neps/datetime-proposal.rst +0 -0
  1246. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/neps/datetime-proposal3.rst +0 -0
  1247. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/neps/deferred-ufunc-evaluation.rst +0 -0
  1248. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/neps/generalized-ufuncs.rst +0 -0
  1249. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/neps/groupby_additions.rst +0 -0
  1250. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/neps/index.rst +0 -0
  1251. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/neps/math_config_clean.rst +0 -0
  1252. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/neps/missing-data.rst +0 -0
  1253. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/neps/new-iterator-ufunc.rst +0 -0
  1254. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/neps/newbugtracker.rst +0 -0
  1255. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/neps/npy-format.rst +0 -0
  1256. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/neps/structured_array_extensions.rst +0 -0
  1257. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/neps/ufunc-overrides.rst +0 -0
  1258. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/neps/warnfix.rst +0 -0
  1259. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/arrays.datetime.rst +0 -0
  1260. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/arrays.nditer.rst +0 -0
  1261. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/arrays.rst +0 -0
  1262. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/c-api.deprecations.rst +0 -0
  1263. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/c-api.rst +0 -0
  1264. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/distutils.rst +0 -0
  1265. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/figures/dtype-hierarchy.dia +0 -0
  1266. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/figures/dtype-hierarchy.pdf +0 -0
  1267. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/figures/dtype-hierarchy.png +0 -0
  1268. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/figures/threefundamental.fig +0 -0
  1269. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/figures/threefundamental.pdf +0 -0
  1270. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/figures/threefundamental.png +0 -0
  1271. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/internals.rst +0 -0
  1272. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/maskedarray.baseclass.rst +0 -0
  1273. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/maskedarray.generic.rst +0 -0
  1274. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/maskedarray.rst +0 -0
  1275. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/routines.array-creation.rst +0 -0
  1276. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/routines.bitwise.rst +0 -0
  1277. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/routines.char.rst +0 -0
  1278. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/routines.ctypeslib.rst +0 -0
  1279. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/routines.datetime.rst +0 -0
  1280. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/routines.dtype.rst +0 -0
  1281. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/routines.dual.rst +0 -0
  1282. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/routines.emath.rst +0 -0
  1283. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/routines.err.rst +0 -0
  1284. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/routines.fft.rst +0 -0
  1285. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/routines.financial.rst +0 -0
  1286. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/routines.functional.rst +0 -0
  1287. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/routines.help.rst +0 -0
  1288. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/routines.indexing.rst +0 -0
  1289. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/routines.logic.rst +0 -0
  1290. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/routines.math.rst +0 -0
  1291. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/routines.matlib.rst +0 -0
  1292. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/routines.numarray.rst +0 -0
  1293. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/routines.oldnumeric.rst +0 -0
  1294. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/routines.other.rst +0 -0
  1295. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/routines.padding.rst +0 -0
  1296. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/routines.polynomials.chebyshev.rst +0 -0
  1297. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/routines.polynomials.classes.rst +0 -0
  1298. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/routines.polynomials.hermite.rst +0 -0
  1299. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/routines.polynomials.hermite_e.rst +0 -0
  1300. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/routines.polynomials.laguerre.rst +0 -0
  1301. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/routines.polynomials.legendre.rst +0 -0
  1302. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/routines.polynomials.package.rst +0 -0
  1303. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/routines.polynomials.poly1d.rst +0 -0
  1304. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/routines.polynomials.polynomial.rst +0 -0
  1305. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/routines.polynomials.rst +0 -0
  1306. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/routines.random.rst +0 -0
  1307. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/routines.rst +0 -0
  1308. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/routines.set.rst +0 -0
  1309. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/routines.testing.rst +0 -0
  1310. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/routines.window.rst +0 -0
  1311. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/reference/swig.rst +0 -0
  1312. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/user/basics.broadcasting.rst +0 -0
  1313. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/user/basics.byteswapping.rst +0 -0
  1314. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/user/basics.creation.rst +0 -0
  1315. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/user/basics.indexing.rst +0 -0
  1316. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/user/basics.io.rst +0 -0
  1317. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/user/basics.rst +0 -0
  1318. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/user/basics.subclassing.rst +0 -0
  1319. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/user/basics.types.rst +0 -0
  1320. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/user/c-info.rst +0 -0
  1321. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/user/howtofind.rst +0 -0
  1322. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/user/index.rst +0 -0
  1323. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/user/introduction.rst +0 -0
  1324. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/user/misc.rst +0 -0
  1325. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/user/performance.rst +0 -0
  1326. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/source/user/whatisnumpy.rst +0 -0
  1327. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/sphinxext/.git +0 -0
  1328. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/sphinxext/.gitignore +0 -0
  1329. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/sphinxext/.travis.yml +0 -0
  1330. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/sphinxext/LICENSE.txt +0 -0
  1331. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/sphinxext/MANIFEST.in +0 -0
  1332. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/sphinxext/README.rst +0 -0
  1333. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/sphinxext/numpydoc/__init__.py +0 -0
  1334. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/sphinxext/numpydoc/comment_eater.py +0 -0
  1335. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/sphinxext/numpydoc/compiler_unparse.py +0 -0
  1336. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/sphinxext/numpydoc/docscrape.py +0 -0
  1337. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/sphinxext/numpydoc/docscrape_sphinx.py +0 -0
  1338. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/sphinxext/numpydoc/linkcode.py +0 -0
  1339. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/sphinxext/numpydoc/numpydoc.py +0 -0
  1340. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/sphinxext/numpydoc/phantom_import.py +0 -0
  1341. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/sphinxext/numpydoc/plot_directive.py +0 -0
  1342. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/sphinxext/numpydoc/tests/test_docscrape.py +0 -0
  1343. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/sphinxext/numpydoc/tests/test_linkcode.py +0 -0
  1344. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/sphinxext/numpydoc/tests/test_phantom_import.py +0 -0
  1345. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/sphinxext/numpydoc/tests/test_plot_directive.py +0 -0
  1346. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/sphinxext/numpydoc/tests/test_traitsdoc.py +0 -0
  1347. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/sphinxext/numpydoc/traitsdoc.py +0 -0
  1348. {numpy-1.9.3 → numpy-1.10.0.post2}/doc/sphinxext/setup.py +0 -0
  1349. {numpy-1.9.3/numpy/core/code_generators → numpy-1.10.0.post2/numpy/_build_utils}/__init__.py +0 -0
  1350. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/compat/__init__.py +0 -0
  1351. {numpy-1.9.3/numpy/distutils/tests/f2py_ext → numpy-1.10.0.post2/numpy/core/code_generators}/__init__.py +0 -0
  1352. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/code_generators/genapi.py +0 -0
  1353. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/code_generators/generate_numpy_api.py +0 -0
  1354. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/cversions.py +0 -0
  1355. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/include/numpy/_neighborhood_iterator_imp.h +0 -0
  1356. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/include/numpy/_numpyconfig.h.in +0 -0
  1357. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/include/numpy/arrayobject.h +0 -0
  1358. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/include/numpy/arrayscalars.h +0 -0
  1359. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/include/numpy/halffloat.h +0 -0
  1360. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/include/numpy/noprefix.h +0 -0
  1361. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/include/numpy/npy_1_7_deprecated_api.h +0 -0
  1362. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/include/numpy/npy_interrupt.h +0 -0
  1363. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/include/numpy/npy_no_deprecated_api.h +0 -0
  1364. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/include/numpy/npy_os.h +0 -0
  1365. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/include/numpy/old_defines.h +0 -0
  1366. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/include/numpy/oldnumeric.h +0 -0
  1367. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/include/numpy/ufuncobject.h +0 -0
  1368. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/include/numpy/utils.h +0 -0
  1369. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/info.py +0 -0
  1370. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/mlib.ini.in +0 -0
  1371. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/npymath.ini.in +0 -0
  1372. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/dummymodule.c +0 -0
  1373. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/multiarray/_datetime.h +0 -0
  1374. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/multiarray/alloc.h +0 -0
  1375. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/multiarray/array_assign.c +0 -0
  1376. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/multiarray/array_assign.h +0 -0
  1377. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/multiarray/array_assign_array.c +0 -0
  1378. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/multiarray/array_assign_scalar.c +0 -0
  1379. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/multiarray/arrayobject.h +0 -0
  1380. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/multiarray/buffer.h +0 -0
  1381. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/multiarray/calculation.h +0 -0
  1382. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/multiarray/conversion_utils.h +0 -0
  1383. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/multiarray/convert.h +0 -0
  1384. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/multiarray/convert_datatype.h +0 -0
  1385. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/multiarray/ctors.h +0 -0
  1386. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/multiarray/datetime_busday.h +0 -0
  1387. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/multiarray/datetime_busdaycal.h +0 -0
  1388. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/multiarray/datetime_strings.h +0 -0
  1389. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/multiarray/descriptor.h +0 -0
  1390. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/multiarray/flagsobject.c +0 -0
  1391. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/multiarray/getset.h +0 -0
  1392. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/multiarray/hashdescr.h +0 -0
  1393. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/multiarray/item_selection.h +0 -0
  1394. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/multiarray/iterators.h +0 -0
  1395. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/multiarray/methods.h +0 -0
  1396. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/multiarray/nditer_impl.h +0 -0
  1397. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/multiarray/nditer_pywrap.h +0 -0
  1398. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/multiarray/nditer_templ.c.src +0 -0
  1399. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/multiarray/numpymemoryview.h +0 -0
  1400. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/multiarray/numpyos.h +0 -0
  1401. {numpy-1.9.3/numpy/core/blasdot → numpy-1.10.0.post2/numpy/core/src/multiarray}/python_xerbla.c +0 -0
  1402. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/multiarray/refcount.c +0 -0
  1403. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/multiarray/refcount.h +0 -0
  1404. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/multiarray/sequence.c +0 -0
  1405. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/multiarray/sequence.h +0 -0
  1406. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/multiarray/shape.h +0 -0
  1407. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/multiarray/ucsnarrow.h +0 -0
  1408. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/multiarray/usertypes.c +0 -0
  1409. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/multiarray/usertypes.h +0 -0
  1410. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/npymath/_signbit.c +0 -0
  1411. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/npymath/halffloat.c +0 -0
  1412. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/npymath/npy_math_common.h +0 -0
  1413. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/npysort/binsearch.c.src +0 -0
  1414. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/private/lowlevel_strided_loops.h +0 -0
  1415. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/private/npy_binsearch.h.src +0 -0
  1416. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/private/npy_fpmath.h +0 -0
  1417. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/private/npy_pycompat.h +0 -0
  1418. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/umath/reduction.c +0 -0
  1419. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/umath/reduction.h +0 -0
  1420. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/umath/struct_ufunc_test.c.src +0 -0
  1421. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/umath/ufunc_object.h +0 -0
  1422. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/src/umath/ufunc_type_resolution.h +0 -0
  1423. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/tests/data/astype_copy.pkl +0 -0
  1424. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/tests/data/recarray_from_file.fits +0 -0
  1425. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/core/tests/test_scalarprint.py +0 -0
  1426. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/ctypeslib.py +0 -0
  1427. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/__version__.py +0 -0
  1428. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/command/__init__.py +0 -0
  1429. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/command/bdist_rpm.py +0 -0
  1430. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/command/build_py.py +0 -0
  1431. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/command/build_scripts.py +0 -0
  1432. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/command/build_src.py +0 -0
  1433. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/command/config_compiler.py +0 -0
  1434. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/command/develop.py +0 -0
  1435. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/command/egg_info.py +0 -0
  1436. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/command/install.py +0 -0
  1437. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/command/install_clib.py +0 -0
  1438. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/command/install_data.py +0 -0
  1439. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/command/install_headers.py +0 -0
  1440. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/command/sdist.py +0 -0
  1441. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/compat.py +0 -0
  1442. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/conv_template.py +0 -0
  1443. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/core.py +0 -0
  1444. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/cpuinfo.py +0 -0
  1445. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/environment.py +0 -0
  1446. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/extension.py +0 -0
  1447. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/fcompiler/__init__.py +0 -0
  1448. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/fcompiler/absoft.py +0 -0
  1449. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/fcompiler/g95.py +0 -0
  1450. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/fcompiler/hpux.py +0 -0
  1451. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/fcompiler/ibm.py +0 -0
  1452. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/fcompiler/lahey.py +0 -0
  1453. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/fcompiler/mips.py +0 -0
  1454. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/fcompiler/nag.py +0 -0
  1455. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/fcompiler/none.py +0 -0
  1456. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/fcompiler/pathf95.py +0 -0
  1457. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/fcompiler/vast.py +0 -0
  1458. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/from_template.py +0 -0
  1459. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/info.py +0 -0
  1460. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/line_endings.py +0 -0
  1461. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/log.py +0 -0
  1462. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/mingw/gfortran_vs2003_hack.c +0 -0
  1463. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/numpy_distribution.py +0 -0
  1464. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/pathccompiler.py +0 -0
  1465. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/setup.py +0 -0
  1466. {numpy-1.9.3/numpy/distutils/tests/f2py_f90_ext → numpy-1.10.0.post2/numpy/distutils/tests/f2py_ext}/__init__.py +0 -0
  1467. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/tests/f2py_ext/setup.py +0 -0
  1468. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/tests/f2py_ext/src/fib1.f +0 -0
  1469. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/tests/f2py_ext/src/fib2.pyf +0 -0
  1470. {numpy-1.9.3/numpy/distutils/tests/gen_ext → numpy-1.10.0.post2/numpy/distutils/tests/f2py_f90_ext}/__init__.py +0 -0
  1471. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/tests/f2py_f90_ext/include/body.f90 +0 -0
  1472. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/tests/f2py_f90_ext/setup.py +0 -0
  1473. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/tests/f2py_f90_ext/src/foo_free.f90 +0 -0
  1474. {numpy-1.9.3/numpy/distutils/tests/pyrex_ext → numpy-1.10.0.post2/numpy/distutils/tests/gen_ext}/__init__.py +0 -0
  1475. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/tests/gen_ext/setup.py +0 -0
  1476. {numpy-1.9.3/numpy/distutils/tests/swig_ext → numpy-1.10.0.post2/numpy/distutils/tests/pyrex_ext}/__init__.py +0 -0
  1477. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/tests/pyrex_ext/primes.pyx +0 -0
  1478. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/tests/pyrex_ext/setup.py +0 -0
  1479. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/tests/setup.py +0 -0
  1480. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/tests/swig_ext/setup.py +0 -0
  1481. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/tests/swig_ext/src/example.c +0 -0
  1482. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/tests/swig_ext/src/example.i +0 -0
  1483. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/tests/swig_ext/src/zoo.cc +0 -0
  1484. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/tests/swig_ext/src/zoo.h +0 -0
  1485. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/tests/swig_ext/src/zoo.i +0 -0
  1486. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/distutils/tests/test_exec_command.py +0 -0
  1487. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/doc/__init__.py +0 -0
  1488. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/doc/basics.py +0 -0
  1489. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/doc/broadcasting.py +0 -0
  1490. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/doc/constants.py +0 -0
  1491. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/doc/howtofind.py +0 -0
  1492. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/doc/internals.py +0 -0
  1493. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/doc/io.py +0 -0
  1494. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/doc/jargon.py +0 -0
  1495. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/doc/methods_vs_functions.py +0 -0
  1496. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/doc/misc.py +0 -0
  1497. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/doc/performance.py +0 -0
  1498. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/doc/subclassing.py +0 -0
  1499. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/doc/ufuncs.py +0 -0
  1500. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/dual.py +0 -0
  1501. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/f2py/__version__.py +0 -0
  1502. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/f2py/info.py +0 -0
  1503. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/f2py/tests/src/assumed_shape/.f2py_f2cmap +0 -0
  1504. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/f2py/tests/src/assumed_shape/foo_free.f90 +0 -0
  1505. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/f2py/tests/src/assumed_shape/foo_mod.f90 +0 -0
  1506. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/f2py/tests/src/assumed_shape/foo_use.f90 +0 -0
  1507. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/f2py/tests/src/assumed_shape/precision.f90 +0 -0
  1508. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/f2py/tests/src/kind/foo.f90 +0 -0
  1509. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/f2py/tests/src/mixed/foo.f +0 -0
  1510. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/f2py/tests/src/mixed/foo_fixed.f90 +0 -0
  1511. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/f2py/tests/src/mixed/foo_free.f90 +0 -0
  1512. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/f2py/tests/src/regression/inout.f90 +0 -0
  1513. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/f2py/tests/src/size/foo.f90 +0 -0
  1514. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/fft/__init__.py +0 -0
  1515. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/fft/helper.py +0 -0
  1516. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/lib/__init__.py +0 -0
  1517. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/lib/_datasource.py +0 -0
  1518. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/lib/_version.py +0 -0
  1519. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/lib/scimath.py +0 -0
  1520. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/lib/tests/data/python3.npy +0 -0
  1521. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/lib/tests/data/win64python2.npy +0 -0
  1522. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/lib/tests/test__datasource.py +0 -0
  1523. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/lib/tests/test_arrayterator.py +0 -0
  1524. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/lib/tests/test_regression.py +0 -0
  1525. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/lib/tests/test_ufunclike.py +0 -0
  1526. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/lib/tests/test_utils.py +0 -0
  1527. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/lib/ufunclike.py +0 -0
  1528. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/lib/user_array.py +0 -0
  1529. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/linalg/__init__.py +0 -0
  1530. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/linalg/info.py +0 -0
  1531. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/linalg/lapack_lite/blas_lite.c +0 -0
  1532. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/linalg/lapack_lite/dlamch.c +0 -0
  1533. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/linalg/lapack_lite/dlapack_lite.c +0 -0
  1534. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/linalg/lapack_lite/f2c.h +0 -0
  1535. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/linalg/lapack_lite/f2c_lite.c +0 -0
  1536. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/linalg/lapack_lite/zlapack_lite.c +0 -0
  1537. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/linalg/setup.py +0 -0
  1538. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/linalg/tests/test_deprecations.py +0 -0
  1539. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/ma/version.py +0 -0
  1540. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/matrixlib/__init__.py +0 -0
  1541. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/matrixlib/setup.py +0 -0
  1542. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/polynomial/__init__.py +0 -0
  1543. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/polynomial/polynomial.py +0 -0
  1544. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/polynomial/setup.py +0 -0
  1545. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/polynomial/tests/test_chebyshev.py +0 -0
  1546. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/polynomial/tests/test_classes.py +0 -0
  1547. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/polynomial/tests/test_hermite.py +0 -0
  1548. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/polynomial/tests/test_hermite_e.py +0 -0
  1549. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/polynomial/tests/test_laguerre.py +0 -0
  1550. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/polynomial/tests/test_legendre.py +0 -0
  1551. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/polynomial/tests/test_polynomial.py +0 -0
  1552. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/polynomial/tests/test_polyutils.py +0 -0
  1553. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/polynomial/tests/test_printing.py +0 -0
  1554. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/random/__init__.py +0 -0
  1555. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/random/info.py +0 -0
  1556. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/random/mtrand/Python.pxi +0 -0
  1557. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/random/mtrand/distributions.h +0 -0
  1558. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/random/mtrand/generate_mtrand_c.py +0 -0
  1559. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/random/mtrand/initarray.c +0 -0
  1560. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/random/mtrand/initarray.h +0 -0
  1561. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/random/mtrand/mtrand_py_helper.h +0 -0
  1562. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/random/mtrand/numpy.pxd +0 -0
  1563. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/random/mtrand/randomkit.c +0 -0
  1564. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/random/mtrand/randomkit.h +0 -0
  1565. {numpy-1.9.3 → numpy-1.10.0.post2}/numpy/testing/tests/test_doctesting.py +0 -0
  1566. {numpy-1.9.3 → numpy-1.10.0.post2}/setupegg.py +0 -0
  1567. {numpy-1.9.3 → numpy-1.10.0.post2}/tools/swig/Makefile +0 -0
  1568. {numpy-1.9.3 → numpy-1.10.0.post2}/tools/swig/pyfragments.swg +0 -0
  1569. {numpy-1.9.3 → numpy-1.10.0.post2}/tools/swig/test/Array1.cxx +0 -0
  1570. {numpy-1.9.3 → numpy-1.10.0.post2}/tools/swig/test/Array1.h +0 -0
  1571. {numpy-1.9.3 → numpy-1.10.0.post2}/tools/swig/test/Array2.cxx +0 -0
  1572. {numpy-1.9.3 → numpy-1.10.0.post2}/tools/swig/test/Array2.h +0 -0
  1573. {numpy-1.9.3 → numpy-1.10.0.post2}/tools/swig/test/Farray.cxx +0 -0
  1574. {numpy-1.9.3 → numpy-1.10.0.post2}/tools/swig/test/Farray.h +0 -0
  1575. {numpy-1.9.3 → numpy-1.10.0.post2}/tools/swig/test/Farray.i +0 -0
  1576. {numpy-1.9.3 → numpy-1.10.0.post2}/tools/swig/test/Fortran.cxx +0 -0
  1577. {numpy-1.9.3 → numpy-1.10.0.post2}/tools/swig/test/Fortran.h +0 -0
  1578. {numpy-1.9.3 → numpy-1.10.0.post2}/tools/swig/test/Fortran.i +0 -0
  1579. {numpy-1.9.3 → numpy-1.10.0.post2}/tools/swig/test/Matrix.cxx +0 -0
  1580. {numpy-1.9.3 → numpy-1.10.0.post2}/tools/swig/test/Matrix.h +0 -0
  1581. {numpy-1.9.3 → numpy-1.10.0.post2}/tools/swig/test/Matrix.i +0 -0
  1582. {numpy-1.9.3 → numpy-1.10.0.post2}/tools/swig/test/SuperTensor.cxx +0 -0
  1583. {numpy-1.9.3 → numpy-1.10.0.post2}/tools/swig/test/SuperTensor.h +0 -0
  1584. {numpy-1.9.3 → numpy-1.10.0.post2}/tools/swig/test/SuperTensor.i +0 -0
  1585. {numpy-1.9.3 → numpy-1.10.0.post2}/tools/swig/test/Tensor.cxx +0 -0
  1586. {numpy-1.9.3 → numpy-1.10.0.post2}/tools/swig/test/Tensor.h +0 -0
  1587. {numpy-1.9.3 → numpy-1.10.0.post2}/tools/swig/test/Tensor.i +0 -0
  1588. {numpy-1.9.3 → numpy-1.10.0.post2}/tools/swig/test/Vector.cxx +0 -0
  1589. {numpy-1.9.3 → numpy-1.10.0.post2}/tools/swig/test/Vector.h +0 -0
  1590. {numpy-1.9.3 → numpy-1.10.0.post2}/tools/swig/test/Vector.i +0 -0
@@ -0,0 +1,4343 @@
1
+ /* -*- c -*- */
2
+ #define PY_SSIZE_T_CLEAN
3
+ #include "Python.h"
4
+ #include "structmember.h"
5
+
6
+ #define NPY_NO_DEPRECATED_API NPY_API_VERSION
7
+ #ifndef _MULTIARRAYMODULE
8
+ #define _MULTIARRAYMODULE
9
+ #endif
10
+
11
+ #include "numpy/arrayobject.h"
12
+ #include "numpy/npy_math.h"
13
+ #include "numpy/halffloat.h"
14
+ #include "numpy/arrayscalars.h"
15
+
16
+ #include "npy_pycompat.h"
17
+
18
+ #include "npy_config.h"
19
+ #include "mapping.h"
20
+ #include "ctors.h"
21
+ #include "usertypes.h"
22
+ #include "numpyos.h"
23
+ #include "common.h"
24
+ #include "scalartypes.h"
25
+ #include "_datetime.h"
26
+ #include "datetime_strings.h"
27
+
28
+ #include <stdlib.h>
29
+
30
+ NPY_NO_EXPORT PyBoolScalarObject _PyArrayScalar_BoolValues[] = {
31
+ {PyObject_HEAD_INIT(&PyBoolArrType_Type) 0},
32
+ {PyObject_HEAD_INIT(&PyBoolArrType_Type) 1},
33
+ };
34
+
35
+ /* TimeInteger is deleted, but still here to fill the API slot */
36
+ NPY_NO_EXPORT PyTypeObject PyTimeIntegerArrType_Type;
37
+
38
+ /*
39
+ * Inheritance is established later when tp_bases is set (or tp_base for
40
+ * single inheritance)
41
+ */
42
+
43
+ /**begin repeat
44
+ * #name = number, integer, signedinteger, unsignedinteger, inexact,
45
+ * floating, complexfloating, flexible, character#
46
+ * #NAME = Number, Integer, SignedInteger, UnsignedInteger, Inexact,
47
+ * Floating, ComplexFloating, Flexible, Character#
48
+ */
49
+ NPY_NO_EXPORT PyTypeObject Py@NAME@ArrType_Type = {
50
+ #if defined(NPY_PY3K)
51
+ PyVarObject_HEAD_INIT(NULL, 0)
52
+ #else
53
+ PyObject_HEAD_INIT(NULL)
54
+ 0, /* ob_size */
55
+ #endif
56
+ "numpy.@name@", /* tp_name*/
57
+ sizeof(PyObject), /* tp_basicsize*/
58
+ 0, /* tp_itemsize */
59
+ /* methods */
60
+ 0, /* tp_dealloc */
61
+ 0, /* tp_print */
62
+ 0, /* tp_getattr */
63
+ 0, /* tp_setattr */
64
+ #if defined(NPY_PY3K)
65
+ 0, /* tp_reserved */
66
+ #else
67
+ 0, /* tp_compare */
68
+ #endif
69
+ 0, /* tp_repr */
70
+ 0, /* tp_as_number */
71
+ 0, /* tp_as_sequence */
72
+ 0, /* tp_as_mapping */
73
+ 0, /* tp_hash */
74
+ 0, /* tp_call */
75
+ 0, /* tp_str */
76
+ 0, /* tp_getattro */
77
+ 0, /* tp_setattro */
78
+ 0, /* tp_as_buffer */
79
+ 0, /* tp_flags */
80
+ 0, /* tp_doc */
81
+ 0, /* tp_traverse */
82
+ 0, /* tp_clear */
83
+ 0, /* tp_richcompare */
84
+ 0, /* tp_weaklistoffset */
85
+ 0, /* tp_iter */
86
+ 0, /* tp_iternext */
87
+ 0, /* tp_methods */
88
+ 0, /* tp_members */
89
+ 0, /* tp_getset */
90
+ 0, /* tp_base */
91
+ 0, /* tp_dict */
92
+ 0, /* tp_descr_get */
93
+ 0, /* tp_descr_set */
94
+ 0, /* tp_dictoffset */
95
+ 0, /* tp_init */
96
+ 0, /* tp_alloc */
97
+ 0, /* tp_new */
98
+ 0, /* tp_free */
99
+ 0, /* tp_is_gc */
100
+ 0, /* tp_bases */
101
+ 0, /* tp_mro */
102
+ 0, /* tp_cache */
103
+ 0, /* tp_subclasses */
104
+ 0, /* tp_weaklist */
105
+ 0, /* tp_del */
106
+ 0, /* tp_version_tag */
107
+ };
108
+ /**end repeat**/
109
+
110
+ static PyObject *
111
+ gentype_alloc(PyTypeObject *type, Py_ssize_t nitems)
112
+ {
113
+ PyObject *obj;
114
+ const size_t size = _PyObject_VAR_SIZE(type, nitems + 1);
115
+
116
+ obj = (PyObject *)PyObject_Malloc(size);
117
+ /*
118
+ * Fixme. Need to check for no memory.
119
+ * If we don't need to zero memory, we could use
120
+ * PyObject_{New, NewVar} for this whole function.
121
+ */
122
+ memset(obj, 0, size);
123
+ if (type->tp_itemsize == 0) {
124
+ PyObject_Init(obj, type);
125
+ }
126
+ else {
127
+ (void) PyObject_InitVar((PyVarObject *)obj, type, nitems);
128
+ }
129
+ return obj;
130
+ }
131
+
132
+ static void
133
+ gentype_dealloc(PyObject *v)
134
+ {
135
+ Py_TYPE(v)->tp_free(v);
136
+ }
137
+
138
+ static void
139
+ gentype_free(PyObject *v)
140
+ {
141
+ /*
142
+ * have an explicit tp_free to enforce inheritance from it.
143
+ * PyObject_Free is also the tp_free of PyBaseObject so python does not
144
+ * COPYSLOT it, instead it takes the next parent PyInt which has a
145
+ * different allocator
146
+ */
147
+ PyObject_Free(v);
148
+ }
149
+
150
+
151
+ static PyObject *
152
+ gentype_power(PyObject *m1, PyObject *m2, PyObject *NPY_UNUSED(m3))
153
+ {
154
+ PyObject *arr, *ret, *arg2;
155
+ char *msg="unsupported operand type(s) for ** or pow()";
156
+
157
+ if (!PyArray_IsScalar(m1, Generic)) {
158
+ if (PyArray_Check(m1)) {
159
+ ret = Py_TYPE(m1)->tp_as_number->nb_power(m1,m2, Py_None);
160
+ }
161
+ else {
162
+ if (!PyArray_IsScalar(m2, Generic)) {
163
+ PyErr_SetString(PyExc_TypeError, msg);
164
+ return NULL;
165
+ }
166
+ arr = PyArray_FromScalar(m2, NULL);
167
+ if (arr == NULL) {
168
+ return NULL;
169
+ }
170
+ ret = Py_TYPE(arr)->tp_as_number->nb_power(m1, arr, Py_None);
171
+ Py_DECREF(arr);
172
+ }
173
+ return ret;
174
+ }
175
+ if (!PyArray_IsScalar(m2, Generic)) {
176
+ if (PyArray_Check(m2)) {
177
+ ret = Py_TYPE(m2)->tp_as_number->nb_power(m1,m2, Py_None);
178
+ }
179
+ else {
180
+ if (!PyArray_IsScalar(m1, Generic)) {
181
+ PyErr_SetString(PyExc_TypeError, msg);
182
+ return NULL;
183
+ }
184
+ arr = PyArray_FromScalar(m1, NULL);
185
+ if (arr == NULL) {
186
+ return NULL;
187
+ }
188
+ ret = Py_TYPE(arr)->tp_as_number->nb_power(arr, m2, Py_None);
189
+ Py_DECREF(arr);
190
+ }
191
+ return ret;
192
+ }
193
+ arr = arg2 = NULL;
194
+ arr = PyArray_FromScalar(m1, NULL);
195
+ arg2 = PyArray_FromScalar(m2, NULL);
196
+ if (arr == NULL || arg2 == NULL) {
197
+ Py_XDECREF(arr);
198
+ Py_XDECREF(arg2);
199
+ return NULL;
200
+ }
201
+ ret = Py_TYPE(arr)->tp_as_number->nb_power(arr, arg2, Py_None);
202
+ Py_DECREF(arr);
203
+ Py_DECREF(arg2);
204
+ return ret;
205
+ }
206
+
207
+ static PyObject *
208
+ gentype_generic_method(PyObject *self, PyObject *args, PyObject *kwds,
209
+ char *str)
210
+ {
211
+ PyObject *arr, *meth, *ret;
212
+
213
+ arr = PyArray_FromScalar(self, NULL);
214
+ if (arr == NULL) {
215
+ return NULL;
216
+ }
217
+ meth = PyObject_GetAttrString(arr, str);
218
+ if (meth == NULL) {
219
+ Py_DECREF(arr);
220
+ return NULL;
221
+ }
222
+ if (kwds == NULL) {
223
+ ret = PyObject_CallObject(meth, args);
224
+ }
225
+ else {
226
+ ret = PyObject_Call(meth, args, kwds);
227
+ }
228
+ Py_DECREF(meth);
229
+ Py_DECREF(arr);
230
+ if (ret && PyArray_Check(ret)) {
231
+ return PyArray_Return((PyArrayObject *)ret);
232
+ }
233
+ else {
234
+ return ret;
235
+ }
236
+ }
237
+
238
+ /**begin repeat
239
+ *
240
+ * #name = add, subtract, remainder, divmod, lshift, rshift,
241
+ * and, xor, or, floor_divide, true_divide#
242
+ */
243
+ static PyObject *
244
+ gentype_@name@(PyObject *m1, PyObject *m2)
245
+ {
246
+ return PyArray_Type.tp_as_number->nb_@name@(m1, m2);
247
+ }
248
+
249
+ /**end repeat**/
250
+
251
+ #if !defined(NPY_PY3K)
252
+ /**begin repeat
253
+ *
254
+ * #name = divide#
255
+ */
256
+ static PyObject *
257
+ gentype_@name@(PyObject *m1, PyObject *m2)
258
+ {
259
+ return PyArray_Type.tp_as_number->nb_@name@(m1, m2);
260
+ }
261
+ /**end repeat**/
262
+ #endif
263
+
264
+ static PyObject *
265
+ gentype_multiply(PyObject *m1, PyObject *m2)
266
+ {
267
+ PyObject *ret = NULL;
268
+ npy_intp repeat;
269
+
270
+ if (!PyArray_IsScalar(m1, Generic) &&
271
+ ((Py_TYPE(m1)->tp_as_number == NULL) ||
272
+ (Py_TYPE(m1)->tp_as_number->nb_multiply == NULL))) {
273
+ /* Try to convert m2 to an int and try sequence repeat */
274
+ repeat = PyArray_PyIntAsIntp(m2);
275
+ if (repeat == -1 && PyErr_Occurred()) {
276
+ return NULL;
277
+ }
278
+ /* Note that npy_intp is compatible to Py_Ssize_t */
279
+ ret = PySequence_Repeat(m1, repeat);
280
+ }
281
+ else if (!PyArray_IsScalar(m2, Generic) &&
282
+ ((Py_TYPE(m2)->tp_as_number == NULL) ||
283
+ (Py_TYPE(m2)->tp_as_number->nb_multiply == NULL))) {
284
+ /* Try to convert m1 to an int and try sequence repeat */
285
+ repeat = PyArray_PyIntAsIntp(m1);
286
+ if (repeat == -1 && PyErr_Occurred()) {
287
+ return NULL;
288
+ }
289
+ ret = PySequence_Repeat(m2, repeat);
290
+ }
291
+ if (ret == NULL) {
292
+ PyErr_Clear(); /* no effect if not set */
293
+ ret = PyArray_Type.tp_as_number->nb_multiply(m1, m2);
294
+ }
295
+ return ret;
296
+ }
297
+
298
+ /**begin repeat
299
+ *
300
+ * #name = positive, negative, absolute, invert, int, float#
301
+ */
302
+ static PyObject *
303
+ gentype_@name@(PyObject *m1)
304
+ {
305
+ PyObject *arr, *ret;
306
+
307
+ arr = PyArray_FromScalar(m1, NULL);
308
+ if (arr == NULL) {
309
+ return NULL;
310
+ }
311
+ ret = Py_TYPE(arr)->tp_as_number->nb_@name@(arr);
312
+ Py_DECREF(arr);
313
+ return ret;
314
+ }
315
+ /**end repeat**/
316
+
317
+ #if !defined(NPY_PY3K)
318
+ /**begin repeat
319
+ *
320
+ * #name = long, oct, hex#
321
+ */
322
+ static PyObject *
323
+ gentype_@name@(PyObject *m1)
324
+ {
325
+ PyObject *arr, *ret;
326
+
327
+ arr = PyArray_FromScalar(m1, NULL);
328
+ if (arr == NULL) {
329
+ return NULL;
330
+ }
331
+ ret = Py_TYPE(arr)->tp_as_number->nb_@name@(arr);
332
+ Py_DECREF(arr);
333
+ return ret;
334
+ }
335
+ /**end repeat**/
336
+ #endif
337
+
338
+ static int
339
+ gentype_nonzero_number(PyObject *m1)
340
+ {
341
+ PyObject *arr;
342
+ int ret;
343
+
344
+ arr = PyArray_FromScalar(m1, NULL);
345
+ if (arr == NULL) {
346
+ return -1;
347
+ }
348
+ #if defined(NPY_PY3K)
349
+ ret = Py_TYPE(arr)->tp_as_number->nb_bool(arr);
350
+ #else
351
+ ret = Py_TYPE(arr)->tp_as_number->nb_nonzero(arr);
352
+ #endif
353
+ Py_DECREF(arr);
354
+ return ret;
355
+ }
356
+
357
+ static PyObject *
358
+ gentype_str(PyObject *self)
359
+ {
360
+ PyObject *arr, *ret = NULL;
361
+
362
+ arr = PyArray_FromScalar(self, NULL);
363
+ if (arr != NULL) {
364
+ ret = PyObject_Str((PyObject *)arr);
365
+ Py_DECREF(arr);
366
+ }
367
+ return ret;
368
+ }
369
+
370
+
371
+ static PyObject *
372
+ gentype_repr(PyObject *self)
373
+ {
374
+ PyObject *arr, *ret = NULL;
375
+
376
+ arr = PyArray_FromScalar(self, NULL);
377
+ if (arr != NULL) {
378
+ /* XXX: Why are we using str here? */
379
+ ret = PyObject_Str((PyObject *)arr);
380
+ Py_DECREF(arr);
381
+ }
382
+ return ret;
383
+ }
384
+
385
+ /*
386
+ * The __format__ method for PEP 3101.
387
+ */
388
+ static PyObject *
389
+ gentype_format(PyObject *self, PyObject *args)
390
+ {
391
+ PyObject *format_spec;
392
+ PyObject *obj, *ret;
393
+
394
+ #if defined(NPY_PY3K)
395
+ if (!PyArg_ParseTuple(args, "U:__format__", &format_spec)) {
396
+ return NULL;
397
+ }
398
+ #else
399
+ if (!PyArg_ParseTuple(args, "O:__format__", &format_spec)) {
400
+ return NULL;
401
+ }
402
+
403
+ if (!PyUnicode_Check(format_spec) && !PyString_Check(format_spec)) {
404
+ PyErr_SetString(PyExc_TypeError,
405
+ "format must be a string");
406
+ return NULL;
407
+ }
408
+ #endif
409
+
410
+ /*
411
+ * Convert to an appropriate Python type and call its format.
412
+ * TODO: For some types, like long double, this isn't right,
413
+ * because it throws away precision.
414
+ */
415
+ if (Py_TYPE(self) == &PyBoolArrType_Type) {
416
+ obj = PyBool_FromLong(((PyBoolScalarObject *)self)->obval);
417
+ }
418
+ else if (PyArray_IsScalar(self, Integer)) {
419
+ #if defined(NPY_PY3K)
420
+ obj = Py_TYPE(self)->tp_as_number->nb_int(self);
421
+ #else
422
+ obj = Py_TYPE(self)->tp_as_number->nb_long(self);
423
+ #endif
424
+ }
425
+ else if (PyArray_IsScalar(self, Floating)) {
426
+ obj = Py_TYPE(self)->tp_as_number->nb_float(self);
427
+ }
428
+ else if (PyArray_IsScalar(self, ComplexFloating)) {
429
+ double val[2];
430
+ PyArray_Descr *dtype = PyArray_DescrFromScalar(self);
431
+
432
+ if (dtype == NULL) {
433
+ return NULL;
434
+ }
435
+ if (PyArray_CastScalarDirect(self, dtype, &val[0], NPY_CDOUBLE) < 0) {
436
+ Py_DECREF(dtype);
437
+ return NULL;
438
+ }
439
+ obj = PyComplex_FromDoubles(val[0], val[1]);
440
+ Py_DECREF(dtype);
441
+ }
442
+ else {
443
+ obj = PyObject_Str(self);
444
+ }
445
+
446
+ if (obj == NULL) {
447
+ return NULL;
448
+ }
449
+
450
+ ret = PyObject_Format(obj, format_spec);
451
+ Py_DECREF(obj);
452
+ return ret;
453
+ }
454
+
455
+ #ifdef FORCE_NO_LONG_DOUBLE_FORMATTING
456
+ #undef NPY_LONGDOUBLE_FMT
457
+ #define NPY_LONGDOUBLE_FMT NPY_DOUBLE_FMT
458
+ #endif
459
+
460
+ /**begin repeat
461
+ * #name = float, double, longdouble#
462
+ * #NAME = FLOAT, DOUBLE, LONGDOUBLE#
463
+ * #type = npy_float, npy_double, npy_longdouble#
464
+ * #suff = f, d, l#
465
+ */
466
+
467
+ #define _FMT1 "%%.%i" NPY_@NAME@_FMT
468
+ #define _FMT2 "%%+.%i" NPY_@NAME@_FMT
469
+
470
+ NPY_NO_EXPORT void
471
+ format_@name@(char *buf, size_t buflen, @type@ val, unsigned int prec)
472
+ {
473
+ /* XXX: Find a correct size here for format string */
474
+ char format[64], *res;
475
+ size_t i, cnt;
476
+
477
+ PyOS_snprintf(format, sizeof(format), _FMT1, prec);
478
+ res = NumPyOS_ascii_format@suff@(buf, buflen, format, val, 0);
479
+ if (res == NULL) {
480
+ fprintf(stderr, "Error while formatting\n");
481
+ return;
482
+ }
483
+
484
+ /* If nothing but digits after sign, append ".0" */
485
+ cnt = strlen(buf);
486
+ for (i = (buf[0] == '-') ? 1 : 0; i < cnt; ++i) {
487
+ if (!isdigit(Py_CHARMASK(buf[i]))) {
488
+ break;
489
+ }
490
+ }
491
+ if (i == cnt && buflen >= cnt + 3) {
492
+ strcpy(&buf[cnt],".0");
493
+ }
494
+ }
495
+
496
+ #undef _FMT1
497
+ #undef _FMT2
498
+
499
+ /**end repeat**/
500
+
501
+ /**begin repeat
502
+ * #name = cfloat, cdouble, clongdouble#
503
+ * #NAME = FLOAT, DOUBLE, LONGDOUBLE#
504
+ * #type = npy_cfloat, npy_cdouble, npy_clongdouble#
505
+ * #suff = f, d, l#
506
+ */
507
+
508
+ #define _FMT1 "%%.%i" NPY_@NAME@_FMT
509
+ #define _FMT2 "%%+.%i" NPY_@NAME@_FMT
510
+
511
+ static void
512
+ format_@name@(char *buf, size_t buflen, @type@ val, unsigned int prec)
513
+ {
514
+ /* XXX: Find a correct size here for format string */
515
+ char format[64];
516
+ char *res;
517
+
518
+ /*
519
+ * Ideally, we should handle this nan/inf stuff in NumpyOS_ascii_format*
520
+ */
521
+ #if PY_VERSION_HEX >= 0x02070000
522
+ if (val.real == 0.0 && npy_signbit(val.real) == 0) {
523
+ #else
524
+ if (val.real == 0.0) {
525
+ #endif
526
+ PyOS_snprintf(format, sizeof(format), _FMT1, prec);
527
+ res = NumPyOS_ascii_format@suff@(buf, buflen - 1, format, val.imag, 0);
528
+ if (res == NULL) {
529
+ /* FIXME
530
+ * We need a better way to handle the error message
531
+ */
532
+ fprintf(stderr, "Error while formatting\n");
533
+ return;
534
+ }
535
+ if (!npy_isfinite(val.imag)) {
536
+ strncat(buf, "*", 1);
537
+ }
538
+ strncat(buf, "j", 1);
539
+ }
540
+ else {
541
+ char re[64], im[64];
542
+ if (npy_isfinite(val.real)) {
543
+ PyOS_snprintf(format, sizeof(format), _FMT1, prec);
544
+ res = NumPyOS_ascii_format@suff@(re, sizeof(re), format,
545
+ val.real, 0);
546
+ if (res == NULL) {
547
+ /* FIXME
548
+ * We need a better way to handle the error message
549
+ */
550
+ fprintf(stderr, "Error while formatting\n");
551
+ return;
552
+ }
553
+ }
554
+ else {
555
+ if (npy_isnan(val.real)) {
556
+ strcpy(re, "nan");
557
+ }
558
+ else if (val.real > 0){
559
+ strcpy(re, "inf");
560
+ }
561
+ else {
562
+ strcpy(re, "-inf");
563
+ }
564
+ }
565
+
566
+
567
+ if (npy_isfinite(val.imag)) {
568
+ PyOS_snprintf(format, sizeof(format), _FMT2, prec);
569
+ res = NumPyOS_ascii_format@suff@(im, sizeof(im), format,
570
+ val.imag, 0);
571
+ if (res == NULL) {
572
+ fprintf(stderr, "Error while formatting\n");
573
+ return;
574
+ }
575
+ }
576
+ else {
577
+ if (npy_isnan(val.imag)) {
578
+ strcpy(im, "+nan");
579
+ }
580
+ else if (val.imag > 0){
581
+ strcpy(im, "+inf");
582
+ }
583
+ else {
584
+ strcpy(im, "-inf");
585
+ }
586
+ if (!npy_isfinite(val.imag)) {
587
+ strncat(im, "*", 1);
588
+ }
589
+ }
590
+ PyOS_snprintf(buf, buflen, "(%s%sj)", re, im);
591
+ }
592
+ }
593
+
594
+ #undef _FMT1
595
+ #undef _FMT2
596
+
597
+ /**end repeat**/
598
+
599
+ NPY_NO_EXPORT void
600
+ format_half(char *buf, size_t buflen, npy_half val, unsigned int prec)
601
+ {
602
+ format_float(buf, buflen, npy_half_to_float(val), prec);
603
+ }
604
+
605
+ /*
606
+ * over-ride repr and str of array-scalar strings and unicode to
607
+ * remove NULL bytes and then call the corresponding functions
608
+ * of string and unicode.
609
+ */
610
+
611
+ /**begin repeat
612
+ * #name = string*2,unicode*2#
613
+ * #form = (repr,str)*2#
614
+ * #Name = String*2,Unicode*2#
615
+ * #NAME = STRING*2,UNICODE*2#
616
+ * #extra = AndSize*2,,#
617
+ * #type = npy_char*2, Py_UNICODE*2#
618
+ */
619
+ static PyObject *
620
+ @name@type_@form@(PyObject *self)
621
+ {
622
+ const @type@ *dptr, *ip;
623
+ int len;
624
+ PyObject *new;
625
+ PyObject *ret;
626
+
627
+ ip = dptr = Py@Name@_AS_@NAME@(self);
628
+ len = Py@Name@_GET_SIZE(self);
629
+ dptr += len-1;
630
+ while(len > 0 && *dptr-- == 0) {
631
+ len--;
632
+ }
633
+ new = Py@Name@_From@Name@@extra@(ip, len);
634
+ if (new == NULL) {
635
+ return PyUString_FromString("");
636
+ }
637
+ ret = Py@Name@_Type.tp_@form@(new);
638
+ Py_DECREF(new);
639
+ return ret;
640
+ }
641
+ /**end repeat**/
642
+
643
+ static PyObject *
644
+ datetimetype_repr(PyObject *self)
645
+ {
646
+ PyDatetimeScalarObject *scal;
647
+ npy_datetimestruct dts;
648
+ PyObject *ret;
649
+ char iso[NPY_DATETIME_MAX_ISO8601_STRLEN];
650
+ int local;
651
+ NPY_DATETIMEUNIT unit;
652
+
653
+ if (!PyArray_IsScalar(self, Datetime)) {
654
+ PyErr_SetString(PyExc_RuntimeError,
655
+ "Called NumPy datetime repr on a non-datetime type");
656
+ return NULL;
657
+ }
658
+
659
+ scal = (PyDatetimeScalarObject *)self;
660
+
661
+ if (convert_datetime_to_datetimestruct(&scal->obmeta,
662
+ scal->obval, &dts) < 0) {
663
+ return NULL;
664
+ }
665
+
666
+ local = (scal->obmeta.base > NPY_FR_D);
667
+ /*
668
+ * Because we're defaulting to local time, display hours with
669
+ * minutes precision, so that 30-minute timezone offsets can work.
670
+ */
671
+ unit = scal->obmeta.base;
672
+ if (unit == NPY_FR_h) {
673
+ unit = NPY_FR_m;
674
+ }
675
+ if (make_iso_8601_datetime(&dts, iso, sizeof(iso), local,
676
+ unit, -1, NPY_SAFE_CASTING) < 0) {
677
+ return NULL;
678
+ }
679
+
680
+ /*
681
+ * For straight units or generic units, the unit will be deduced
682
+ * from the string, so it's not necessary to specify it.
683
+ */
684
+ if ((scal->obmeta.num == 1 && scal->obmeta.base != NPY_FR_h) ||
685
+ scal->obmeta.base == NPY_FR_GENERIC) {
686
+ ret = PyUString_FromString("numpy.datetime64('");
687
+ PyUString_ConcatAndDel(&ret,
688
+ PyUString_FromString(iso));
689
+ PyUString_ConcatAndDel(&ret,
690
+ PyUString_FromString("')"));
691
+ }
692
+ else {
693
+ ret = PyUString_FromString("numpy.datetime64('");
694
+ PyUString_ConcatAndDel(&ret,
695
+ PyUString_FromString(iso));
696
+ PyUString_ConcatAndDel(&ret,
697
+ PyUString_FromString("','"));
698
+ ret = append_metastr_to_string(&scal->obmeta, 1, ret);
699
+ PyUString_ConcatAndDel(&ret,
700
+ PyUString_FromString("')"));
701
+ }
702
+
703
+ return ret;
704
+ }
705
+
706
+ static PyObject *
707
+ timedeltatype_repr(PyObject *self)
708
+ {
709
+ PyTimedeltaScalarObject *scal;
710
+ PyObject *ret;
711
+
712
+ if (!PyArray_IsScalar(self, Timedelta)) {
713
+ PyErr_SetString(PyExc_RuntimeError,
714
+ "Called NumPy timedelta repr on a non-datetime type");
715
+ return NULL;
716
+ }
717
+
718
+ scal = (PyTimedeltaScalarObject *)self;
719
+
720
+ /* The value */
721
+ if (scal->obval == NPY_DATETIME_NAT) {
722
+ ret = PyUString_FromString("numpy.timedelta64('NaT'");
723
+ }
724
+ else {
725
+ /*
726
+ * Can't use "%lld" in Python < 2.7, Python3 < 3.2,
727
+ * or if HAVE_LONG_LONG is not defined
728
+ */
729
+ #if defined(HAVE_LONG_LONG) && \
730
+ ((PY_VERSION_HEX >= 0x02070000 && PY_VERSION_HEX < 0x03000000) || \
731
+ (PY_VERSION_HEX >= 0x03020000))
732
+ ret = PyUString_FromFormat("numpy.timedelta64(%lld",
733
+ (long long)scal->obval);
734
+ #else
735
+ ret = PyUString_FromFormat("numpy.timedelta64(%ld",
736
+ (long)scal->obval);
737
+ #endif
738
+ }
739
+ /* The metadata unit */
740
+ if (scal->obmeta.base == NPY_FR_GENERIC) {
741
+ PyUString_ConcatAndDel(&ret,
742
+ PyUString_FromString(")"));
743
+ }
744
+ else {
745
+ PyUString_ConcatAndDel(&ret,
746
+ PyUString_FromString(",'"));
747
+ ret = append_metastr_to_string(&scal->obmeta, 1, ret);
748
+ PyUString_ConcatAndDel(&ret,
749
+ PyUString_FromString("')"));
750
+ }
751
+
752
+ return ret;
753
+ }
754
+
755
+ static PyObject *
756
+ datetimetype_str(PyObject *self)
757
+ {
758
+ PyDatetimeScalarObject *scal;
759
+ npy_datetimestruct dts;
760
+ char iso[NPY_DATETIME_MAX_ISO8601_STRLEN];
761
+ int local;
762
+ NPY_DATETIMEUNIT unit;
763
+
764
+ if (!PyArray_IsScalar(self, Datetime)) {
765
+ PyErr_SetString(PyExc_RuntimeError,
766
+ "Called NumPy datetime str on a non-datetime type");
767
+ return NULL;
768
+ }
769
+
770
+ scal = (PyDatetimeScalarObject *)self;
771
+
772
+ if (convert_datetime_to_datetimestruct(&scal->obmeta, scal->obval,
773
+ &dts) < 0) {
774
+ return NULL;
775
+ }
776
+
777
+ local = (scal->obmeta.base > NPY_FR_D);
778
+ /*
779
+ * Because we're defaulting to local time, display hours with
780
+ * minutes precision, so that 30-minute timezone offsets can work.
781
+ */
782
+ unit = scal->obmeta.base;
783
+ if (unit == NPY_FR_h) {
784
+ unit = NPY_FR_m;
785
+ }
786
+ if (make_iso_8601_datetime(&dts, iso, sizeof(iso), local,
787
+ unit, -1, NPY_SAFE_CASTING) < 0) {
788
+ return NULL;
789
+ }
790
+
791
+ return PyUString_FromString(iso);
792
+ }
793
+
794
+ static char *_datetime_verbose_strings[NPY_DATETIME_NUMUNITS] = {
795
+ "years",
796
+ "months",
797
+ "weeks",
798
+ "<invalid>",
799
+ "days",
800
+ "hours",
801
+ "minutes",
802
+ "seconds",
803
+ "milliseconds",
804
+ "microseconds",
805
+ "nanoseconds",
806
+ "picoseconds",
807
+ "femtoseconds",
808
+ "attoseconds",
809
+ "generic time units"
810
+ };
811
+
812
+ static PyObject *
813
+ timedeltatype_str(PyObject *self)
814
+ {
815
+ PyTimedeltaScalarObject *scal;
816
+ PyObject *ret;
817
+ char *basestr = "invalid";
818
+
819
+ if (!PyArray_IsScalar(self, Timedelta)) {
820
+ PyErr_SetString(PyExc_RuntimeError,
821
+ "Called NumPy timedelta str on a non-datetime type");
822
+ return NULL;
823
+ }
824
+
825
+ scal = (PyTimedeltaScalarObject *)self;
826
+
827
+ if (scal->obmeta.base >= 0 && scal->obmeta.base < NPY_DATETIME_NUMUNITS) {
828
+ basestr = _datetime_verbose_strings[scal->obmeta.base];
829
+ }
830
+ else {
831
+ PyErr_SetString(PyExc_RuntimeError,
832
+ "NumPy datetime metadata is corrupted");
833
+ return NULL;
834
+ }
835
+
836
+ if (scal->obval == NPY_DATETIME_NAT) {
837
+ ret = PyUString_FromString("NaT");
838
+ }
839
+ else {
840
+ /*
841
+ * Can't use "%lld" in Python < 2.7, Python3 < 3.2,
842
+ * or if HAVE_LONG_LONG is not defined
843
+ */
844
+ #if defined(HAVE_LONG_LONG) && \
845
+ ((PY_VERSION_HEX >= 0x02070000 && PY_VERSION_HEX < 0x03000000) || \
846
+ (PY_VERSION_HEX >= 0x03020000))
847
+ ret = PyUString_FromFormat("%lld ",
848
+ (long long)(scal->obval * scal->obmeta.num));
849
+ #else
850
+ ret = PyUString_FromFormat("%ld ",
851
+ (long)(scal->obval * scal->obmeta.num));
852
+ #endif
853
+ PyUString_ConcatAndDel(&ret,
854
+ PyUString_FromString(basestr));
855
+ }
856
+
857
+ return ret;
858
+ }
859
+
860
+ /* The REPR values are finfo.precision + 2 */
861
+ #define HALFPREC_REPR 5
862
+ #define HALFPREC_STR 5
863
+ #define FLOATPREC_REPR 8
864
+ #define FLOATPREC_STR 6
865
+ #define DOUBLEPREC_REPR 17
866
+ #define DOUBLEPREC_STR 12
867
+ #if NPY_SIZEOF_LONGDOUBLE == NPY_SIZEOF_DOUBLE
868
+ #define LONGDOUBLEPREC_REPR DOUBLEPREC_REPR
869
+ #define LONGDOUBLEPREC_STR DOUBLEPREC_STR
870
+ #else /* More than probably needed on Intel FP */
871
+ #define LONGDOUBLEPREC_REPR 20
872
+ #define LONGDOUBLEPREC_STR 12
873
+ #endif
874
+
875
+ /*
876
+ * float type str and repr
877
+ *
878
+ * These functions will return NULL if PyString creation fails.
879
+ */
880
+
881
+ /**begin repeat
882
+ * #name = half, float, double, longdouble#
883
+ * #Name = Half, Float, Double, LongDouble#
884
+ * #NAME = HALF, FLOAT, DOUBLE, LONGDOUBLE#
885
+ * #hascomplex = 0, 1, 1, 1#
886
+ */
887
+ /**begin repeat1
888
+ * #kind = str, repr#
889
+ * #KIND = STR, REPR#
890
+ */
891
+
892
+ #define PREC @NAME@PREC_@KIND@
893
+
894
+ static PyObject *
895
+ @name@type_@kind@(PyObject *self)
896
+ {
897
+ char buf[100];
898
+ npy_@name@ val = ((Py@Name@ScalarObject *)self)->obval;
899
+
900
+ format_@name@(buf, sizeof(buf), val, PREC);
901
+ return PyUString_FromString(buf);
902
+ }
903
+
904
+ #if @hascomplex@
905
+ static PyObject *
906
+ c@name@type_@kind@(PyObject *self)
907
+ {
908
+ char buf[202];
909
+ npy_c@name@ val = ((PyC@Name@ScalarObject *)self)->obval;
910
+
911
+ format_c@name@(buf, sizeof(buf), val, PREC);
912
+ return PyUString_FromString(buf);
913
+ }
914
+ #endif
915
+
916
+ #undef PREC
917
+
918
+ /**end repeat1**/
919
+ /**end repeat**/
920
+
921
+ /*
922
+ * float type print (control print a, where a is a float type instance)
923
+ */
924
+ /**begin repeat
925
+ * #name = half, float, double, longdouble#
926
+ * #Name = Half, Float, Double, LongDouble#
927
+ * #NAME = HALF, FLOAT, DOUBLE, LONGDOUBLE#
928
+ * #hascomplex = 0, 1, 1, 1#
929
+ */
930
+
931
+ static int
932
+ @name@type_print(PyObject *v, FILE *fp, int flags)
933
+ {
934
+ char buf[100];
935
+ npy_@name@ val = ((Py@Name@ScalarObject *)v)->obval;
936
+
937
+ format_@name@(buf, sizeof(buf), val,
938
+ (flags & Py_PRINT_RAW) ? @NAME@PREC_STR : @NAME@PREC_REPR);
939
+ Py_BEGIN_ALLOW_THREADS
940
+ fputs(buf, fp);
941
+ Py_END_ALLOW_THREADS
942
+ return 0;
943
+ }
944
+
945
+ #if @hascomplex@
946
+ static int
947
+ c@name@type_print(PyObject *v, FILE *fp, int flags)
948
+ {
949
+ /* Size of buf: twice sizeof(real) + 2 (for the parenthesis) */
950
+ char buf[202];
951
+ npy_c@name@ val = ((PyC@Name@ScalarObject *)v)->obval;
952
+
953
+ format_c@name@(buf, sizeof(buf), val,
954
+ (flags & Py_PRINT_RAW) ? @NAME@PREC_STR : @NAME@PREC_REPR);
955
+ Py_BEGIN_ALLOW_THREADS
956
+ fputs(buf, fp);
957
+ Py_END_ALLOW_THREADS
958
+ return 0;
959
+ }
960
+ #endif
961
+
962
+ /**end repeat**/
963
+
964
+
965
+ /*
966
+ * Could improve this with a PyLong_FromLongDouble(longdouble ldval)
967
+ * but this would need some more work...
968
+ */
969
+
970
+ /**begin repeat
971
+ *
972
+ * #name = (int, float)*2#
973
+ * #KIND = (Long, Float)*2#
974
+ * #char = ,,c*2#
975
+ * #CHAR = ,,C*2#
976
+ * #POST = ,,.real*2#
977
+ */
978
+ static PyObject *
979
+ @char@longdoubletype_@name@(PyObject *self)
980
+ {
981
+ double dval;
982
+ PyObject *obj, *ret;
983
+
984
+ dval = (double)(((Py@CHAR@LongDoubleScalarObject *)self)->obval)@POST@;
985
+ obj = Py@KIND@_FromDouble(dval);
986
+ if (obj == NULL) {
987
+ return NULL;
988
+ }
989
+ ret = Py_TYPE(obj)->tp_as_number->nb_@name@(obj);
990
+ Py_DECREF(obj);
991
+ return ret;
992
+ }
993
+ /**end repeat**/
994
+
995
+ #if !defined(NPY_PY3K)
996
+
997
+ /**begin repeat
998
+ *
999
+ * #name = (long, hex, oct)*2#
1000
+ * #KIND = (Long*3)*2#
1001
+ * #char = ,,,c*3#
1002
+ * #CHAR = ,,,C*3#
1003
+ * #POST = ,,,.real*3#
1004
+ */
1005
+ static PyObject *
1006
+ @char@longdoubletype_@name@(PyObject *self)
1007
+ {
1008
+ double dval;
1009
+ PyObject *obj, *ret;
1010
+
1011
+ dval = (double)(((Py@CHAR@LongDoubleScalarObject *)self)->obval)@POST@;
1012
+ obj = Py@KIND@_FromDouble(dval);
1013
+ if (obj == NULL) {
1014
+ return NULL;
1015
+ }
1016
+ ret = Py_TYPE(obj)->tp_as_number->nb_@name@(obj);
1017
+ Py_DECREF(obj);
1018
+ return ret;
1019
+ }
1020
+ /**end repeat**/
1021
+
1022
+ #endif /* !defined(NPY_PY3K) */
1023
+
1024
+ static PyNumberMethods gentype_as_number = {
1025
+ (binaryfunc)gentype_add, /*nb_add*/
1026
+ (binaryfunc)gentype_subtract, /*nb_subtract*/
1027
+ (binaryfunc)gentype_multiply, /*nb_multiply*/
1028
+ #if defined(NPY_PY3K)
1029
+ #else
1030
+ (binaryfunc)gentype_divide, /*nb_divide*/
1031
+ #endif
1032
+ (binaryfunc)gentype_remainder, /*nb_remainder*/
1033
+ (binaryfunc)gentype_divmod, /*nb_divmod*/
1034
+ (ternaryfunc)gentype_power, /*nb_power*/
1035
+ (unaryfunc)gentype_negative,
1036
+ (unaryfunc)gentype_positive, /*nb_pos*/
1037
+ (unaryfunc)gentype_absolute, /*(unaryfunc)gentype_abs,*/
1038
+ (inquiry)gentype_nonzero_number, /*nb_nonzero*/
1039
+ (unaryfunc)gentype_invert, /*nb_invert*/
1040
+ (binaryfunc)gentype_lshift, /*nb_lshift*/
1041
+ (binaryfunc)gentype_rshift, /*nb_rshift*/
1042
+ (binaryfunc)gentype_and, /*nb_and*/
1043
+ (binaryfunc)gentype_xor, /*nb_xor*/
1044
+ (binaryfunc)gentype_or, /*nb_or*/
1045
+ #if defined(NPY_PY3K)
1046
+ #else
1047
+ 0, /*nb_coerce*/
1048
+ #endif
1049
+ (unaryfunc)gentype_int, /*nb_int*/
1050
+ #if defined(NPY_PY3K)
1051
+ 0, /*nb_reserved*/
1052
+ #else
1053
+ (unaryfunc)gentype_long, /*nb_long*/
1054
+ #endif
1055
+ (unaryfunc)gentype_float, /*nb_float*/
1056
+ #if defined(NPY_PY3K)
1057
+ #else
1058
+ (unaryfunc)gentype_oct, /*nb_oct*/
1059
+ (unaryfunc)gentype_hex, /*nb_hex*/
1060
+ #endif
1061
+ 0, /*inplace_add*/
1062
+ 0, /*inplace_subtract*/
1063
+ 0, /*inplace_multiply*/
1064
+ #if defined(NPY_PY3K)
1065
+ #else
1066
+ 0, /*inplace_divide*/
1067
+ #endif
1068
+ 0, /*inplace_remainder*/
1069
+ 0, /*inplace_power*/
1070
+ 0, /*inplace_lshift*/
1071
+ 0, /*inplace_rshift*/
1072
+ 0, /*inplace_and*/
1073
+ 0, /*inplace_xor*/
1074
+ 0, /*inplace_or*/
1075
+ (binaryfunc)gentype_floor_divide, /*nb_floor_divide*/
1076
+ (binaryfunc)gentype_true_divide, /*nb_true_divide*/
1077
+ 0, /*nb_inplace_floor_divide*/
1078
+ 0, /*nb_inplace_true_divide*/
1079
+ (unaryfunc)NULL, /*nb_index*/
1080
+ };
1081
+
1082
+
1083
+ static PyObject *
1084
+ gentype_richcompare(PyObject *self, PyObject *other, int cmp_op)
1085
+ {
1086
+ PyObject *arr, *ret;
1087
+
1088
+ /*
1089
+ * If the other object is None, False is always right. This avoids
1090
+ * the array None comparison, at least until deprecation it is fixed.
1091
+ * After that, this may be removed and numpy false would be returned.
1092
+ *
1093
+ * NOTE: np.equal(NaT, None) evaluates to TRUE! This is an
1094
+ * an inconsistency, which may has to be considered
1095
+ * when the deprecation is finished.
1096
+ */
1097
+ if (other == Py_None) {
1098
+ if (cmp_op == Py_EQ) {
1099
+ Py_RETURN_FALSE;
1100
+ }
1101
+ if (cmp_op == Py_NE) {
1102
+ Py_RETURN_TRUE;
1103
+ }
1104
+ }
1105
+
1106
+ arr = PyArray_FromScalar(self, NULL);
1107
+ if (arr == NULL) {
1108
+ return NULL;
1109
+ }
1110
+ /*
1111
+ * Call via PyObject_RichCompare to ensure that other.__eq__
1112
+ * has a chance to run when necessary
1113
+ */
1114
+ ret = PyObject_RichCompare(arr, other, cmp_op);
1115
+ Py_DECREF(arr);
1116
+ return ret;
1117
+ }
1118
+
1119
+ static PyObject *
1120
+ gentype_ndim_get(PyObject *NPY_UNUSED(self))
1121
+ {
1122
+ return PyInt_FromLong(0);
1123
+ }
1124
+
1125
+ static PyObject *
1126
+ gentype_flags_get(PyObject *NPY_UNUSED(self))
1127
+ {
1128
+ return PyArray_NewFlagsObject(NULL);
1129
+ }
1130
+
1131
+ static PyObject *
1132
+ voidtype_flags_get(PyVoidScalarObject *self)
1133
+ {
1134
+ PyObject *flagobj;
1135
+ flagobj = PyArrayFlags_Type.tp_alloc(&PyArrayFlags_Type, 0);
1136
+ if (flagobj == NULL) {
1137
+ return NULL;
1138
+ }
1139
+ ((PyArrayFlagsObject *)flagobj)->arr = NULL;
1140
+ ((PyArrayFlagsObject *)flagobj)->flags = self->flags;
1141
+ return flagobj;
1142
+ }
1143
+
1144
+ static PyObject *
1145
+ voidtype_dtypedescr_get(PyVoidScalarObject *self)
1146
+ {
1147
+ Py_INCREF(self->descr);
1148
+ return (PyObject *)self->descr;
1149
+ }
1150
+
1151
+
1152
+ static PyObject *
1153
+ inttype_numerator_get(PyObject *self)
1154
+ {
1155
+ Py_INCREF(self);
1156
+ return self;
1157
+ }
1158
+
1159
+
1160
+ static PyObject *
1161
+ inttype_denominator_get(PyObject *self)
1162
+ {
1163
+ return PyInt_FromLong(1);
1164
+ }
1165
+
1166
+
1167
+ static PyObject *
1168
+ gentype_data_get(PyObject *self)
1169
+ {
1170
+ #if defined(NPY_PY3K)
1171
+ return PyMemoryView_FromObject(self);
1172
+ #else
1173
+ return PyBuffer_FromObject(self, 0, Py_END_OF_BUFFER);
1174
+ #endif
1175
+ }
1176
+
1177
+
1178
+ static PyObject *
1179
+ gentype_itemsize_get(PyObject *self)
1180
+ {
1181
+ PyArray_Descr *typecode;
1182
+ PyObject *ret;
1183
+ int elsize;
1184
+
1185
+ typecode = PyArray_DescrFromScalar(self);
1186
+ elsize = typecode->elsize;
1187
+ #ifndef Py_UNICODE_WIDE
1188
+ if (typecode->type_num == NPY_UNICODE) {
1189
+ elsize >>= 1;
1190
+ }
1191
+ #endif
1192
+ ret = PyInt_FromLong((long) elsize);
1193
+ Py_DECREF(typecode);
1194
+ return ret;
1195
+ }
1196
+
1197
+ static PyObject *
1198
+ gentype_size_get(PyObject *NPY_UNUSED(self))
1199
+ {
1200
+ return PyInt_FromLong(1);
1201
+ }
1202
+
1203
+ static PyObject *
1204
+ gentype_sizeof(PyObject *self)
1205
+ {
1206
+ Py_ssize_t nbytes;
1207
+ PyObject * isz = gentype_itemsize_get(self);
1208
+ if (isz == NULL) {
1209
+ return NULL;
1210
+ }
1211
+ nbytes = PyLong_AsLong(isz) + Py_TYPE(self)->tp_basicsize +
1212
+ Py_SIZE(self) * Py_TYPE(self)->tp_itemsize;
1213
+ Py_DECREF(isz);
1214
+ return PyLong_FromSsize_t(nbytes);
1215
+ }
1216
+
1217
+ #if PY_VERSION_HEX >= 0x03000000
1218
+ NPY_NO_EXPORT void
1219
+ gentype_struct_free(PyObject *ptr)
1220
+ {
1221
+ PyArrayInterface *arrif;
1222
+ PyObject *context;
1223
+
1224
+ arrif = (PyArrayInterface*)PyCapsule_GetPointer(ptr, NULL);
1225
+ context = (PyObject *)PyCapsule_GetContext(ptr);
1226
+ Py_DECREF(context);
1227
+ Py_XDECREF(arrif->descr);
1228
+ PyArray_free(arrif->shape);
1229
+ PyArray_free(arrif);
1230
+ }
1231
+ #else
1232
+ NPY_NO_EXPORT void
1233
+ gentype_struct_free(void *ptr, void *arg)
1234
+ {
1235
+ PyArrayInterface *arrif = (PyArrayInterface *)ptr;
1236
+ Py_DECREF((PyObject *)arg);
1237
+ Py_XDECREF(arrif->descr);
1238
+ PyArray_free(arrif->shape);
1239
+ PyArray_free(arrif);
1240
+ }
1241
+ #endif
1242
+
1243
+ static PyObject *
1244
+ gentype_struct_get(PyObject *self)
1245
+ {
1246
+ PyArrayObject *arr;
1247
+ PyArrayInterface *inter;
1248
+ PyObject *ret;
1249
+
1250
+ arr = (PyArrayObject *)PyArray_FromScalar(self, NULL);
1251
+ inter = (PyArrayInterface *)PyArray_malloc(sizeof(PyArrayInterface));
1252
+ inter->two = 2;
1253
+ inter->nd = 0;
1254
+ inter->flags = PyArray_FLAGS(arr);
1255
+ inter->flags &= ~(NPY_ARRAY_UPDATEIFCOPY | NPY_ARRAY_OWNDATA);
1256
+ inter->flags |= NPY_ARRAY_NOTSWAPPED;
1257
+ inter->typekind = PyArray_DESCR(arr)->kind;
1258
+ inter->itemsize = PyArray_DESCR(arr)->elsize;
1259
+ inter->strides = NULL;
1260
+ inter->shape = NULL;
1261
+ inter->data = PyArray_DATA(arr);
1262
+ inter->descr = NULL;
1263
+
1264
+ ret = NpyCapsule_FromVoidPtrAndDesc(inter, arr, gentype_struct_free);
1265
+ return ret;
1266
+ }
1267
+
1268
+ static PyObject *
1269
+ gentype_priority_get(PyObject *NPY_UNUSED(self))
1270
+ {
1271
+ return PyFloat_FromDouble(NPY_SCALAR_PRIORITY);
1272
+ }
1273
+
1274
+ static PyObject *
1275
+ gentype_shape_get(PyObject *NPY_UNUSED(self))
1276
+ {
1277
+ return PyTuple_New(0);
1278
+ }
1279
+
1280
+
1281
+ static PyObject *
1282
+ gentype_interface_get(PyObject *self)
1283
+ {
1284
+ PyArrayObject *arr;
1285
+ PyObject *inter;
1286
+
1287
+ arr = (PyArrayObject *)PyArray_FromScalar(self, NULL);
1288
+ if (arr == NULL) {
1289
+ return NULL;
1290
+ }
1291
+ inter = PyObject_GetAttrString((PyObject *)arr, "__array_interface__");
1292
+ if (inter != NULL) {
1293
+ PyDict_SetItemString(inter, "__ref", (PyObject *)arr);
1294
+ }
1295
+ Py_DECREF(arr);
1296
+ return inter;
1297
+ }
1298
+
1299
+
1300
+
1301
+ static PyObject *
1302
+ gentype_typedescr_get(PyObject *self)
1303
+ {
1304
+ return (PyObject *)PyArray_DescrFromScalar(self);
1305
+ }
1306
+
1307
+
1308
+ static PyObject *
1309
+ gentype_base_get(PyObject *NPY_UNUSED(self))
1310
+ {
1311
+ Py_RETURN_NONE;
1312
+ }
1313
+
1314
+
1315
+ static PyArray_Descr *
1316
+ _realdescr_fromcomplexscalar(PyObject *self, int *typenum)
1317
+ {
1318
+ if (PyArray_IsScalar(self, CDouble)) {
1319
+ *typenum = NPY_CDOUBLE;
1320
+ return PyArray_DescrFromType(NPY_DOUBLE);
1321
+ }
1322
+ if (PyArray_IsScalar(self, CFloat)) {
1323
+ *typenum = NPY_CFLOAT;
1324
+ return PyArray_DescrFromType(NPY_FLOAT);
1325
+ }
1326
+ if (PyArray_IsScalar(self, CLongDouble)) {
1327
+ *typenum = NPY_CLONGDOUBLE;
1328
+ return PyArray_DescrFromType(NPY_LONGDOUBLE);
1329
+ }
1330
+ return NULL;
1331
+ }
1332
+
1333
+ static PyObject *
1334
+ gentype_real_get(PyObject *self)
1335
+ {
1336
+ PyArray_Descr *typecode;
1337
+ PyObject *ret;
1338
+ int typenum;
1339
+
1340
+ if (PyArray_IsScalar(self, ComplexFloating)) {
1341
+ void *ptr;
1342
+ typecode = _realdescr_fromcomplexscalar(self, &typenum);
1343
+ ptr = scalar_value(self, NULL);
1344
+ ret = PyArray_Scalar(ptr, typecode, NULL);
1345
+ Py_DECREF(typecode);
1346
+ return ret;
1347
+ }
1348
+ else if (PyArray_IsScalar(self, Object)) {
1349
+ PyObject *obj = ((PyObjectScalarObject *)self)->obval;
1350
+ ret = PyObject_GetAttrString(obj, "real");
1351
+ if (ret != NULL) {
1352
+ return ret;
1353
+ }
1354
+ PyErr_Clear();
1355
+ }
1356
+ Py_INCREF(self);
1357
+ return (PyObject *)self;
1358
+ }
1359
+
1360
+ static PyObject *
1361
+ gentype_imag_get(PyObject *self)
1362
+ {
1363
+ PyArray_Descr *typecode=NULL;
1364
+ PyObject *ret;
1365
+ int typenum;
1366
+
1367
+ if (PyArray_IsScalar(self, ComplexFloating)) {
1368
+ char *ptr;
1369
+ typecode = _realdescr_fromcomplexscalar(self, &typenum);
1370
+ ptr = (char *)scalar_value(self, NULL);
1371
+ ret = PyArray_Scalar(ptr + typecode->elsize, typecode, NULL);
1372
+ }
1373
+ else if (PyArray_IsScalar(self, Object)) {
1374
+ PyObject *obj = ((PyObjectScalarObject *)self)->obval;
1375
+ PyArray_Descr *newtype;
1376
+ ret = PyObject_GetAttrString(obj, "imag");
1377
+ if (ret == NULL) {
1378
+ PyErr_Clear();
1379
+ obj = PyInt_FromLong(0);
1380
+ newtype = PyArray_DescrFromType(NPY_OBJECT);
1381
+ ret = PyArray_Scalar((char *)&obj, newtype, NULL);
1382
+ Py_DECREF(newtype);
1383
+ Py_DECREF(obj);
1384
+ }
1385
+ }
1386
+ else {
1387
+ char *temp;
1388
+ int elsize;
1389
+ typecode = PyArray_DescrFromScalar(self);
1390
+ elsize = typecode->elsize;
1391
+ temp = PyDataMem_NEW(elsize);
1392
+ memset(temp, '\0', elsize);
1393
+ ret = PyArray_Scalar(temp, typecode, NULL);
1394
+ PyDataMem_FREE(temp);
1395
+ }
1396
+
1397
+ Py_XDECREF(typecode);
1398
+ return ret;
1399
+ }
1400
+
1401
+ static PyObject *
1402
+ gentype_flat_get(PyObject *self)
1403
+ {
1404
+ PyObject *ret, *arr;
1405
+
1406
+ arr = PyArray_FromScalar(self, NULL);
1407
+ if (arr == NULL) {
1408
+ return NULL;
1409
+ }
1410
+ ret = PyArray_IterNew(arr);
1411
+ Py_DECREF(arr);
1412
+ return ret;
1413
+ }
1414
+
1415
+
1416
+ static PyObject *
1417
+ gentype_transpose_get(PyObject *self)
1418
+ {
1419
+ Py_INCREF(self);
1420
+ return self;
1421
+ }
1422
+
1423
+
1424
+ static PyGetSetDef gentype_getsets[] = {
1425
+ {"ndim",
1426
+ (getter)gentype_ndim_get,
1427
+ (setter) 0,
1428
+ "number of array dimensions",
1429
+ NULL},
1430
+ {"flags",
1431
+ (getter)gentype_flags_get,
1432
+ (setter)0,
1433
+ "integer value of flags",
1434
+ NULL},
1435
+ {"shape",
1436
+ (getter)gentype_shape_get,
1437
+ (setter)0,
1438
+ "tuple of array dimensions",
1439
+ NULL},
1440
+ {"strides",
1441
+ (getter)gentype_shape_get,
1442
+ (setter) 0,
1443
+ "tuple of bytes steps in each dimension",
1444
+ NULL},
1445
+ {"data",
1446
+ (getter)gentype_data_get,
1447
+ (setter) 0,
1448
+ "pointer to start of data",
1449
+ NULL},
1450
+ {"itemsize",
1451
+ (getter)gentype_itemsize_get,
1452
+ (setter)0,
1453
+ "length of one element in bytes",
1454
+ NULL},
1455
+ {"size",
1456
+ (getter)gentype_size_get,
1457
+ (setter)0,
1458
+ "number of elements in the gentype",
1459
+ NULL},
1460
+ {"nbytes",
1461
+ (getter)gentype_itemsize_get,
1462
+ (setter)0,
1463
+ "length of item in bytes",
1464
+ NULL},
1465
+ {"base",
1466
+ (getter)gentype_base_get,
1467
+ (setter)0,
1468
+ "base object",
1469
+ NULL},
1470
+ {"dtype",
1471
+ (getter)gentype_typedescr_get,
1472
+ NULL,
1473
+ "get array data-descriptor",
1474
+ NULL},
1475
+ {"real",
1476
+ (getter)gentype_real_get,
1477
+ (setter)0,
1478
+ "real part of scalar",
1479
+ NULL},
1480
+ {"imag",
1481
+ (getter)gentype_imag_get,
1482
+ (setter)0,
1483
+ "imaginary part of scalar",
1484
+ NULL},
1485
+ {"flat",
1486
+ (getter)gentype_flat_get,
1487
+ (setter)0,
1488
+ "a 1-d view of scalar",
1489
+ NULL},
1490
+ {"T",
1491
+ (getter)gentype_transpose_get,
1492
+ (setter)0,
1493
+ "transpose",
1494
+ NULL},
1495
+ {"__array_interface__",
1496
+ (getter)gentype_interface_get,
1497
+ NULL,
1498
+ "Array protocol: Python side",
1499
+ NULL},
1500
+ {"__array_struct__",
1501
+ (getter)gentype_struct_get,
1502
+ NULL,
1503
+ "Array protocol: struct",
1504
+ NULL},
1505
+ {"__array_priority__",
1506
+ (getter)gentype_priority_get,
1507
+ NULL,
1508
+ "Array priority.",
1509
+ NULL},
1510
+ {NULL, NULL, NULL, NULL, NULL} /* Sentinel */
1511
+ };
1512
+
1513
+
1514
+ /* 0-dim array from scalar object */
1515
+
1516
+ static char doc_getarray[] = "sc.__array__(|type) return 0-dim array";
1517
+
1518
+ static PyObject *
1519
+ gentype_getarray(PyObject *scalar, PyObject *args)
1520
+ {
1521
+ PyArray_Descr *outcode=NULL;
1522
+ PyObject *ret;
1523
+
1524
+ if (!PyArg_ParseTuple(args, "|O&", &PyArray_DescrConverter,
1525
+ &outcode)) {
1526
+ Py_XDECREF(outcode);
1527
+ return NULL;
1528
+ }
1529
+ ret = PyArray_FromScalar(scalar, outcode);
1530
+ return ret;
1531
+ }
1532
+
1533
+ static char doc_sc_wraparray[] = "sc.__array_wrap__(obj) return scalar from array";
1534
+
1535
+ static PyObject *
1536
+ gentype_wraparray(PyObject *NPY_UNUSED(scalar), PyObject *args)
1537
+ {
1538
+ PyObject *obj;
1539
+ PyArrayObject *arr;
1540
+
1541
+ if (PyTuple_Size(args) < 1) {
1542
+ PyErr_SetString(PyExc_TypeError,
1543
+ "only accepts 1 argument.");
1544
+ return NULL;
1545
+ }
1546
+ obj = PyTuple_GET_ITEM(args, 0);
1547
+ if (!PyArray_Check(obj)) {
1548
+ PyErr_SetString(PyExc_TypeError,
1549
+ "can only be called with ndarray object");
1550
+ return NULL;
1551
+ }
1552
+ arr = (PyArrayObject *)obj;
1553
+
1554
+ return PyArray_Scalar(PyArray_DATA(arr),
1555
+ PyArray_DESCR(arr), (PyObject *)arr);
1556
+ }
1557
+
1558
+ /*
1559
+ * These gentype_* functions do not take keyword arguments.
1560
+ * The proper flag is METH_VARARGS.
1561
+ */
1562
+ /**begin repeat
1563
+ *
1564
+ * #name = tolist, item, tostring, tobytes, astype, copy, __deepcopy__,
1565
+ * searchsorted, view, swapaxes, conj, conjugate, nonzero, flatten,
1566
+ * ravel, fill, transpose, newbyteorder#
1567
+ */
1568
+ static PyObject *
1569
+ gentype_@name@(PyObject *self, PyObject *args)
1570
+ {
1571
+ return gentype_generic_method(self, args, NULL, "@name@");
1572
+ }
1573
+ /**end repeat**/
1574
+
1575
+ static PyObject *
1576
+ gentype_itemset(PyObject *NPY_UNUSED(self), PyObject *NPY_UNUSED(args))
1577
+ {
1578
+ PyErr_SetString(PyExc_ValueError, "array-scalars are immutable");
1579
+ return NULL;
1580
+ }
1581
+
1582
+ static PyObject *
1583
+ gentype_squeeze(PyObject *self, PyObject *args)
1584
+ {
1585
+ if (!PyArg_ParseTuple(args, "")) {
1586
+ return NULL;
1587
+ }
1588
+ Py_INCREF(self);
1589
+ return self;
1590
+ }
1591
+
1592
+ static Py_ssize_t
1593
+ gentype_getreadbuf(PyObject *, Py_ssize_t, void **);
1594
+
1595
+ static PyObject *
1596
+ gentype_byteswap(PyObject *self, PyObject *args)
1597
+ {
1598
+ npy_bool inplace = NPY_FALSE;
1599
+
1600
+ if (!PyArg_ParseTuple(args, "|O&", PyArray_BoolConverter, &inplace)) {
1601
+ return NULL;
1602
+ }
1603
+ if (inplace) {
1604
+ PyErr_SetString(PyExc_ValueError,
1605
+ "cannot byteswap a scalar in-place");
1606
+ return NULL;
1607
+ }
1608
+ else {
1609
+ /* get the data, copyswap it and pass it to a new Array scalar */
1610
+ char *data;
1611
+ PyArray_Descr *descr;
1612
+ PyObject *new;
1613
+ char *newmem;
1614
+
1615
+ gentype_getreadbuf(self, 0, (void **)&data);
1616
+ descr = PyArray_DescrFromScalar(self);
1617
+ newmem = PyObject_Malloc(descr->elsize);
1618
+ if (newmem == NULL) {
1619
+ Py_DECREF(descr);
1620
+ return PyErr_NoMemory();
1621
+ }
1622
+ else {
1623
+ descr->f->copyswap(newmem, data, 1, NULL);
1624
+ }
1625
+ new = PyArray_Scalar(newmem, descr, NULL);
1626
+ PyObject_Free(newmem);
1627
+ Py_DECREF(descr);
1628
+ return new;
1629
+ }
1630
+ }
1631
+
1632
+
1633
+ /*
1634
+ * These gentype_* functions take keyword arguments.
1635
+ * The proper flag is METH_VARARGS | METH_KEYWORDS.
1636
+ */
1637
+ /**begin repeat
1638
+ *
1639
+ * #name = take, getfield, put, repeat, tofile, mean, trace, diagonal, clip,
1640
+ * std, var, sum, cumsum, prod, cumprod, compress, sort, argsort,
1641
+ * round, argmax, argmin, max, min, ptp, any, all, resize, reshape,
1642
+ * choose#
1643
+ */
1644
+ static PyObject *
1645
+ gentype_@name@(PyObject *self, PyObject *args, PyObject *kwds)
1646
+ {
1647
+ return gentype_generic_method(self, args, kwds, "@name@");
1648
+ }
1649
+ /**end repeat**/
1650
+
1651
+ static PyObject *
1652
+ voidtype_getfield(PyVoidScalarObject *self, PyObject *args, PyObject *kwds)
1653
+ {
1654
+ /* Use ndarray's getfield to obtain the field safely */
1655
+ return gentype_generic_method((PyObject *)self, args, kwds, "getfield");
1656
+ }
1657
+
1658
+ static PyObject *
1659
+ gentype_setfield(PyObject *NPY_UNUSED(self), PyObject *NPY_UNUSED(args),
1660
+ PyObject *NPY_UNUSED(kwds))
1661
+ {
1662
+ PyErr_SetString(PyExc_TypeError,
1663
+ "Can't set fields in a non-void array scalar.");
1664
+ return NULL;
1665
+ }
1666
+
1667
+ static PyObject *
1668
+ voidtype_setfield(PyVoidScalarObject *self, PyObject *args, PyObject *kwds)
1669
+ {
1670
+ /*
1671
+ * We would like to use ndarray's setfield because it performs safety
1672
+ * checks on the field datatypes and because it broadcasts properly.
1673
+ * However, as a special case, void-scalar assignment broadcasts
1674
+ * differently from ndarrays when assigning to an object field: Assignment
1675
+ * to an ndarray object field broadcasts, but assignment to a void-scalar
1676
+ * object-field should not, in order to allow nested ndarrays.
1677
+ * These lines should then behave identically:
1678
+ *
1679
+ * b = np.zeros(1, dtype=[('x', 'O')])
1680
+ * b[0]['x'] = arange(3) # uses voidtype_setfield
1681
+ * b['x'][0] = arange(3) # uses ndarray setitem
1682
+ *
1683
+ * Ndarray's setfield would try to broadcast the lhs. Instead we use
1684
+ * ndarray getfield to get the field safely, then setitem to set the value
1685
+ * without broadcast. Note we also want subarrays to be set properly, ie
1686
+ *
1687
+ * a = np.zeros(1, dtype=[('x', 'i', 5)])
1688
+ * a[0]['x'] = 1
1689
+ *
1690
+ * sets all values to 1. Setitem does this.
1691
+ */
1692
+ PyObject *getfield_args, *value, *arr, *meth, *arr_field, *emptytuple;
1693
+
1694
+ value = PyTuple_GetItem(args, 0);
1695
+ if (value == NULL) {
1696
+ return NULL;
1697
+ }
1698
+ getfield_args = PyTuple_GetSlice(args, 1, 3);
1699
+ if (getfield_args == NULL) {
1700
+ return NULL;
1701
+ }
1702
+
1703
+ /* 1. Convert to 0-d array and use getfield */
1704
+ arr = PyArray_FromScalar((PyObject*)self, NULL);
1705
+ if (arr == NULL) {
1706
+ Py_DECREF(getfield_args);
1707
+ return NULL;
1708
+ }
1709
+ meth = PyObject_GetAttrString(arr, "getfield");
1710
+ if (meth == NULL) {
1711
+ Py_DECREF(getfield_args);
1712
+ Py_DECREF(arr);
1713
+ return NULL;
1714
+ }
1715
+ if (kwds == NULL) {
1716
+ arr_field = PyObject_CallObject(meth, getfield_args);
1717
+ }
1718
+ else {
1719
+ arr_field = PyObject_Call(meth, getfield_args, kwds);
1720
+ }
1721
+ Py_DECREF(getfield_args);
1722
+ Py_DECREF(meth);
1723
+ Py_DECREF(arr);
1724
+
1725
+ if(arr_field == NULL){
1726
+ return NULL;
1727
+ }
1728
+
1729
+ /* 2. Fill the resulting array using setitem */
1730
+ emptytuple = PyTuple_New(0);
1731
+ if (PyObject_SetItem(arr_field, emptytuple, value) < 0) {
1732
+ Py_DECREF(arr_field);
1733
+ Py_DECREF(emptytuple);
1734
+ return NULL;
1735
+ }
1736
+ Py_DECREF(arr_field);
1737
+ Py_DECREF(emptytuple);
1738
+
1739
+ Py_RETURN_NONE;
1740
+ }
1741
+
1742
+
1743
+ static PyObject *
1744
+ gentype_reduce(PyObject *self, PyObject *NPY_UNUSED(args))
1745
+ {
1746
+ PyObject *ret = NULL, *obj = NULL, *mod = NULL;
1747
+ const char *buffer;
1748
+ Py_ssize_t buflen;
1749
+
1750
+ /* Return a tuple of (callable object, arguments) */
1751
+ ret = PyTuple_New(2);
1752
+ if (ret == NULL) {
1753
+ return NULL;
1754
+ }
1755
+ #if defined(NPY_PY3K)
1756
+ if (PyArray_IsScalar(self, Unicode)) {
1757
+ /* Unicode on Python 3 does not expose the buffer interface */
1758
+ buffer = PyUnicode_AS_DATA(self);
1759
+ buflen = PyUnicode_GET_DATA_SIZE(self);
1760
+ }
1761
+ else
1762
+ #endif
1763
+ if (PyObject_AsReadBuffer(self, (const void **)&buffer, &buflen)<0) {
1764
+ Py_DECREF(ret);
1765
+ return NULL;
1766
+ }
1767
+ mod = PyImport_ImportModule("numpy.core.multiarray");
1768
+ if (mod == NULL) {
1769
+ return NULL;
1770
+ }
1771
+ obj = PyObject_GetAttrString(mod, "scalar");
1772
+ Py_DECREF(mod);
1773
+ if (obj == NULL) {
1774
+ return NULL;
1775
+ }
1776
+ PyTuple_SET_ITEM(ret, 0, obj);
1777
+ obj = PyObject_GetAttrString((PyObject *)self, "dtype");
1778
+ if (PyArray_IsScalar(self, Object)) {
1779
+ mod = ((PyObjectScalarObject *)self)->obval;
1780
+ PyTuple_SET_ITEM(ret, 1, Py_BuildValue("NO", obj, mod));
1781
+ }
1782
+ else {
1783
+ #ifndef Py_UNICODE_WIDE
1784
+ /*
1785
+ * We need to expand the buffer so that we always write
1786
+ * UCS4 to disk for pickle of unicode scalars.
1787
+ *
1788
+ * This could be in a unicode_reduce function, but
1789
+ * that would require re-factoring.
1790
+ */
1791
+ int alloc = 0;
1792
+ char *tmp;
1793
+ int newlen;
1794
+
1795
+ if (PyArray_IsScalar(self, Unicode)) {
1796
+ tmp = PyArray_malloc(buflen*2);
1797
+ if (tmp == NULL) {
1798
+ Py_DECREF(ret);
1799
+ return PyErr_NoMemory();
1800
+ }
1801
+ alloc = 1;
1802
+ newlen = PyUCS2Buffer_AsUCS4((Py_UNICODE *)buffer,
1803
+ (npy_ucs4 *)tmp,
1804
+ buflen / 2, buflen / 2);
1805
+ buflen = newlen*4;
1806
+ buffer = tmp;
1807
+ }
1808
+ #endif
1809
+ mod = PyBytes_FromStringAndSize(buffer, buflen);
1810
+ if (mod == NULL) {
1811
+ Py_DECREF(ret);
1812
+ #ifndef Py_UNICODE_WIDE
1813
+ ret = NULL;
1814
+ goto fail;
1815
+ #else
1816
+ return NULL;
1817
+ #endif
1818
+ }
1819
+ PyTuple_SET_ITEM(ret, 1,
1820
+ Py_BuildValue("NN", obj, mod));
1821
+ #ifndef Py_UNICODE_WIDE
1822
+ fail:
1823
+ if (alloc) PyArray_free((char *)buffer);
1824
+ #endif
1825
+ }
1826
+ return ret;
1827
+ }
1828
+
1829
+ /* ignores everything */
1830
+ static PyObject *
1831
+ gentype_setstate(PyObject *NPY_UNUSED(self), PyObject *NPY_UNUSED(args))
1832
+ {
1833
+ Py_RETURN_NONE;
1834
+ }
1835
+
1836
+ static PyObject *
1837
+ gentype_dump(PyObject *self, PyObject *args)
1838
+ {
1839
+ PyObject *file = NULL;
1840
+ int ret;
1841
+
1842
+ if (!PyArg_ParseTuple(args, "O", &file)) {
1843
+ return NULL;
1844
+ }
1845
+ ret = PyArray_Dump(self, file, 2);
1846
+ if (ret < 0) {
1847
+ return NULL;
1848
+ }
1849
+ Py_RETURN_NONE;
1850
+ }
1851
+
1852
+ static PyObject *
1853
+ gentype_dumps(PyObject *self, PyObject *args)
1854
+ {
1855
+ if (!PyArg_ParseTuple(args, "")) {
1856
+ return NULL;
1857
+ }
1858
+ return PyArray_Dumps(self, 2);
1859
+ }
1860
+
1861
+
1862
+ /* setting flags cannot be done for scalars */
1863
+ static PyObject *
1864
+ gentype_setflags(PyObject *NPY_UNUSED(self), PyObject *NPY_UNUSED(args),
1865
+ PyObject *NPY_UNUSED(kwds))
1866
+ {
1867
+ Py_RETURN_NONE;
1868
+ }
1869
+
1870
+ /*
1871
+ * casting complex numbers (that don't inherit from Python complex)
1872
+ * to Python complex
1873
+ */
1874
+
1875
+ /**begin repeat
1876
+ * #name = cfloat, clongdouble#
1877
+ * #Name = CFloat, CLongDouble#
1878
+ */
1879
+ static PyObject *
1880
+ @name@_complex(PyObject *self, PyObject *NPY_UNUSED(args),
1881
+ PyObject *NPY_UNUSED(kwds))
1882
+ {
1883
+ return PyComplex_FromDoubles(PyArrayScalar_VAL(self, @Name@).real,
1884
+ PyArrayScalar_VAL(self, @Name@).imag);
1885
+ }
1886
+ /**end repeat**/
1887
+
1888
+ /*
1889
+ * need to fill in doc-strings for these methods on import -- copy from
1890
+ * array docstrings
1891
+ */
1892
+ static PyMethodDef gentype_methods[] = {
1893
+ {"tolist",
1894
+ (PyCFunction)gentype_tolist,
1895
+ METH_VARARGS, NULL},
1896
+ {"item",
1897
+ (PyCFunction)gentype_item,
1898
+ METH_VARARGS, NULL},
1899
+ {"itemset",
1900
+ (PyCFunction)gentype_itemset,
1901
+ METH_VARARGS, NULL},
1902
+ {"tobytes",
1903
+ (PyCFunction)gentype_tobytes,
1904
+ METH_VARARGS, NULL},
1905
+ {"tofile",
1906
+ (PyCFunction)gentype_tofile,
1907
+ METH_VARARGS | METH_KEYWORDS, NULL},
1908
+ {"tostring",
1909
+ (PyCFunction)gentype_tostring,
1910
+ METH_VARARGS, NULL},
1911
+ {"byteswap",
1912
+ (PyCFunction)gentype_byteswap,
1913
+ METH_VARARGS, NULL},
1914
+ {"astype",
1915
+ (PyCFunction)gentype_astype,
1916
+ METH_VARARGS, NULL},
1917
+ {"getfield",
1918
+ (PyCFunction)gentype_getfield,
1919
+ METH_VARARGS | METH_KEYWORDS, NULL},
1920
+ {"setfield",
1921
+ (PyCFunction)gentype_setfield,
1922
+ METH_VARARGS | METH_KEYWORDS, NULL},
1923
+ {"copy",
1924
+ (PyCFunction)gentype_copy,
1925
+ METH_VARARGS, NULL},
1926
+ {"resize",
1927
+ (PyCFunction)gentype_resize,
1928
+ METH_VARARGS | METH_KEYWORDS, NULL},
1929
+ {"__array__",
1930
+ (PyCFunction)gentype_getarray,
1931
+ METH_VARARGS, doc_getarray},
1932
+ {"__array_wrap__",
1933
+ (PyCFunction)gentype_wraparray,
1934
+ METH_VARARGS, doc_sc_wraparray},
1935
+
1936
+ /* for the sys module */
1937
+ {"__sizeof__",
1938
+ (PyCFunction)gentype_sizeof,
1939
+ METH_NOARGS, NULL},
1940
+
1941
+ /* for the copy module */
1942
+ {"__copy__",
1943
+ (PyCFunction)gentype_copy,
1944
+ METH_VARARGS, NULL},
1945
+ {"__deepcopy__",
1946
+ (PyCFunction)gentype___deepcopy__,
1947
+ METH_VARARGS, NULL},
1948
+
1949
+ {"__reduce__",
1950
+ (PyCFunction) gentype_reduce,
1951
+ METH_VARARGS, NULL},
1952
+ /* For consistency does nothing */
1953
+ {"__setstate__",
1954
+ (PyCFunction) gentype_setstate,
1955
+ METH_VARARGS, NULL},
1956
+
1957
+ {"dumps",
1958
+ (PyCFunction) gentype_dumps,
1959
+ METH_VARARGS, NULL},
1960
+ {"dump",
1961
+ (PyCFunction) gentype_dump,
1962
+ METH_VARARGS, NULL},
1963
+
1964
+ /* Methods for array */
1965
+ {"fill",
1966
+ (PyCFunction)gentype_fill,
1967
+ METH_VARARGS, NULL},
1968
+ {"transpose",
1969
+ (PyCFunction)gentype_transpose,
1970
+ METH_VARARGS, NULL},
1971
+ {"take",
1972
+ (PyCFunction)gentype_take,
1973
+ METH_VARARGS | METH_KEYWORDS, NULL},
1974
+ {"put",
1975
+ (PyCFunction)gentype_put,
1976
+ METH_VARARGS | METH_KEYWORDS, NULL},
1977
+ {"repeat",
1978
+ (PyCFunction)gentype_repeat,
1979
+ METH_VARARGS | METH_KEYWORDS, NULL},
1980
+ {"choose",
1981
+ (PyCFunction)gentype_choose,
1982
+ METH_VARARGS | METH_KEYWORDS, NULL},
1983
+ {"sort",
1984
+ (PyCFunction)gentype_sort,
1985
+ METH_VARARGS | METH_KEYWORDS, NULL},
1986
+ {"argsort",
1987
+ (PyCFunction)gentype_argsort,
1988
+ METH_VARARGS | METH_KEYWORDS, NULL},
1989
+ {"searchsorted",
1990
+ (PyCFunction)gentype_searchsorted,
1991
+ METH_VARARGS, NULL},
1992
+ {"argmax",
1993
+ (PyCFunction)gentype_argmax,
1994
+ METH_VARARGS | METH_KEYWORDS, NULL},
1995
+ {"argmin",
1996
+ (PyCFunction)gentype_argmin,
1997
+ METH_VARARGS | METH_KEYWORDS, NULL},
1998
+ {"reshape",
1999
+ (PyCFunction)gentype_reshape,
2000
+ METH_VARARGS | METH_KEYWORDS, NULL},
2001
+ {"squeeze",
2002
+ (PyCFunction)gentype_squeeze,
2003
+ METH_VARARGS, NULL},
2004
+ {"view",
2005
+ (PyCFunction)gentype_view,
2006
+ METH_VARARGS, NULL},
2007
+ {"swapaxes",
2008
+ (PyCFunction)gentype_swapaxes,
2009
+ METH_VARARGS, NULL},
2010
+ {"max",
2011
+ (PyCFunction)gentype_max,
2012
+ METH_VARARGS | METH_KEYWORDS, NULL},
2013
+ {"min",
2014
+ (PyCFunction)gentype_min,
2015
+ METH_VARARGS | METH_KEYWORDS, NULL},
2016
+ {"ptp",
2017
+ (PyCFunction)gentype_ptp,
2018
+ METH_VARARGS | METH_KEYWORDS, NULL},
2019
+ {"mean",
2020
+ (PyCFunction)gentype_mean,
2021
+ METH_VARARGS | METH_KEYWORDS, NULL},
2022
+ {"trace",
2023
+ (PyCFunction)gentype_trace,
2024
+ METH_VARARGS | METH_KEYWORDS, NULL},
2025
+ {"diagonal",
2026
+ (PyCFunction)gentype_diagonal,
2027
+ METH_VARARGS | METH_KEYWORDS, NULL},
2028
+ {"clip",
2029
+ (PyCFunction)gentype_clip,
2030
+ METH_VARARGS | METH_KEYWORDS, NULL},
2031
+ {"conj",
2032
+ (PyCFunction)gentype_conj,
2033
+ METH_VARARGS, NULL},
2034
+ {"conjugate",
2035
+ (PyCFunction)gentype_conjugate,
2036
+ METH_VARARGS, NULL},
2037
+ {"nonzero",
2038
+ (PyCFunction)gentype_nonzero,
2039
+ METH_VARARGS, NULL},
2040
+ {"std",
2041
+ (PyCFunction)gentype_std,
2042
+ METH_VARARGS | METH_KEYWORDS, NULL},
2043
+ {"var",
2044
+ (PyCFunction)gentype_var,
2045
+ METH_VARARGS | METH_KEYWORDS, NULL},
2046
+ {"sum",
2047
+ (PyCFunction)gentype_sum,
2048
+ METH_VARARGS | METH_KEYWORDS, NULL},
2049
+ {"cumsum",
2050
+ (PyCFunction)gentype_cumsum,
2051
+ METH_VARARGS | METH_KEYWORDS, NULL},
2052
+ {"prod",
2053
+ (PyCFunction)gentype_prod,
2054
+ METH_VARARGS | METH_KEYWORDS, NULL},
2055
+ {"cumprod",
2056
+ (PyCFunction)gentype_cumprod,
2057
+ METH_VARARGS | METH_KEYWORDS, NULL},
2058
+ {"all",
2059
+ (PyCFunction)gentype_all,
2060
+ METH_VARARGS | METH_KEYWORDS, NULL},
2061
+ {"any",
2062
+ (PyCFunction)gentype_any,
2063
+ METH_VARARGS | METH_KEYWORDS, NULL},
2064
+ {"compress",
2065
+ (PyCFunction)gentype_compress,
2066
+ METH_VARARGS | METH_KEYWORDS, NULL},
2067
+ {"flatten",
2068
+ (PyCFunction)gentype_flatten,
2069
+ METH_VARARGS, NULL},
2070
+ {"ravel",
2071
+ (PyCFunction)gentype_ravel,
2072
+ METH_VARARGS, NULL},
2073
+ {"round",
2074
+ (PyCFunction)gentype_round,
2075
+ METH_VARARGS | METH_KEYWORDS, NULL},
2076
+ #if defined(NPY_PY3K)
2077
+ /* Hook for the round() builtin */
2078
+ {"__round__",
2079
+ (PyCFunction)gentype_round,
2080
+ METH_VARARGS | METH_KEYWORDS, NULL},
2081
+ #endif
2082
+ /* For the format function */
2083
+ {"__format__",
2084
+ gentype_format,
2085
+ METH_VARARGS,
2086
+ "NumPy array scalar formatter"},
2087
+ {"setflags",
2088
+ (PyCFunction)gentype_setflags,
2089
+ METH_VARARGS | METH_KEYWORDS, NULL},
2090
+ {"newbyteorder",
2091
+ (PyCFunction)gentype_newbyteorder,
2092
+ METH_VARARGS, NULL},
2093
+ {NULL, NULL, 0, NULL} /* sentinel */
2094
+ };
2095
+
2096
+
2097
+ static PyGetSetDef voidtype_getsets[] = {
2098
+ {"flags",
2099
+ (getter)voidtype_flags_get,
2100
+ (setter)0,
2101
+ "integer value of flags",
2102
+ NULL},
2103
+ {"dtype",
2104
+ (getter)voidtype_dtypedescr_get,
2105
+ (setter)0,
2106
+ "dtype object",
2107
+ NULL},
2108
+ {NULL, NULL, NULL, NULL, NULL}
2109
+ };
2110
+
2111
+ static PyMethodDef voidtype_methods[] = {
2112
+ {"getfield",
2113
+ (PyCFunction)voidtype_getfield,
2114
+ METH_VARARGS | METH_KEYWORDS, NULL},
2115
+ {"setfield",
2116
+ (PyCFunction)voidtype_setfield,
2117
+ METH_VARARGS | METH_KEYWORDS, NULL},
2118
+ {NULL, NULL, 0, NULL}
2119
+ };
2120
+
2121
+ static PyGetSetDef inttype_getsets[] = {
2122
+ {"numerator",
2123
+ (getter)inttype_numerator_get,
2124
+ (setter)0,
2125
+ "numerator of value (the value itself)",
2126
+ NULL},
2127
+ {"denominator",
2128
+ (getter)inttype_denominator_get,
2129
+ (setter)0,
2130
+ "denominator of value (1)",
2131
+ NULL},
2132
+ {NULL, NULL, NULL, NULL, NULL}
2133
+ };
2134
+
2135
+ /**begin repeat
2136
+ * #name = cfloat,clongdouble#
2137
+ */
2138
+ static PyMethodDef @name@type_methods[] = {
2139
+ {"__complex__",
2140
+ (PyCFunction)@name@_complex,
2141
+ METH_VARARGS | METH_KEYWORDS, NULL},
2142
+ {NULL, NULL, 0, NULL}
2143
+ };
2144
+ /**end repeat**/
2145
+
2146
+ /************* As_mapping functions for void array scalar ************/
2147
+
2148
+ static Py_ssize_t
2149
+ voidtype_length(PyVoidScalarObject *self)
2150
+ {
2151
+ if (!PyDataType_HASFIELDS(self->descr)) {
2152
+ return 0;
2153
+ }
2154
+ else {
2155
+ /* return the number of fields */
2156
+ return (Py_ssize_t) PyTuple_GET_SIZE(self->descr->names);
2157
+ }
2158
+ }
2159
+
2160
+ static PyObject *
2161
+ voidtype_item(PyVoidScalarObject *self, Py_ssize_t n)
2162
+ {
2163
+ npy_intp m;
2164
+ PyObject *flist=NULL, *fieldind, *fieldparam, *fieldinfo, *ret;
2165
+
2166
+ if (!(PyDataType_HASFIELDS(self->descr))) {
2167
+ PyErr_SetString(PyExc_IndexError,
2168
+ "can't index void scalar without fields");
2169
+ return NULL;
2170
+ }
2171
+ flist = self->descr->names;
2172
+ m = PyTuple_GET_SIZE(flist);
2173
+ if (n < 0) {
2174
+ n += m;
2175
+ }
2176
+ if (n < 0 || n >= m) {
2177
+ PyErr_Format(PyExc_IndexError, "invalid index (%d)", (int) n);
2178
+ return NULL;
2179
+ }
2180
+ /* no error checking needed: descr->names is well structured */
2181
+ fieldind = PyTuple_GET_ITEM(flist, n);
2182
+ fieldparam = PyDict_GetItem(self->descr->fields, fieldind);
2183
+ fieldinfo = PyTuple_GetSlice(fieldparam, 0, 2);
2184
+ ret = voidtype_getfield(self, fieldinfo, NULL);
2185
+ Py_DECREF(fieldinfo);
2186
+ return ret;
2187
+ }
2188
+
2189
+
2190
+ /* get field by name or number */
2191
+ static PyObject *
2192
+ voidtype_subscript(PyVoidScalarObject *self, PyObject *ind)
2193
+ {
2194
+ npy_intp n;
2195
+ PyObject *ret, *fieldinfo, *fieldparam;
2196
+
2197
+ if (!(PyDataType_HASFIELDS(self->descr))) {
2198
+ PyErr_SetString(PyExc_IndexError,
2199
+ "can't index void scalar without fields");
2200
+ return NULL;
2201
+ }
2202
+
2203
+ #if defined(NPY_PY3K)
2204
+ if (PyUString_Check(ind)) {
2205
+ #else
2206
+ if (PyBytes_Check(ind) || PyUnicode_Check(ind)) {
2207
+ #endif
2208
+ /* look up in fields */
2209
+ fieldparam = PyDict_GetItem(self->descr->fields, ind);
2210
+ if (!fieldparam) {
2211
+ goto fail;
2212
+ }
2213
+ fieldinfo = PyTuple_GetSlice(fieldparam, 0, 2);
2214
+ ret = voidtype_getfield(self, fieldinfo, NULL);
2215
+ Py_DECREF(fieldinfo);
2216
+ return ret;
2217
+ }
2218
+
2219
+ /* try to convert it to a number */
2220
+ n = PyArray_PyIntAsIntp(ind);
2221
+ if (error_converting(n)) {
2222
+ goto fail;
2223
+ }
2224
+ return voidtype_item(self, (Py_ssize_t)n);
2225
+
2226
+ fail:
2227
+ PyErr_SetString(PyExc_IndexError, "invalid index");
2228
+ return NULL;
2229
+ }
2230
+
2231
+ static int
2232
+ voidtype_ass_item(PyVoidScalarObject *self, Py_ssize_t n, PyObject *val)
2233
+ {
2234
+ npy_intp m;
2235
+ PyObject *flist=NULL, *fieldinfo, *newtup;
2236
+ PyObject *res;
2237
+
2238
+ if (!(PyDataType_HASFIELDS(self->descr))) {
2239
+ PyErr_SetString(PyExc_IndexError,
2240
+ "can't index void scalar without fields");
2241
+ return -1;
2242
+ }
2243
+
2244
+ flist = self->descr->names;
2245
+ m = PyTuple_GET_SIZE(flist);
2246
+ if (n < 0) {
2247
+ n += m;
2248
+ }
2249
+ if (n < 0 || n >= m) {
2250
+ goto fail;
2251
+ }
2252
+ fieldinfo = PyDict_GetItem(self->descr->fields,
2253
+ PyTuple_GET_ITEM(flist, n));
2254
+ newtup = Py_BuildValue("(OOO)", val,
2255
+ PyTuple_GET_ITEM(fieldinfo, 0),
2256
+ PyTuple_GET_ITEM(fieldinfo, 1));
2257
+ res = voidtype_setfield(self, newtup, NULL);
2258
+ Py_DECREF(newtup);
2259
+ if (!res) {
2260
+ return -1;
2261
+ }
2262
+ Py_DECREF(res);
2263
+ return 0;
2264
+
2265
+ fail:
2266
+ PyErr_Format(PyExc_IndexError, "invalid index (%d)", (int) n);
2267
+ return -1;
2268
+ }
2269
+
2270
+ static int
2271
+ voidtype_ass_subscript(PyVoidScalarObject *self, PyObject *ind, PyObject *val)
2272
+ {
2273
+ npy_intp n;
2274
+ char *msg = "invalid index";
2275
+ PyObject *fieldinfo, *newtup;
2276
+ PyObject *res;
2277
+
2278
+ if (!PyDataType_HASFIELDS(self->descr)) {
2279
+ PyErr_SetString(PyExc_IndexError,
2280
+ "can't index void scalar without fields");
2281
+ return -1;
2282
+ }
2283
+
2284
+ if (!val) {
2285
+ PyErr_SetString(PyExc_ValueError,
2286
+ "cannot delete scalar field");
2287
+ return -1;
2288
+ }
2289
+
2290
+ #if defined(NPY_PY3K)
2291
+ if (PyUString_Check(ind)) {
2292
+ #else
2293
+ if (PyBytes_Check(ind) || PyUnicode_Check(ind)) {
2294
+ #endif
2295
+ /* look up in fields */
2296
+ fieldinfo = PyDict_GetItem(self->descr->fields, ind);
2297
+ if (!fieldinfo) {
2298
+ goto fail;
2299
+ }
2300
+ newtup = Py_BuildValue("(OOO)", val,
2301
+ PyTuple_GET_ITEM(fieldinfo, 0),
2302
+ PyTuple_GET_ITEM(fieldinfo, 1));
2303
+ res = voidtype_setfield(self, newtup, NULL);
2304
+ Py_DECREF(newtup);
2305
+ if (!res) {
2306
+ return -1;
2307
+ }
2308
+ Py_DECREF(res);
2309
+ return 0;
2310
+ }
2311
+
2312
+ /* try to convert it to a number */
2313
+ n = PyArray_PyIntAsIntp(ind);
2314
+ if (error_converting(n)) {
2315
+ goto fail;
2316
+ }
2317
+ return voidtype_ass_item(self, (Py_ssize_t)n, val);
2318
+
2319
+ fail:
2320
+ PyErr_SetString(PyExc_IndexError, msg);
2321
+ return -1;
2322
+ }
2323
+
2324
+ static PyMappingMethods voidtype_as_mapping = {
2325
+ (lenfunc)voidtype_length, /*mp_length*/
2326
+ (binaryfunc)voidtype_subscript, /*mp_subscript*/
2327
+ (objobjargproc)voidtype_ass_subscript, /*mp_ass_subscript*/
2328
+ };
2329
+
2330
+
2331
+ static PySequenceMethods voidtype_as_sequence = {
2332
+ (lenfunc)voidtype_length, /*sq_length*/
2333
+ 0, /*sq_concat*/
2334
+ 0, /*sq_repeat*/
2335
+ (ssizeargfunc)voidtype_item, /*sq_item*/
2336
+ 0, /*sq_slice*/
2337
+ (ssizeobjargproc)voidtype_ass_item, /*sq_ass_item*/
2338
+ 0, /* ssq_ass_slice */
2339
+ 0, /* sq_contains */
2340
+ 0, /* sq_inplace_concat */
2341
+ 0, /* sq_inplace_repeat */
2342
+ };
2343
+
2344
+
2345
+ static Py_ssize_t
2346
+ gentype_getreadbuf(PyObject *self, Py_ssize_t segment, void **ptrptr)
2347
+ {
2348
+ int numbytes;
2349
+ PyArray_Descr *outcode;
2350
+
2351
+ if (segment != 0) {
2352
+ PyErr_SetString(PyExc_SystemError,
2353
+ "Accessing non-existent array segment");
2354
+ return -1;
2355
+ }
2356
+
2357
+ outcode = PyArray_DescrFromScalar(self);
2358
+ numbytes = outcode->elsize;
2359
+ *ptrptr = (void *)scalar_value(self, outcode);
2360
+
2361
+ #ifndef Py_UNICODE_WIDE
2362
+ if (outcode->type_num == NPY_UNICODE) {
2363
+ numbytes >>= 1;
2364
+ }
2365
+ #endif
2366
+ Py_DECREF(outcode);
2367
+ return numbytes;
2368
+ }
2369
+
2370
+ #if !defined(NPY_PY3K)
2371
+ static Py_ssize_t
2372
+ gentype_getsegcount(PyObject *self, Py_ssize_t *lenp)
2373
+ {
2374
+ PyArray_Descr *outcode;
2375
+
2376
+ outcode = PyArray_DescrFromScalar(self);
2377
+ if (lenp) {
2378
+ *lenp = outcode->elsize;
2379
+ #ifndef Py_UNICODE_WIDE
2380
+ if (outcode->type_num == NPY_UNICODE) {
2381
+ *lenp >>= 1;
2382
+ }
2383
+ #endif
2384
+ }
2385
+ Py_DECREF(outcode);
2386
+ return 1;
2387
+ }
2388
+
2389
+ static Py_ssize_t
2390
+ gentype_getcharbuf(PyObject *self, Py_ssize_t segment, constchar **ptrptr)
2391
+ {
2392
+ if (PyArray_IsScalar(self, String) ||
2393
+ PyArray_IsScalar(self, Unicode)) {
2394
+ return gentype_getreadbuf(self, segment, (void **)ptrptr);
2395
+ }
2396
+ else {
2397
+ PyErr_SetString(PyExc_TypeError,
2398
+ "Non-character array cannot be interpreted "\
2399
+ "as character buffer.");
2400
+ return -1;
2401
+ }
2402
+ }
2403
+ #endif /* !defined(NPY_PY3K) */
2404
+
2405
+
2406
+ static int
2407
+ gentype_getbuffer(PyObject *self, Py_buffer *view, int flags)
2408
+ {
2409
+ Py_ssize_t len;
2410
+ void *buf;
2411
+
2412
+ /* FIXME: XXX: the format is not implemented! -- this needs more work */
2413
+
2414
+ len = gentype_getreadbuf(self, 0, &buf);
2415
+ return PyBuffer_FillInfo(view, self, buf, len, 1, flags);
2416
+ }
2417
+
2418
+ /* releasebuffer is not needed */
2419
+
2420
+
2421
+ static PyBufferProcs gentype_as_buffer = {
2422
+ #if !defined(NPY_PY3K)
2423
+ gentype_getreadbuf, /* bf_getreadbuffer*/
2424
+ NULL, /* bf_getwritebuffer*/
2425
+ gentype_getsegcount, /* bf_getsegcount*/
2426
+ gentype_getcharbuf, /* bf_getcharbuffer*/
2427
+ #endif
2428
+ gentype_getbuffer, /* bf_getbuffer */
2429
+ NULL, /* bf_releasebuffer */
2430
+ };
2431
+
2432
+
2433
+ #if defined(NPY_PY3K)
2434
+ #define BASEFLAGS Py_TPFLAGS_DEFAULT | Py_TPFLAGS_BASETYPE
2435
+ #define LEAFFLAGS Py_TPFLAGS_DEFAULT
2436
+ #else
2437
+ #define BASEFLAGS Py_TPFLAGS_DEFAULT | Py_TPFLAGS_BASETYPE | Py_TPFLAGS_CHECKTYPES
2438
+ #define LEAFFLAGS Py_TPFLAGS_DEFAULT | Py_TPFLAGS_CHECKTYPES
2439
+ #endif
2440
+
2441
+ NPY_NO_EXPORT PyTypeObject PyGenericArrType_Type = {
2442
+ #if defined(NPY_PY3K)
2443
+ PyVarObject_HEAD_INIT(NULL, 0)
2444
+ #else
2445
+ PyObject_HEAD_INIT(NULL)
2446
+ 0, /* ob_size */
2447
+ #endif
2448
+ "numpy.generic", /* tp_name*/
2449
+ sizeof(PyObject), /* tp_basicsize*/
2450
+ 0, /* tp_itemsize */
2451
+ /* methods */
2452
+ 0, /* tp_dealloc */
2453
+ 0, /* tp_print */
2454
+ 0, /* tp_getattr */
2455
+ 0, /* tp_setattr */
2456
+ #if defined(NPY_PY3K)
2457
+ 0, /* tp_reserved */
2458
+ #else
2459
+ 0, /* tp_compare */
2460
+ #endif
2461
+ 0, /* tp_repr */
2462
+ 0, /* tp_as_number */
2463
+ 0, /* tp_as_sequence */
2464
+ 0, /* tp_as_mapping */
2465
+ 0, /* tp_hash */
2466
+ 0, /* tp_call */
2467
+ 0, /* tp_str */
2468
+ 0, /* tp_getattro */
2469
+ 0, /* tp_setattro */
2470
+ 0, /* tp_as_buffer */
2471
+ 0, /* tp_flags */
2472
+ 0, /* tp_doc */
2473
+ 0, /* tp_traverse */
2474
+ 0, /* tp_clear */
2475
+ 0, /* tp_richcompare */
2476
+ 0, /* tp_weaklistoffset */
2477
+ 0, /* tp_iter */
2478
+ 0, /* tp_iternext */
2479
+ 0, /* tp_methods */
2480
+ 0, /* tp_members */
2481
+ 0, /* tp_getset */
2482
+ 0, /* tp_base */
2483
+ 0, /* tp_dict */
2484
+ 0, /* tp_descr_get */
2485
+ 0, /* tp_descr_set */
2486
+ 0, /* tp_dictoffset */
2487
+ 0, /* tp_init */
2488
+ 0, /* tp_alloc */
2489
+ 0, /* tp_new */
2490
+ 0, /* tp_free */
2491
+ 0, /* tp_is_gc */
2492
+ 0, /* tp_bases */
2493
+ 0, /* tp_mro */
2494
+ 0, /* tp_cache */
2495
+ 0, /* tp_subclasses */
2496
+ 0, /* tp_weaklist */
2497
+ 0, /* tp_del */
2498
+ 0, /* tp_version_tag */
2499
+ };
2500
+
2501
+ static void
2502
+ void_dealloc(PyVoidScalarObject *v)
2503
+ {
2504
+ if (v->flags & NPY_ARRAY_OWNDATA) {
2505
+ PyDataMem_FREE(v->obval);
2506
+ }
2507
+ Py_XDECREF(v->descr);
2508
+ Py_XDECREF(v->base);
2509
+ Py_TYPE(v)->tp_free(v);
2510
+ }
2511
+
2512
+ static void
2513
+ object_arrtype_dealloc(PyObject *v)
2514
+ {
2515
+ Py_XDECREF(((PyObjectScalarObject *)v)->obval);
2516
+ Py_TYPE(v)->tp_free(v);
2517
+ }
2518
+
2519
+ /*
2520
+ * string and unicode inherit from Python Type first and so GET_ITEM
2521
+ * is different to get to the Python Type.
2522
+ *
2523
+ * ok is a work-around for a bug in complex_new that doesn't allocate
2524
+ * memory from the sub-types memory allocator.
2525
+ */
2526
+
2527
+ #define _WORK(num) \
2528
+ if (type->tp_bases && (PyTuple_GET_SIZE(type->tp_bases)==2)) { \
2529
+ PyTypeObject *sup; \
2530
+ /* We are inheriting from a Python type as well so \
2531
+ give it first dibs on conversion */ \
2532
+ sup = (PyTypeObject *)PyTuple_GET_ITEM(type->tp_bases, num); \
2533
+ /* Prevent recursion */ \
2534
+ if (thisfunc != sup->tp_new) { \
2535
+ robj = sup->tp_new(type, args, kwds); \
2536
+ if (robj != NULL) goto finish; \
2537
+ if (PyTuple_GET_SIZE(args)!=1) return NULL; \
2538
+ PyErr_Clear(); \
2539
+ } \
2540
+ /* now do default conversion */ \
2541
+ }
2542
+
2543
+ #define _WORK1 _WORK(1)
2544
+ #define _WORKz _WORK(0)
2545
+ #define _WORK0
2546
+
2547
+ /**begin repeat
2548
+ * #name = byte, short, int, long, longlong, ubyte, ushort, uint, ulong,
2549
+ * ulonglong, half, float, double, longdouble, cfloat, cdouble,
2550
+ * clongdouble, string, unicode, object#
2551
+ * #Name = Byte, Short, Int, Long, LongLong, UByte, UShort, UInt, ULong,
2552
+ * ULongLong, Half, Float, Double, LongDouble, CFloat, CDouble,
2553
+ * CLongDouble, String, Unicode, Object#
2554
+ * #TYPE = BYTE, SHORT, INT, LONG, LONGLONG, UBYTE, USHORT, UINT, ULONG,
2555
+ * ULONGLONG, HALF, FLOAT, DOUBLE, LONGDOUBLE, CFLOAT, CDOUBLE,
2556
+ * CLONGDOUBLE, STRING, UNICODE, OBJECT#
2557
+ * #work = 0,0,1,1,1,0,0,0,0,0,0,0,1,0,0,0,0,z,z,0#
2558
+ * #default = 0*17,1*2,2#
2559
+ */
2560
+
2561
+ #define _NPY_UNUSED2_1
2562
+ #define _NPY_UNUSED2_z
2563
+ #define _NPY_UNUSED2_0 NPY_UNUSED
2564
+ #define _NPY_UNUSED1_0
2565
+ #define _NPY_UNUSED1_1
2566
+ #define _NPY_UNUSED1_2 NPY_UNUSED
2567
+
2568
+ static PyObject *
2569
+ @name@_arrtype_new(PyTypeObject *_NPY_UNUSED1_@default@(type), PyObject *args, PyObject *_NPY_UNUSED2_@work@(kwds))
2570
+ {
2571
+ PyObject *obj = NULL;
2572
+ PyObject *robj;
2573
+ PyArrayObject *arr;
2574
+ PyArray_Descr *typecode = NULL;
2575
+ #if (@work@ != 0) || (@default@ == 1)
2576
+ void *thisfunc = (void *)@name@_arrtype_new;
2577
+ #endif
2578
+ #if !(@default@ == 2)
2579
+ int itemsize;
2580
+ void *dest, *src;
2581
+ #endif
2582
+
2583
+ /*
2584
+ * allow base-class (if any) to do conversion
2585
+ * If successful, this will jump to finish:
2586
+ */
2587
+ _WORK@work@
2588
+
2589
+ if (!PyArg_ParseTuple(args, "|O", &obj)) {
2590
+ return NULL;
2591
+ }
2592
+ typecode = PyArray_DescrFromType(NPY_@TYPE@);
2593
+ if (typecode == NULL) {
2594
+ return NULL;
2595
+ }
2596
+ /*
2597
+ * typecode is new reference and stolen by
2598
+ * PyArray_FromAny but not PyArray_Scalar
2599
+ */
2600
+ if (obj == NULL) {
2601
+ #if @default@ == 0
2602
+ robj = PyArray_Scalar(NULL, typecode, NULL);
2603
+ if (robj == NULL) {
2604
+ Py_DECREF(typecode);
2605
+ return NULL;
2606
+ }
2607
+ memset(&((Py@Name@ScalarObject *)robj)->obval, 0, sizeof(npy_@name@));
2608
+ #elif @default@ == 1
2609
+ robj = PyArray_Scalar(NULL, typecode, NULL);
2610
+ #elif @default@ == 2
2611
+ Py_INCREF(Py_None);
2612
+ robj = Py_None;
2613
+ #endif
2614
+ Py_DECREF(typecode);
2615
+ goto finish;
2616
+ }
2617
+
2618
+ /*
2619
+ * It is expected at this point that robj is a PyArrayScalar
2620
+ * (even for Object Data Type)
2621
+ */
2622
+ arr = (PyArrayObject *)PyArray_FromAny(obj, typecode,
2623
+ 0, 0, NPY_ARRAY_FORCECAST, NULL);
2624
+ if ((arr == NULL) || (PyArray_NDIM(arr) > 0)) {
2625
+ return (PyObject *)arr;
2626
+ }
2627
+ /* 0-d array */
2628
+ robj = PyArray_ToScalar(PyArray_DATA(arr), arr);
2629
+ Py_DECREF(arr);
2630
+
2631
+ finish:
2632
+ /*
2633
+ * In OBJECT case, robj is no longer a
2634
+ * PyArrayScalar at this point but the
2635
+ * remaining code assumes it is
2636
+ */
2637
+ #if @default@ == 2
2638
+ return robj;
2639
+ #else
2640
+ /* Normal return */
2641
+ if ((robj == NULL) || (Py_TYPE(robj) == type)) {
2642
+ return robj;
2643
+ }
2644
+
2645
+ /*
2646
+ * This return path occurs when the requested type is not created
2647
+ * but another scalar object is created instead (i.e. when
2648
+ * the base-class does the conversion in _WORK macro)
2649
+ */
2650
+
2651
+ /* Need to allocate new type and copy data-area over */
2652
+ if (type->tp_itemsize) {
2653
+ itemsize = PyBytes_GET_SIZE(robj);
2654
+ }
2655
+ else {
2656
+ itemsize = 0;
2657
+ }
2658
+ obj = type->tp_alloc(type, itemsize);
2659
+ if (obj == NULL) {
2660
+ Py_DECREF(robj);
2661
+ return NULL;
2662
+ }
2663
+ /* typecode will be NULL */
2664
+ typecode = PyArray_DescrFromType(NPY_@TYPE@);
2665
+ dest = scalar_value(obj, typecode);
2666
+ src = scalar_value(robj, typecode);
2667
+ Py_DECREF(typecode);
2668
+ #if @default@ == 0
2669
+ *((npy_@name@ *)dest) = *((npy_@name@ *)src);
2670
+ #elif @default@ == 1 /* unicode and strings */
2671
+ if (itemsize == 0) { /* unicode */
2672
+ #if PY_VERSION_HEX >= 0x03030000
2673
+ itemsize = PyUnicode_GetLength(robj) * PyUnicode_KIND(robj);
2674
+ #else
2675
+ itemsize = ((PyUnicodeObject *)robj)->length * sizeof(Py_UNICODE);
2676
+ #endif
2677
+ }
2678
+ memcpy(dest, src, itemsize);
2679
+ /* @default@ == 2 won't get here */
2680
+ #endif
2681
+ Py_DECREF(robj);
2682
+ return obj;
2683
+ #endif
2684
+ }
2685
+ /**end repeat**/
2686
+
2687
+ #undef _WORK1
2688
+ #undef _WORKz
2689
+ #undef _WORK0
2690
+ #undef _WORK
2691
+
2692
+ /**begin repeat
2693
+ * #name = datetime, timedelta#
2694
+ * #Name = Datetime, Timedelta#
2695
+ * #NAME = DATETIME, TIMEDELTA#
2696
+ * #is_datetime = 1, 0#
2697
+ */
2698
+
2699
+ static PyObject *
2700
+ @name@_arrtype_new(PyTypeObject *type, PyObject *args, PyObject *kwds)
2701
+ {
2702
+ PyObject *obj = NULL, *meta_obj = NULL;
2703
+ Py@Name@ScalarObject *ret;
2704
+
2705
+ if (!PyArg_ParseTuple(args, "|OO", &obj, &meta_obj)) {
2706
+ return NULL;
2707
+ }
2708
+
2709
+ /* Allocate the return scalar */
2710
+ ret = (Py@Name@ScalarObject *)Py@Name@ArrType_Type.tp_alloc(
2711
+ &Py@Name@ArrType_Type, 0);
2712
+ if (ret == NULL) {
2713
+ return NULL;
2714
+ }
2715
+
2716
+ /* Incorporate the metadata if its provided */
2717
+ if (meta_obj != NULL) {
2718
+ /* Parse the provided metadata input */
2719
+ if (convert_pyobject_to_datetime_metadata(meta_obj, &ret->obmeta)
2720
+ < 0) {
2721
+ Py_DECREF(ret);
2722
+ return NULL;
2723
+ }
2724
+ }
2725
+ else {
2726
+ /*
2727
+ * A unit of -1 signals that convert_pyobject_to_datetime
2728
+ * should populate.
2729
+ */
2730
+ ret->obmeta.base = -1;
2731
+ }
2732
+
2733
+ if (obj == NULL) {
2734
+ if (ret->obmeta.base == -1) {
2735
+ ret->obmeta.base = NPY_DATETIME_DEFAULTUNIT;
2736
+ ret->obmeta.num = 1;
2737
+ }
2738
+
2739
+ /* Make datetime default to NaT, timedelta default to zero */
2740
+ #if @is_datetime@
2741
+ ret->obval = NPY_DATETIME_NAT;
2742
+ #else
2743
+ ret->obval = 0;
2744
+ #endif
2745
+ }
2746
+ else if (convert_pyobject_to_@name@(&ret->obmeta, obj,
2747
+ NPY_SAME_KIND_CASTING, &ret->obval) < 0) {
2748
+ Py_DECREF(ret);
2749
+ return NULL;
2750
+ }
2751
+
2752
+ return (PyObject *)ret;
2753
+ }
2754
+ /**end repeat**/
2755
+
2756
+ /* bool->tp_new only returns Py_True or Py_False */
2757
+ static PyObject *
2758
+ bool_arrtype_new(PyTypeObject *NPY_UNUSED(type), PyObject *args, PyObject *NPY_UNUSED(kwds))
2759
+ {
2760
+ PyObject *obj = NULL;
2761
+ PyArrayObject *arr;
2762
+
2763
+ if (!PyArg_ParseTuple(args, "|O", &obj)) {
2764
+ return NULL;
2765
+ }
2766
+ if (obj == NULL) {
2767
+ PyArrayScalar_RETURN_FALSE;
2768
+ }
2769
+ if (obj == Py_False) {
2770
+ PyArrayScalar_RETURN_FALSE;
2771
+ }
2772
+ if (obj == Py_True) {
2773
+ PyArrayScalar_RETURN_TRUE;
2774
+ }
2775
+ arr = (PyArrayObject *)PyArray_FROM_OTF(obj,
2776
+ NPY_BOOL, NPY_ARRAY_FORCECAST);
2777
+ if (arr && 0 == PyArray_NDIM(arr)) {
2778
+ npy_bool val = *((npy_bool *)PyArray_DATA(arr));
2779
+ Py_DECREF(arr);
2780
+ PyArrayScalar_RETURN_BOOL_FROM_LONG(val);
2781
+ }
2782
+ return PyArray_Return((PyArrayObject *)arr);
2783
+ }
2784
+
2785
+ static PyObject *
2786
+ bool_arrtype_and(PyObject *a, PyObject *b)
2787
+ {
2788
+ if (PyArray_IsScalar(a, Bool) && PyArray_IsScalar(b, Bool)) {
2789
+ PyArrayScalar_RETURN_BOOL_FROM_LONG
2790
+ ((a == PyArrayScalar_True) & (b == PyArrayScalar_True));
2791
+ }
2792
+ return PyGenericArrType_Type.tp_as_number->nb_and(a, b);
2793
+ }
2794
+
2795
+ static PyObject *
2796
+ bool_arrtype_or(PyObject *a, PyObject *b)
2797
+ {
2798
+ if (PyArray_IsScalar(a, Bool) && PyArray_IsScalar(b, Bool)) {
2799
+ PyArrayScalar_RETURN_BOOL_FROM_LONG
2800
+ ((a == PyArrayScalar_True)|(b == PyArrayScalar_True));
2801
+ }
2802
+ return PyGenericArrType_Type.tp_as_number->nb_or(a, b);
2803
+ }
2804
+
2805
+ static PyObject *
2806
+ bool_arrtype_xor(PyObject *a, PyObject *b)
2807
+ {
2808
+ if (PyArray_IsScalar(a, Bool) && PyArray_IsScalar(b, Bool)) {
2809
+ PyArrayScalar_RETURN_BOOL_FROM_LONG
2810
+ ((a == PyArrayScalar_True)^(b == PyArrayScalar_True));
2811
+ }
2812
+ return PyGenericArrType_Type.tp_as_number->nb_xor(a, b);
2813
+ }
2814
+
2815
+ static int
2816
+ bool_arrtype_nonzero(PyObject *a)
2817
+ {
2818
+ return a == PyArrayScalar_True;
2819
+ }
2820
+
2821
+ /**begin repeat
2822
+ * #name = byte, short, int, long, ubyte, ushort, longlong, uint,
2823
+ * ulong, ulonglong#
2824
+ * #Name = Byte, Short, Int, Long, UByte, UShort, LongLong, UInt,
2825
+ * ULong, ULongLong#
2826
+ * #type = PyInt_FromLong*6, PyLong_FromLongLong*1,
2827
+ * PyLong_FromUnsignedLong*2, PyLong_FromUnsignedLongLong#
2828
+ */
2829
+ static PyNumberMethods @name@_arrtype_as_number;
2830
+ static PyObject *
2831
+ @name@_index(PyObject *self)
2832
+ {
2833
+ return @type@(PyArrayScalar_VAL(self, @Name@));
2834
+ }
2835
+ /**end repeat**/
2836
+
2837
+ static PyObject *
2838
+ bool_index(PyObject *a)
2839
+ {
2840
+ return PyInt_FromLong(PyArrayScalar_VAL(a, Bool));
2841
+ }
2842
+
2843
+ /* Arithmetic methods -- only so we can override &, |, ^. */
2844
+ NPY_NO_EXPORT PyNumberMethods bool_arrtype_as_number = {
2845
+ 0, /* nb_add */
2846
+ 0, /* nb_subtract */
2847
+ 0, /* nb_multiply */
2848
+ #if defined(NPY_PY3K)
2849
+ #else
2850
+ 0, /* nb_divide */
2851
+ #endif
2852
+ 0, /* nb_remainder */
2853
+ 0, /* nb_divmod */
2854
+ 0, /* nb_power */
2855
+ 0, /* nb_negative */
2856
+ 0, /* nb_positive */
2857
+ 0, /* nb_absolute */
2858
+ (inquiry)bool_arrtype_nonzero, /* nb_nonzero / nb_bool */
2859
+ 0, /* nb_invert */
2860
+ 0, /* nb_lshift */
2861
+ 0, /* nb_rshift */
2862
+ (binaryfunc)bool_arrtype_and, /* nb_and */
2863
+ (binaryfunc)bool_arrtype_xor, /* nb_xor */
2864
+ (binaryfunc)bool_arrtype_or, /* nb_or */
2865
+ #if defined(NPY_PY3K)
2866
+ #else
2867
+ 0, /* nb_coerce */
2868
+ #endif
2869
+ 0, /* nb_int */
2870
+ #if defined(NPY_PY3K)
2871
+ 0, /* nb_reserved */
2872
+ #else
2873
+ 0, /* nb_long */
2874
+ #endif
2875
+ 0, /* nb_float */
2876
+ #if defined(NPY_PY3K)
2877
+ #else
2878
+ 0, /* nb_oct */
2879
+ 0, /* nb_hex */
2880
+ #endif
2881
+ /* Added in release 2.0 */
2882
+ 0, /* nb_inplace_add */
2883
+ 0, /* nb_inplace_subtract */
2884
+ 0, /* nb_inplace_multiply */
2885
+ #if defined(NPY_PY3K)
2886
+ #else
2887
+ 0, /* nb_inplace_divide */
2888
+ #endif
2889
+ 0, /* nb_inplace_remainder */
2890
+ 0, /* nb_inplace_power */
2891
+ 0, /* nb_inplace_lshift */
2892
+ 0, /* nb_inplace_rshift */
2893
+ 0, /* nb_inplace_and */
2894
+ 0, /* nb_inplace_xor */
2895
+ 0, /* nb_inplace_or */
2896
+ /* Added in release 2.2 */
2897
+ /* The following require the Py_TPFLAGS_HAVE_CLASS flag */
2898
+ 0, /* nb_floor_divide */
2899
+ 0, /* nb_true_divide */
2900
+ 0, /* nb_inplace_floor_divide */
2901
+ 0, /* nb_inplace_true_divide */
2902
+ /* Added in release 2.5 */
2903
+ 0, /* nb_index */
2904
+ };
2905
+
2906
+ static PyObject *
2907
+ void_arrtype_new(PyTypeObject *type, PyObject *args, PyObject *NPY_UNUSED(kwds))
2908
+ {
2909
+ PyObject *obj, *arr;
2910
+ npy_ulonglong memu = 1;
2911
+ PyObject *new = NULL;
2912
+ char *destptr;
2913
+
2914
+ if (!PyArg_ParseTuple(args, "O", &obj)) {
2915
+ return NULL;
2916
+ }
2917
+ /*
2918
+ * For a VOID scalar first see if obj is an integer or long
2919
+ * and create new memory of that size (filled with 0) for the scalar
2920
+ */
2921
+ if (PyLong_Check(obj) || PyInt_Check(obj) ||
2922
+ PyArray_IsScalar(obj, Integer) ||
2923
+ (PyArray_Check(obj) &&
2924
+ PyArray_NDIM((PyArrayObject *)obj)==0 &&
2925
+ PyArray_ISINTEGER((PyArrayObject *)obj))) {
2926
+ #if defined(NPY_PY3K)
2927
+ new = Py_TYPE(obj)->tp_as_number->nb_int(obj);
2928
+ #else
2929
+ new = Py_TYPE(obj)->tp_as_number->nb_long(obj);
2930
+ #endif
2931
+ }
2932
+ if (new && PyLong_Check(new)) {
2933
+ PyObject *ret;
2934
+ memu = PyLong_AsUnsignedLongLong(new);
2935
+ Py_DECREF(new);
2936
+ if (PyErr_Occurred() || (memu > NPY_MAX_INT)) {
2937
+ PyErr_Clear();
2938
+ PyErr_Format(PyExc_OverflowError,
2939
+ "size cannot be greater than %d",
2940
+ (int) NPY_MAX_INT);
2941
+ return NULL;
2942
+ }
2943
+ destptr = PyDataMem_NEW((int) memu);
2944
+ if (destptr == NULL) {
2945
+ return PyErr_NoMemory();
2946
+ }
2947
+ ret = type->tp_alloc(type, 0);
2948
+ if (ret == NULL) {
2949
+ PyDataMem_FREE(destptr);
2950
+ return PyErr_NoMemory();
2951
+ }
2952
+ ((PyVoidScalarObject *)ret)->obval = destptr;
2953
+ Py_SIZE((PyVoidScalarObject *)ret) = (int) memu;
2954
+ ((PyVoidScalarObject *)ret)->descr =
2955
+ PyArray_DescrNewFromType(NPY_VOID);
2956
+ ((PyVoidScalarObject *)ret)->descr->elsize = (int) memu;
2957
+ ((PyVoidScalarObject *)ret)->flags = NPY_ARRAY_BEHAVED |
2958
+ NPY_ARRAY_OWNDATA;
2959
+ ((PyVoidScalarObject *)ret)->base = NULL;
2960
+ memset(destptr, '\0', (size_t) memu);
2961
+ return ret;
2962
+ }
2963
+
2964
+ arr = PyArray_FROM_OTF(obj, NPY_VOID, NPY_ARRAY_FORCECAST);
2965
+ return PyArray_Return((PyArrayObject *)arr);
2966
+ }
2967
+
2968
+
2969
+ /**************** Define Hash functions ********************/
2970
+
2971
+ /**begin repeat
2972
+ * #lname = bool, ubyte, ushort#
2973
+ * #name = Bool,UByte, UShort#
2974
+ */
2975
+ static npy_hash_t
2976
+ @lname@_arrtype_hash(PyObject *obj)
2977
+ {
2978
+ return (npy_hash_t)(((Py@name@ScalarObject *)obj)->obval);
2979
+ }
2980
+ /**end repeat**/
2981
+
2982
+ /**begin repeat
2983
+ * #lname = byte, short, uint#
2984
+ * #name = Byte, Short, UInt#
2985
+ */
2986
+ static npy_hash_t
2987
+ @lname@_arrtype_hash(PyObject *obj)
2988
+ {
2989
+ npy_hash_t x = (npy_hash_t)(((Py@name@ScalarObject *)obj)->obval);
2990
+ if (x == -1) {
2991
+ x = -2;
2992
+ }
2993
+ return x;
2994
+ }
2995
+ /**end repeat**/
2996
+
2997
+ static npy_hash_t
2998
+ ulong_arrtype_hash(PyObject *obj)
2999
+ {
3000
+ PyObject * l = PyLong_FromUnsignedLong(((PyULongScalarObject*)obj)->obval);
3001
+ npy_hash_t x = PyObject_Hash(l);
3002
+ Py_DECREF(l);
3003
+ return x;
3004
+ }
3005
+
3006
+ #if (NPY_SIZEOF_INT != NPY_SIZEOF_LONG) || defined(NPY_PY3K)
3007
+ static npy_hash_t
3008
+ int_arrtype_hash(PyObject *obj)
3009
+ {
3010
+ npy_hash_t x = (npy_hash_t)(((PyIntScalarObject *)obj)->obval);
3011
+ if (x == -1) {
3012
+ x = -2;
3013
+ }
3014
+ return x;
3015
+ }
3016
+ #endif
3017
+
3018
+ #if defined(NPY_PY3K)
3019
+ static npy_hash_t
3020
+ long_arrtype_hash(PyObject *obj)
3021
+ {
3022
+ PyObject * l = PyLong_FromLong(((PyLongScalarObject*)obj)->obval);
3023
+ npy_hash_t x = PyObject_Hash(l);
3024
+ Py_DECREF(l);
3025
+ return x;
3026
+ }
3027
+ #endif
3028
+
3029
+ /**begin repeat
3030
+ * #char = ,u#
3031
+ * #Char = ,U#
3032
+ * #Word = ,Unsigned#
3033
+ */
3034
+ static NPY_INLINE npy_hash_t
3035
+ @char@longlong_arrtype_hash(PyObject *obj)
3036
+ {
3037
+ PyObject * l = PyLong_From@Word@LongLong(
3038
+ ((Py@Char@LongLongScalarObject*)obj)->obval);
3039
+ npy_hash_t x = PyObject_Hash(l);
3040
+ Py_DECREF(l);
3041
+ return x;
3042
+ }
3043
+ /**end repeat**/
3044
+
3045
+
3046
+ /**begin repeat
3047
+ * #lname = datetime, timedelta#
3048
+ * #name = Datetime, Timedelta#
3049
+ */
3050
+ #if NPY_SIZEOF_HASH_T==NPY_SIZEOF_DATETIME
3051
+ static npy_hash_t
3052
+ @lname@_arrtype_hash(PyObject *obj)
3053
+ {
3054
+ npy_hash_t x = (npy_hash_t)(((Py@name@ScalarObject *)obj)->obval);
3055
+ if (x == -1) {
3056
+ x = -2;
3057
+ }
3058
+ return x;
3059
+ }
3060
+ #elif NPY_SIZEOF_LONGLONG==NPY_SIZEOF_DATETIME
3061
+ static npy_hash_t
3062
+ @lname@_arrtype_hash(PyObject *obj)
3063
+ {
3064
+ npy_hash_t y;
3065
+ npy_longlong x = (((Py@name@ScalarObject *)obj)->obval);
3066
+
3067
+ if ((x <= LONG_MAX)) {
3068
+ y = (npy_hash_t) x;
3069
+ }
3070
+ else {
3071
+ union Mask {
3072
+ long hashvals[2];
3073
+ npy_longlong v;
3074
+ } both;
3075
+
3076
+ both.v = x;
3077
+ y = both.hashvals[0] + (1000003)*both.hashvals[1];
3078
+ }
3079
+ if (y == -1) {
3080
+ y = -2;
3081
+ }
3082
+ return y;
3083
+ }
3084
+ #endif
3085
+ /**end repeat**/
3086
+
3087
+
3088
+
3089
+ /* Wrong thing to do for longdouble, but....*/
3090
+
3091
+ /**begin repeat
3092
+ * #lname = float, longdouble#
3093
+ * #name = Float, LongDouble#
3094
+ */
3095
+ static npy_hash_t
3096
+ @lname@_arrtype_hash(PyObject *obj)
3097
+ {
3098
+ return _Py_HashDouble((double) ((Py@name@ScalarObject *)obj)->obval);
3099
+ }
3100
+
3101
+ /* borrowed from complex_hash */
3102
+ static npy_hash_t
3103
+ c@lname@_arrtype_hash(PyObject *obj)
3104
+ {
3105
+ npy_hash_t hashreal, hashimag, combined;
3106
+ hashreal = _Py_HashDouble((double)
3107
+ (((PyC@name@ScalarObject *)obj)->obval).real);
3108
+
3109
+ if (hashreal == -1) {
3110
+ return -1;
3111
+ }
3112
+ hashimag = _Py_HashDouble((double)
3113
+ (((PyC@name@ScalarObject *)obj)->obval).imag);
3114
+ if (hashimag == -1) {
3115
+ return -1;
3116
+ }
3117
+ combined = hashreal + 1000003 * hashimag;
3118
+ if (combined == -1) {
3119
+ combined = -2;
3120
+ }
3121
+ return combined;
3122
+ }
3123
+ /**end repeat**/
3124
+
3125
+ static npy_hash_t
3126
+ half_arrtype_hash(PyObject *obj)
3127
+ {
3128
+ return _Py_HashDouble(npy_half_to_double(((PyHalfScalarObject *)obj)->obval));
3129
+ }
3130
+
3131
+ static npy_hash_t
3132
+ object_arrtype_hash(PyObject *obj)
3133
+ {
3134
+ return PyObject_Hash(((PyObjectScalarObject *)obj)->obval);
3135
+ }
3136
+
3137
+ /* we used to just hash the pointer */
3138
+ /* now use tuplehash algorithm using voidtype_item to get the object
3139
+ */
3140
+ static npy_hash_t
3141
+ void_arrtype_hash(PyObject *obj)
3142
+ {
3143
+ npy_hash_t x, y;
3144
+ Py_ssize_t len, n;
3145
+ PyVoidScalarObject *p;
3146
+ PyObject *element;
3147
+ npy_hash_t mult = 1000003L;
3148
+ x = 0x345678L;
3149
+ p = (PyVoidScalarObject *)obj;
3150
+ /* Cannot hash mutable void scalars */
3151
+ if (p->flags & NPY_ARRAY_WRITEABLE) {
3152
+ PyErr_SetString(PyExc_TypeError, "unhashable type: 'writeable void-scalar'");
3153
+ return -1;
3154
+ }
3155
+ len = voidtype_length(p);
3156
+ for (n=0; n < len; n++) {
3157
+ element = voidtype_item(p, n);
3158
+ y = PyObject_Hash(element);
3159
+ Py_DECREF(element);
3160
+ if (y == -1)
3161
+ return -1;
3162
+ x = (x ^ y) * mult;
3163
+ mult += (npy_hash_t)(82520L + len + len);
3164
+ }
3165
+ x += 97531L;
3166
+ if (x == -1)
3167
+ x = -2;
3168
+ return x;
3169
+ }
3170
+
3171
+ /*object arrtype getattro and setattro */
3172
+ static PyObject *
3173
+ object_arrtype_getattro(PyObjectScalarObject *obj, PyObject *attr) {
3174
+ PyObject *res;
3175
+
3176
+ /* first look in object and then hand off to generic type */
3177
+
3178
+ res = PyObject_GenericGetAttr(obj->obval, attr);
3179
+ if (res) {
3180
+ return res;
3181
+ }
3182
+ PyErr_Clear();
3183
+ return PyObject_GenericGetAttr((PyObject *)obj, attr);
3184
+ }
3185
+
3186
+ static int
3187
+ object_arrtype_setattro(PyObjectScalarObject *obj, PyObject *attr, PyObject *val) {
3188
+ int res;
3189
+ /* first look in object and then hand off to generic type */
3190
+
3191
+ res = PyObject_GenericSetAttr(obj->obval, attr, val);
3192
+ if (res >= 0) {
3193
+ return res;
3194
+ }
3195
+ PyErr_Clear();
3196
+ return PyObject_GenericSetAttr((PyObject *)obj, attr, val);
3197
+ }
3198
+
3199
+ static PyObject *
3200
+ object_arrtype_concat(PyObjectScalarObject *self, PyObject *other)
3201
+ {
3202
+ return PySequence_Concat(self->obval, other);
3203
+ }
3204
+
3205
+ static Py_ssize_t
3206
+ object_arrtype_length(PyObjectScalarObject *self)
3207
+ {
3208
+ return PyObject_Length(self->obval);
3209
+ }
3210
+
3211
+ static PyObject *
3212
+ object_arrtype_repeat(PyObjectScalarObject *self, Py_ssize_t count)
3213
+ {
3214
+ return PySequence_Repeat(self->obval, count);
3215
+ }
3216
+
3217
+ static PyObject *
3218
+ object_arrtype_subscript(PyObjectScalarObject *self, PyObject *key)
3219
+ {
3220
+ return PyObject_GetItem(self->obval, key);
3221
+ }
3222
+
3223
+ static int
3224
+ object_arrtype_ass_subscript(PyObjectScalarObject *self, PyObject *key,
3225
+ PyObject *value)
3226
+ {
3227
+ return PyObject_SetItem(self->obval, key, value);
3228
+ }
3229
+
3230
+ static int
3231
+ object_arrtype_contains(PyObjectScalarObject *self, PyObject *ob)
3232
+ {
3233
+ return PySequence_Contains(self->obval, ob);
3234
+ }
3235
+
3236
+ static PyObject *
3237
+ object_arrtype_inplace_concat(PyObjectScalarObject *self, PyObject *o)
3238
+ {
3239
+ return PySequence_InPlaceConcat(self->obval, o);
3240
+ }
3241
+
3242
+ static PyObject *
3243
+ object_arrtype_inplace_repeat(PyObjectScalarObject *self, Py_ssize_t count)
3244
+ {
3245
+ return PySequence_InPlaceRepeat(self->obval, count);
3246
+ }
3247
+
3248
+ static PySequenceMethods object_arrtype_as_sequence = {
3249
+ (lenfunc)object_arrtype_length, /*sq_length*/
3250
+ (binaryfunc)object_arrtype_concat, /*sq_concat*/
3251
+ (ssizeargfunc)object_arrtype_repeat, /*sq_repeat*/
3252
+ 0, /*sq_item*/
3253
+ 0, /*sq_slice*/
3254
+ 0, /* sq_ass_item */
3255
+ 0, /* sq_ass_slice */
3256
+ (objobjproc)object_arrtype_contains, /* sq_contains */
3257
+ (binaryfunc)object_arrtype_inplace_concat, /* sq_inplace_concat */
3258
+ (ssizeargfunc)object_arrtype_inplace_repeat, /* sq_inplace_repeat */
3259
+ };
3260
+
3261
+ static PyMappingMethods object_arrtype_as_mapping = {
3262
+ (lenfunc)object_arrtype_length,
3263
+ (binaryfunc)object_arrtype_subscript,
3264
+ (objobjargproc)object_arrtype_ass_subscript,
3265
+ };
3266
+
3267
+ #if !defined(NPY_PY3K)
3268
+ static Py_ssize_t
3269
+ object_arrtype_getsegcount(PyObjectScalarObject *self, Py_ssize_t *lenp)
3270
+ {
3271
+ Py_ssize_t newlen;
3272
+ int cnt;
3273
+ PyBufferProcs *pb = Py_TYPE(self->obval)->tp_as_buffer;
3274
+
3275
+ if (pb == NULL ||
3276
+ pb->bf_getsegcount == NULL ||
3277
+ (cnt = (*pb->bf_getsegcount)(self->obval, &newlen)) != 1) {
3278
+ return 0;
3279
+ }
3280
+ if (lenp) {
3281
+ *lenp = newlen;
3282
+ }
3283
+ return cnt;
3284
+ }
3285
+
3286
+ static Py_ssize_t
3287
+ object_arrtype_getreadbuf(PyObjectScalarObject *self, Py_ssize_t segment, void **ptrptr)
3288
+ {
3289
+ PyBufferProcs *pb = Py_TYPE(self->obval)->tp_as_buffer;
3290
+
3291
+ if (pb == NULL ||
3292
+ pb->bf_getreadbuffer == NULL ||
3293
+ pb->bf_getsegcount == NULL) {
3294
+ PyErr_SetString(PyExc_TypeError,
3295
+ "expected a readable buffer object");
3296
+ return -1;
3297
+ }
3298
+ return (*pb->bf_getreadbuffer)(self->obval, segment, ptrptr);
3299
+ }
3300
+
3301
+ static Py_ssize_t
3302
+ object_arrtype_getwritebuf(PyObjectScalarObject *self, Py_ssize_t segment, void **ptrptr)
3303
+ {
3304
+ PyBufferProcs *pb = Py_TYPE(self->obval)->tp_as_buffer;
3305
+
3306
+ if (pb == NULL ||
3307
+ pb->bf_getwritebuffer == NULL ||
3308
+ pb->bf_getsegcount == NULL) {
3309
+ PyErr_SetString(PyExc_TypeError,
3310
+ "expected a writeable buffer object");
3311
+ return -1;
3312
+ }
3313
+ return (*pb->bf_getwritebuffer)(self->obval, segment, ptrptr);
3314
+ }
3315
+
3316
+ static Py_ssize_t
3317
+ object_arrtype_getcharbuf(PyObjectScalarObject *self, Py_ssize_t segment,
3318
+ constchar **ptrptr)
3319
+ {
3320
+ PyBufferProcs *pb = Py_TYPE(self->obval)->tp_as_buffer;
3321
+
3322
+ if (pb == NULL ||
3323
+ pb->bf_getcharbuffer == NULL ||
3324
+ pb->bf_getsegcount == NULL) {
3325
+ PyErr_SetString(PyExc_TypeError,
3326
+ "expected a character buffer object");
3327
+ return -1;
3328
+ }
3329
+ return (*pb->bf_getcharbuffer)(self->obval, segment, ptrptr);
3330
+ }
3331
+ #endif
3332
+
3333
+ static int
3334
+ object_arrtype_getbuffer(PyObjectScalarObject *self, Py_buffer *view, int flags)
3335
+ {
3336
+ PyBufferProcs *pb = Py_TYPE(self->obval)->tp_as_buffer;
3337
+ if (pb == NULL || pb->bf_getbuffer == NULL) {
3338
+ PyErr_SetString(PyExc_TypeError,
3339
+ "expected a readable buffer object");
3340
+ return -1;
3341
+ }
3342
+ return (*pb->bf_getbuffer)(self->obval, view, flags);
3343
+ }
3344
+
3345
+ static void
3346
+ object_arrtype_releasebuffer(PyObjectScalarObject *self, Py_buffer *view)
3347
+ {
3348
+ PyBufferProcs *pb = Py_TYPE(self->obval)->tp_as_buffer;
3349
+ if (pb == NULL) {
3350
+ PyErr_SetString(PyExc_TypeError,
3351
+ "expected a readable buffer object");
3352
+ return;
3353
+ }
3354
+ if (pb->bf_releasebuffer != NULL) {
3355
+ (*pb->bf_releasebuffer)(self->obval, view);
3356
+ }
3357
+ }
3358
+
3359
+ static PyBufferProcs object_arrtype_as_buffer = {
3360
+ #if !defined(NPY_PY3K)
3361
+ (readbufferproc)object_arrtype_getreadbuf,
3362
+ (writebufferproc)object_arrtype_getwritebuf,
3363
+ (segcountproc)object_arrtype_getsegcount,
3364
+ (charbufferproc)object_arrtype_getcharbuf,
3365
+ #endif
3366
+ (getbufferproc)object_arrtype_getbuffer,
3367
+ (releasebufferproc)object_arrtype_releasebuffer,
3368
+ };
3369
+
3370
+ static PyObject *
3371
+ object_arrtype_call(PyObjectScalarObject *obj, PyObject *args, PyObject *kwds)
3372
+ {
3373
+ return PyObject_Call(obj->obval, args, kwds);
3374
+ }
3375
+
3376
+ NPY_NO_EXPORT PyTypeObject PyObjectArrType_Type = {
3377
+ #if defined(NPY_PY3K)
3378
+ PyVarObject_HEAD_INIT(NULL, 0)
3379
+ #else
3380
+ PyObject_HEAD_INIT(NULL)
3381
+ 0, /* ob_size */
3382
+ #endif
3383
+ "numpy.object_", /* tp_name*/
3384
+ sizeof(PyObjectScalarObject), /* tp_basicsize*/
3385
+ 0, /* tp_itemsize */
3386
+ (destructor)object_arrtype_dealloc, /* tp_dealloc */
3387
+ 0, /* tp_print */
3388
+ 0, /* tp_getattr */
3389
+ 0, /* tp_setattr */
3390
+ #if defined(NPY_PY3K)
3391
+ 0, /* tp_reserved */
3392
+ #else
3393
+ 0, /* tp_compare */
3394
+ #endif
3395
+ 0, /* tp_repr */
3396
+ 0, /* tp_as_number */
3397
+ &object_arrtype_as_sequence, /* tp_as_sequence */
3398
+ &object_arrtype_as_mapping, /* tp_as_mapping */
3399
+ 0, /* tp_hash */
3400
+ (ternaryfunc)object_arrtype_call, /* tp_call */
3401
+ 0, /* tp_str */
3402
+ (getattrofunc)object_arrtype_getattro, /* tp_getattro */
3403
+ (setattrofunc)object_arrtype_setattro, /* tp_setattro */
3404
+ &object_arrtype_as_buffer, /* tp_as_buffer */
3405
+ 0, /* tp_flags */
3406
+ 0, /* tp_doc */
3407
+ 0, /* tp_traverse */
3408
+ 0, /* tp_clear */
3409
+ 0, /* tp_richcompare */
3410
+ 0, /* tp_weaklistoffset */
3411
+ 0, /* tp_iter */
3412
+ 0, /* tp_iternext */
3413
+ 0, /* tp_methods */
3414
+ 0, /* tp_members */
3415
+ 0, /* tp_getset */
3416
+ 0, /* tp_base */
3417
+ 0, /* tp_dict */
3418
+ 0, /* tp_descr_get */
3419
+ 0, /* tp_descr_set */
3420
+ 0, /* tp_dictoffset */
3421
+ 0, /* tp_init */
3422
+ 0, /* tp_alloc */
3423
+ 0, /* tp_new */
3424
+ 0, /* tp_free */
3425
+ 0, /* tp_is_gc */
3426
+ 0, /* tp_bases */
3427
+ 0, /* tp_mro */
3428
+ 0, /* tp_cache */
3429
+ 0, /* tp_subclasses */
3430
+ 0, /* tp_weaklist */
3431
+ 0, /* tp_del */
3432
+ 0, /* tp_version_tag */
3433
+ };
3434
+
3435
+ static PyObject *
3436
+ gen_arrtype_subscript(PyObject *self, PyObject *key)
3437
+ {
3438
+ /*
3439
+ * Only [...], [...,<???>], [<???>, ...],
3440
+ * is allowed for indexing a scalar
3441
+ *
3442
+ * These return a new N-d array with a copy of
3443
+ * the data where N is the number of None's in <???>.
3444
+ */
3445
+ PyObject *res, *ret;
3446
+
3447
+ res = PyArray_FromScalar(self, NULL);
3448
+
3449
+ ret = array_subscript((PyArrayObject *)res, key);
3450
+ Py_DECREF(res);
3451
+ if (ret == NULL) {
3452
+ PyErr_SetString(PyExc_IndexError,
3453
+ "invalid index to scalar variable.");
3454
+ }
3455
+ return ret;
3456
+ }
3457
+
3458
+
3459
+ #define NAME_bool "bool"
3460
+ #define NAME_void "void"
3461
+ #if defined(NPY_PY3K)
3462
+ #define NAME_string "bytes"
3463
+ #define NAME_unicode "str"
3464
+ #else
3465
+ #define NAME_string "string"
3466
+ #define NAME_unicode "unicode"
3467
+ #endif
3468
+
3469
+ /**begin repeat
3470
+ * #name = bool, string, unicode, void#
3471
+ * #NAME = Bool, String, Unicode, Void#
3472
+ * #ex = _,_,_,#
3473
+ */
3474
+ NPY_NO_EXPORT PyTypeObject Py@NAME@ArrType_Type = {
3475
+ #if defined(NPY_PY3K)
3476
+ PyVarObject_HEAD_INIT(NULL, 0)
3477
+ #else
3478
+ PyObject_HEAD_INIT(NULL)
3479
+ 0, /* ob_size */
3480
+ #endif
3481
+ "numpy." NAME_@name@ "@ex@", /* tp_name*/
3482
+ sizeof(Py@NAME@ScalarObject), /* tp_basicsize*/
3483
+ 0, /* tp_itemsize */
3484
+ 0, /* tp_dealloc */
3485
+ 0, /* tp_print */
3486
+ 0, /* tp_getattr */
3487
+ 0, /* tp_setattr */
3488
+ #if defined(NPY_PY3K)
3489
+ 0, /* tp_reserved */
3490
+ #else
3491
+ 0, /* tp_compare */
3492
+ #endif
3493
+ 0, /* tp_repr */
3494
+ 0, /* tp_as_number */
3495
+ 0, /* tp_as_sequence */
3496
+ 0, /* tp_as_mapping */
3497
+ 0, /* tp_hash */
3498
+ 0, /* tp_call */
3499
+ 0, /* tp_str */
3500
+ 0, /* tp_getattro */
3501
+ 0, /* tp_setattro */
3502
+ 0, /* tp_as_buffer */
3503
+ 0, /* tp_flags */
3504
+ 0, /* tp_doc */
3505
+ 0, /* tp_traverse */
3506
+ 0, /* tp_clear */
3507
+ 0, /* tp_richcompare */
3508
+ 0, /* tp_weaklistoffset */
3509
+ 0, /* tp_iter */
3510
+ 0, /* tp_iternext */
3511
+ 0, /* tp_methods */
3512
+ 0, /* tp_members */
3513
+ 0, /* tp_getset */
3514
+ 0, /* tp_base */
3515
+ 0, /* tp_dict */
3516
+ 0, /* tp_descr_get */
3517
+ 0, /* tp_descr_set */
3518
+ 0, /* tp_dictoffset */
3519
+ 0, /* tp_init */
3520
+ 0, /* tp_alloc */
3521
+ 0, /* tp_new */
3522
+ 0, /* tp_free */
3523
+ 0, /* tp_is_gc */
3524
+ 0, /* tp_bases */
3525
+ 0, /* tp_mro */
3526
+ 0, /* tp_cache */
3527
+ 0, /* tp_subclasses */
3528
+ 0, /* tp_weaklist */
3529
+ 0, /* tp_del */
3530
+ 0, /* tp_version_tag */
3531
+ };
3532
+ /**end repeat**/
3533
+
3534
+ #undef NAME_bool
3535
+ #undef NAME_void
3536
+ #undef NAME_string
3537
+ #undef NAME_unicode
3538
+
3539
+ /**begin repeat
3540
+ * #NAME = Byte, Short, Int, Long, LongLong, UByte, UShort, UInt, ULong,
3541
+ * ULongLong, Half, Float, Double, LongDouble, Datetime, Timedelta#
3542
+ * #name = int*5, uint*5, float*4, datetime, timedelta#
3543
+ * #CNAME = (CHAR, SHORT, INT, LONG, LONGLONG)*2, HALF, FLOAT, DOUBLE,
3544
+ * LONGDOUBLE, DATETIME, TIMEDELTA#
3545
+ */
3546
+ #if NPY_BITSOF_@CNAME@ == 8
3547
+ #define _THIS_SIZE "8"
3548
+ #elif NPY_BITSOF_@CNAME@ == 16
3549
+ #define _THIS_SIZE "16"
3550
+ #elif NPY_BITSOF_@CNAME@ == 32
3551
+ #define _THIS_SIZE "32"
3552
+ #elif NPY_BITSOF_@CNAME@ == 64
3553
+ #define _THIS_SIZE "64"
3554
+ #elif NPY_BITSOF_@CNAME@ == 80
3555
+ #define _THIS_SIZE "80"
3556
+ #elif NPY_BITSOF_@CNAME@ == 96
3557
+ #define _THIS_SIZE "96"
3558
+ #elif NPY_BITSOF_@CNAME@ == 128
3559
+ #define _THIS_SIZE "128"
3560
+ #elif NPY_BITSOF_@CNAME@ == 256
3561
+ #define _THIS_SIZE "256"
3562
+ #endif
3563
+ NPY_NO_EXPORT PyTypeObject Py@NAME@ArrType_Type = {
3564
+ #if defined(NPY_PY3K)
3565
+ PyVarObject_HEAD_INIT(NULL, 0)
3566
+ #else
3567
+ PyObject_HEAD_INIT(NULL)
3568
+ 0, /* ob_size */
3569
+ #endif
3570
+ "numpy.@name@" _THIS_SIZE, /* tp_name*/
3571
+ sizeof(Py@NAME@ScalarObject), /* tp_basicsize*/
3572
+ 0, /* tp_itemsize */
3573
+ 0, /* tp_dealloc */
3574
+ 0, /* tp_print */
3575
+ 0, /* tp_getattr */
3576
+ 0, /* tp_setattr */
3577
+ #if defined(NPY_PY3K)
3578
+ 0, /* tp_reserved */
3579
+ #else
3580
+ 0, /* tp_compare */
3581
+ #endif
3582
+ 0, /* tp_repr */
3583
+ 0, /* tp_as_number */
3584
+ 0, /* tp_as_sequence */
3585
+ 0, /* tp_as_mapping */
3586
+ 0, /* tp_hash */
3587
+ 0, /* tp_call */
3588
+ 0, /* tp_str */
3589
+ 0, /* tp_getattro */
3590
+ 0, /* tp_setattro */
3591
+ 0, /* tp_as_buffer */
3592
+ 0, /* tp_flags */
3593
+ 0, /* tp_doc */
3594
+ 0, /* tp_traverse */
3595
+ 0, /* tp_clear */
3596
+ 0, /* tp_richcompare */
3597
+ 0, /* tp_weaklistoffset */
3598
+ 0, /* tp_iter */
3599
+ 0, /* tp_iternext */
3600
+ 0, /* tp_methods */
3601
+ 0, /* tp_members */
3602
+ 0, /* tp_getset */
3603
+ 0, /* tp_base */
3604
+ 0, /* tp_dict */
3605
+ 0, /* tp_descr_get */
3606
+ 0, /* tp_descr_set */
3607
+ 0, /* tp_dictoffset */
3608
+ 0, /* tp_init */
3609
+ 0, /* tp_alloc */
3610
+ 0, /* tp_new */
3611
+ 0, /* tp_free */
3612
+ 0, /* tp_is_gc */
3613
+ 0, /* tp_bases */
3614
+ 0, /* tp_mro */
3615
+ 0, /* tp_cache */
3616
+ 0, /* tp_subclasses */
3617
+ 0, /* tp_weaklist */
3618
+ 0, /* tp_del */
3619
+ 0, /* tp_version_tag */
3620
+ };
3621
+
3622
+ #undef _THIS_SIZE
3623
+ /**end repeat**/
3624
+
3625
+
3626
+ static PyMappingMethods gentype_as_mapping = {
3627
+ NULL,
3628
+ (binaryfunc)gen_arrtype_subscript,
3629
+ NULL
3630
+ };
3631
+
3632
+
3633
+ /**begin repeat
3634
+ * #NAME = CFloat, CDouble, CLongDouble#
3635
+ * #name = complex*3#
3636
+ * #CNAME = FLOAT, DOUBLE, LONGDOUBLE#
3637
+ */
3638
+ #if NPY_BITSOF_@CNAME@ == 16
3639
+ #define _THIS_SIZE2 "16"
3640
+ #define _THIS_SIZE1 "32"
3641
+ #elif NPY_BITSOF_@CNAME@ == 32
3642
+ #define _THIS_SIZE2 "32"
3643
+ #define _THIS_SIZE1 "64"
3644
+ #elif NPY_BITSOF_@CNAME@ == 64
3645
+ #define _THIS_SIZE2 "64"
3646
+ #define _THIS_SIZE1 "128"
3647
+ #elif NPY_BITSOF_@CNAME@ == 80
3648
+ #define _THIS_SIZE2 "80"
3649
+ #define _THIS_SIZE1 "160"
3650
+ #elif NPY_BITSOF_@CNAME@ == 96
3651
+ #define _THIS_SIZE2 "96"
3652
+ #define _THIS_SIZE1 "192"
3653
+ #elif NPY_BITSOF_@CNAME@ == 128
3654
+ #define _THIS_SIZE2 "128"
3655
+ #define _THIS_SIZE1 "256"
3656
+ #elif NPY_BITSOF_@CNAME@ == 256
3657
+ #define _THIS_SIZE2 "256"
3658
+ #define _THIS_SIZE1 "512"
3659
+ #endif
3660
+
3661
+ #define _THIS_DOC "Composed of two " _THIS_SIZE2 " bit floats"
3662
+
3663
+ NPY_NO_EXPORT PyTypeObject Py@NAME@ArrType_Type = {
3664
+ #if defined(NPY_PY3K)
3665
+ PyVarObject_HEAD_INIT(0, 0)
3666
+ #else
3667
+ PyObject_HEAD_INIT(0)
3668
+ 0, /* ob_size */
3669
+ #endif
3670
+ "numpy.@name@" _THIS_SIZE1, /* tp_name*/
3671
+ sizeof(Py@NAME@ScalarObject), /* tp_basicsize*/
3672
+ 0, /* tp_itemsize*/
3673
+ 0, /* tp_dealloc*/
3674
+ 0, /* tp_print*/
3675
+ 0, /* tp_getattr*/
3676
+ 0, /* tp_setattr*/
3677
+ #if defined(NPY_PY3K)
3678
+ 0, /* tp_reserved */
3679
+ #else
3680
+ 0, /* tp_compare */
3681
+ #endif
3682
+ 0, /* tp_repr*/
3683
+ 0, /* tp_as_number*/
3684
+ 0, /* tp_as_sequence*/
3685
+ 0, /* tp_as_mapping*/
3686
+ 0, /* tp_hash */
3687
+ 0, /* tp_call*/
3688
+ 0, /* tp_str*/
3689
+ 0, /* tp_getattro*/
3690
+ 0, /* tp_setattro*/
3691
+ 0, /* tp_as_buffer*/
3692
+ Py_TPFLAGS_DEFAULT, /* tp_flags*/
3693
+ _THIS_DOC, /* tp_doc */
3694
+ 0, /* tp_traverse */
3695
+ 0, /* tp_clear */
3696
+ 0, /* tp_richcompare */
3697
+ 0, /* tp_weaklistoffset */
3698
+ 0, /* tp_iter */
3699
+ 0, /* tp_iternext */
3700
+ 0, /* tp_methods */
3701
+ 0, /* tp_members */
3702
+ 0, /* tp_getset */
3703
+ 0, /* tp_base */
3704
+ 0, /* tp_dict */
3705
+ 0, /* tp_descr_get */
3706
+ 0, /* tp_descr_set */
3707
+ 0, /* tp_dictoffset */
3708
+ 0, /* tp_init */
3709
+ 0, /* tp_alloc */
3710
+ 0, /* tp_new */
3711
+ 0, /* tp_free */
3712
+ 0, /* tp_is_gc */
3713
+ 0, /* tp_bases */
3714
+ 0, /* tp_mro */
3715
+ 0, /* tp_cache */
3716
+ 0, /* tp_subclasses */
3717
+ 0, /* tp_weaklist */
3718
+ 0, /* tp_del */
3719
+ 0, /* tp_version_tag */
3720
+ };
3721
+ #undef _THIS_SIZE1
3722
+ #undef _THIS_SIZE2
3723
+ #undef _THIS_DOC
3724
+
3725
+ /**end repeat**/
3726
+
3727
+ #ifdef NPY_ENABLE_SEPARATE_COMPILATION
3728
+ /*
3729
+ * This table maps the built-in type numbers to their scalar
3730
+ * type numbers. Note that signed integers are mapped to INTNEG_SCALAR,
3731
+ * which is different than what PyArray_ScalarKind returns.
3732
+ */
3733
+ NPY_NO_EXPORT signed char
3734
+ _npy_scalar_kinds_table[NPY_NTYPES];
3735
+
3736
+ /*
3737
+ * This table maps a scalar kind (excluding NPY_NOSCALAR)
3738
+ * to the smallest type number of that kind.
3739
+ */
3740
+ NPY_NO_EXPORT signed char
3741
+ _npy_smallest_type_of_kind_table[NPY_NSCALARKINDS];
3742
+
3743
+ /*
3744
+ * This table gives the type of the same kind, but next in the sequence
3745
+ * of sizes.
3746
+ */
3747
+ NPY_NO_EXPORT signed char
3748
+ _npy_next_larger_type_table[NPY_NTYPES];
3749
+
3750
+ /*
3751
+ * This table describes safe casting for small type numbers,
3752
+ * and is used by PyArray_CanCastSafely.
3753
+ */
3754
+ NPY_NO_EXPORT unsigned char
3755
+ _npy_can_cast_safely_table[NPY_NTYPES][NPY_NTYPES];
3756
+
3757
+ /*
3758
+ * This table gives the smallest-size and smallest-kind type to which
3759
+ * the input types may be safely cast, according to _npy_can_cast_safely.
3760
+ */
3761
+ NPY_NO_EXPORT signed char
3762
+ _npy_type_promotion_table[NPY_NTYPES][NPY_NTYPES];
3763
+ #endif
3764
+
3765
+ NPY_NO_EXPORT void
3766
+ initialize_casting_tables(void)
3767
+ {
3768
+ int i, j;
3769
+
3770
+ _npy_smallest_type_of_kind_table[NPY_BOOL_SCALAR] = NPY_BOOL;
3771
+ _npy_smallest_type_of_kind_table[NPY_INTPOS_SCALAR] = NPY_UBYTE;
3772
+ _npy_smallest_type_of_kind_table[NPY_INTNEG_SCALAR] = NPY_BYTE;
3773
+ _npy_smallest_type_of_kind_table[NPY_FLOAT_SCALAR] = NPY_HALF;
3774
+ _npy_smallest_type_of_kind_table[NPY_COMPLEX_SCALAR] = NPY_CFLOAT;
3775
+ _npy_smallest_type_of_kind_table[NPY_OBJECT_SCALAR] = NPY_OBJECT;
3776
+
3777
+ /* Default for built-in types is object scalar */
3778
+ memset(_npy_scalar_kinds_table, NPY_OBJECT_SCALAR,
3779
+ sizeof(_npy_scalar_kinds_table));
3780
+ /* Default for next largest type is -1, signalling no bigger */
3781
+ memset(_npy_next_larger_type_table, -1,
3782
+ sizeof(_npy_next_larger_type_table));
3783
+
3784
+ /* Compile-time loop of scalar kinds */
3785
+
3786
+ /**begin repeat
3787
+ * #NAME = BOOL,
3788
+ * BYTE, UBYTE, SHORT, USHORT, INT, UINT,
3789
+ * LONG, ULONG, LONGLONG, ULONGLONG,
3790
+ * HALF, FLOAT, DOUBLE, LONGDOUBLE,
3791
+ * CFLOAT, CDOUBLE, CLONGDOUBLE#
3792
+ * #BIGGERTYPE = -1,
3793
+ * NPY_SHORT, NPY_USHORT, NPY_INT, NPY_UINT, NPY_LONG, NPY_ULONG,
3794
+ * NPY_LONGLONG, NPY_ULONGLONG, -1, -1,
3795
+ * NPY_FLOAT, NPY_DOUBLE, NPY_LONGDOUBLE, -1,
3796
+ * NPY_CDOUBLE, NPY_CLONGDOUBLE, -1#
3797
+ * #SCKIND = BOOL,
3798
+ * (INTNEG, INTPOS)*5,
3799
+ * FLOAT*4,
3800
+ * COMPLEX*3#
3801
+ */
3802
+
3803
+ _npy_scalar_kinds_table[NPY_@NAME@] = NPY_@SCKIND@_SCALAR;
3804
+ _npy_next_larger_type_table[NPY_@NAME@] = @BIGGERTYPE@;
3805
+
3806
+ /**end repeat**/
3807
+
3808
+ memset(_npy_can_cast_safely_table, 0, sizeof(_npy_can_cast_safely_table));
3809
+
3810
+ for (i = 0; i < NPY_NTYPES; ++i) {
3811
+ /* Identity */
3812
+ _npy_can_cast_safely_table[i][i] = 1;
3813
+ if (i != NPY_DATETIME) {
3814
+ /*
3815
+ * Bool -> <Anything> except datetime (since
3816
+ * it conceptually has no zero)
3817
+ */
3818
+ _npy_can_cast_safely_table[NPY_BOOL][i] = 1;
3819
+ }
3820
+ /* <Anything> -> Object */
3821
+ _npy_can_cast_safely_table[i][NPY_OBJECT] = 1;
3822
+ /* <Anything> -> Void */
3823
+ _npy_can_cast_safely_table[i][NPY_VOID] = 1;
3824
+ }
3825
+
3826
+ _npy_can_cast_safely_table[NPY_STRING][NPY_UNICODE] = 1;
3827
+ _npy_can_cast_safely_table[NPY_BOOL][NPY_TIMEDELTA] = 1;
3828
+
3829
+ #ifndef NPY_SIZEOF_BYTE
3830
+ #define NPY_SIZEOF_BYTE 1
3831
+ #endif
3832
+
3833
+ /* Compile-time loop of casting rules */
3834
+
3835
+ /**begin repeat
3836
+ * #FROM_NAME = BYTE, UBYTE, SHORT, USHORT, INT, UINT,
3837
+ * LONG, ULONG, LONGLONG, ULONGLONG,
3838
+ * HALF, FLOAT, DOUBLE, LONGDOUBLE,
3839
+ * CFLOAT, CDOUBLE, CLONGDOUBLE#
3840
+ * #FROM_BASENAME = BYTE, BYTE, SHORT, SHORT, INT, INT,
3841
+ * LONG, LONG, LONGLONG, LONGLONG,
3842
+ * HALF, FLOAT, DOUBLE, LONGDOUBLE,
3843
+ * FLOAT, DOUBLE, LONGDOUBLE#
3844
+ * #from_isint = 1, 0, 1, 0, 1, 0, 1, 0,
3845
+ * 1, 0, 0, 0, 0, 0,
3846
+ * 0, 0, 0#
3847
+ * #from_isuint = 0, 1, 0, 1, 0, 1, 0, 1,
3848
+ * 0, 1, 0, 0, 0, 0,
3849
+ * 0, 0, 0#
3850
+ * #from_isfloat = 0, 0, 0, 0, 0, 0, 0, 0,
3851
+ * 0, 0, 1, 1, 1, 1,
3852
+ * 0, 0, 0#
3853
+ * #from_iscomplex = 0, 0, 0, 0, 0, 0, 0, 0,
3854
+ * 0, 0, 0, 0, 0, 0,
3855
+ * 1, 1, 1#
3856
+ */
3857
+
3858
+ #define _FROM_BSIZE NPY_SIZEOF_@FROM_BASENAME@
3859
+ #define _FROM_NUM (NPY_@FROM_NAME@)
3860
+
3861
+ _npy_can_cast_safely_table[_FROM_NUM][NPY_STRING] = 1;
3862
+ _npy_can_cast_safely_table[_FROM_NUM][NPY_UNICODE] = 1;
3863
+
3864
+ /* Allow casts from any integer to the TIMEDELTA type */
3865
+ #if @from_isint@ || @from_isuint@
3866
+ _npy_can_cast_safely_table[_FROM_NUM][NPY_TIMEDELTA] = 1;
3867
+ #endif
3868
+
3869
+ /**begin repeat1
3870
+ * #TO_NAME = BYTE, UBYTE, SHORT, USHORT, INT, UINT,
3871
+ * LONG, ULONG, LONGLONG, ULONGLONG,
3872
+ * HALF, FLOAT, DOUBLE, LONGDOUBLE,
3873
+ * CFLOAT, CDOUBLE, CLONGDOUBLE#
3874
+ * #TO_BASENAME = BYTE, BYTE, SHORT, SHORT, INT, INT,
3875
+ * LONG, LONG, LONGLONG, LONGLONG,
3876
+ * HALF, FLOAT, DOUBLE, LONGDOUBLE,
3877
+ * FLOAT, DOUBLE, LONGDOUBLE#
3878
+ * #to_isint = 1, 0, 1, 0, 1, 0, 1, 0,
3879
+ * 1, 0, 0, 0, 0, 0,
3880
+ * 0, 0, 0#
3881
+ * #to_isuint = 0, 1, 0, 1, 0, 1, 0, 1,
3882
+ * 0, 1, 0, 0, 0, 0,
3883
+ * 0, 0, 0#
3884
+ * #to_isfloat = 0, 0, 0, 0, 0, 0, 0, 0,
3885
+ * 0, 0, 1, 1, 1, 1,
3886
+ * 0, 0, 0#
3887
+ * #to_iscomplex = 0, 0, 0, 0, 0, 0, 0, 0,
3888
+ * 0, 0, 0, 0, 0, 0,
3889
+ * 1, 1, 1#
3890
+ */
3891
+ #define _TO_BSIZE NPY_SIZEOF_@TO_BASENAME@
3892
+ #define _TO_NUM (NPY_@TO_NAME@)
3893
+
3894
+ /*
3895
+ * NOTE: _FROM_BSIZE and _TO_BSIZE are the sizes of the "base type"
3896
+ * which is the same as the size of the type except for
3897
+ * complex, where it is the size of the real type.
3898
+ */
3899
+
3900
+ #if @from_isint@
3901
+
3902
+ # if @to_isint@ && (_TO_BSIZE >= _FROM_BSIZE)
3903
+ /* int -> int */
3904
+ _npy_can_cast_safely_table[_FROM_NUM][_TO_NUM] = 1;
3905
+ # elif @to_isfloat@ && (_FROM_BSIZE < 8) && (_TO_BSIZE > _FROM_BSIZE)
3906
+ /* int -> float */
3907
+ _npy_can_cast_safely_table[_FROM_NUM][_TO_NUM] = 1;
3908
+ # elif @to_isfloat@ && (_FROM_BSIZE >= 8) && (_TO_BSIZE >= _FROM_BSIZE)
3909
+ /* int -> float */
3910
+ _npy_can_cast_safely_table[_FROM_NUM][_TO_NUM] = 1;
3911
+ # elif @to_iscomplex@ && (_FROM_BSIZE < 8) && (_TO_BSIZE > _FROM_BSIZE)
3912
+ /* int -> complex */
3913
+ _npy_can_cast_safely_table[_FROM_NUM][_TO_NUM] = 1;
3914
+ # elif @to_iscomplex@ && (_FROM_BSIZE >= 8) && (_TO_BSIZE >= _FROM_BSIZE)
3915
+ /* int -> complex */
3916
+ _npy_can_cast_safely_table[_FROM_NUM][_TO_NUM] = 1;
3917
+ # endif
3918
+
3919
+ #elif @from_isuint@
3920
+
3921
+ # if @to_isint@ && (_TO_BSIZE > _FROM_BSIZE)
3922
+ /* uint -> int */
3923
+ _npy_can_cast_safely_table[_FROM_NUM][_TO_NUM] = 1;
3924
+ # elif @to_isuint@ && (_TO_BSIZE >= _FROM_BSIZE)
3925
+ /* uint -> uint */
3926
+ _npy_can_cast_safely_table[_FROM_NUM][_TO_NUM] = 1;
3927
+ # elif @to_isfloat@ && (_FROM_BSIZE < 8) && (_TO_BSIZE > _FROM_BSIZE)
3928
+ /* uint -> float */
3929
+ _npy_can_cast_safely_table[_FROM_NUM][_TO_NUM] = 1;
3930
+ # elif @to_isfloat@ && (_FROM_BSIZE >= 8) && (_TO_BSIZE >= _FROM_BSIZE)
3931
+ /* uint -> float */
3932
+ _npy_can_cast_safely_table[_FROM_NUM][_TO_NUM] = 1;
3933
+ # elif @to_iscomplex@ && (_FROM_BSIZE < 8) && (_TO_BSIZE > _FROM_BSIZE)
3934
+ /* uint -> complex */
3935
+ _npy_can_cast_safely_table[_FROM_NUM][_TO_NUM] = 1;
3936
+ # elif @to_iscomplex@ && (_FROM_BSIZE >= 8) && (_TO_BSIZE >= _FROM_BSIZE)
3937
+ /* uint -> complex */
3938
+ _npy_can_cast_safely_table[_FROM_NUM][_TO_NUM] = 1;
3939
+ # endif
3940
+
3941
+
3942
+ #elif @from_isfloat@
3943
+
3944
+ # if @to_isfloat@ && (_TO_BSIZE >= _FROM_BSIZE)
3945
+ /* float -> float */
3946
+ _npy_can_cast_safely_table[_FROM_NUM][_TO_NUM] = 1;
3947
+ # elif @to_iscomplex@ && (_TO_BSIZE >= _FROM_BSIZE)
3948
+ /* float -> complex */
3949
+ _npy_can_cast_safely_table[_FROM_NUM][_TO_NUM] = 1;
3950
+ # endif
3951
+
3952
+ #elif @from_iscomplex@
3953
+
3954
+ # if @to_iscomplex@ && (_TO_BSIZE >= _FROM_BSIZE)
3955
+ /* complex -> complex */
3956
+ _npy_can_cast_safely_table[_FROM_NUM][_TO_NUM] = 1;
3957
+ # endif
3958
+
3959
+ #endif
3960
+
3961
+ #undef _TO_NUM
3962
+ #undef _TO_BSIZE
3963
+
3964
+ /**end repeat1**/
3965
+
3966
+ #undef _FROM_NUM
3967
+ #undef _FROM_BSIZE
3968
+
3969
+ /**end repeat**/
3970
+
3971
+ /*
3972
+ * Now that the _can_cast_safely table is finished, we can
3973
+ * use it to build the _type_promotion table
3974
+ */
3975
+ for (i = 0; i < NPY_NTYPES; ++i) {
3976
+ _npy_type_promotion_table[i][i] = i;
3977
+ /* Don't let number promote to string/unicode/void/datetime/timedelta */
3978
+ if (i == NPY_STRING || i == NPY_UNICODE || i == NPY_VOID ||
3979
+ i == NPY_DATETIME || i == NPY_TIMEDELTA) {
3980
+ /* Promoting these types requires examining their contents */
3981
+ _npy_type_promotion_table[i][i] = -1;
3982
+ for (j = i + 1; j < NPY_NTYPES; ++j) {
3983
+ _npy_type_promotion_table[i][j] = -1;
3984
+ _npy_type_promotion_table[j][i] = -1;
3985
+ }
3986
+ /* Except they can convert to OBJECT */
3987
+ _npy_type_promotion_table[i][NPY_OBJECT] = NPY_OBJECT;
3988
+ _npy_type_promotion_table[NPY_OBJECT][i] = NPY_OBJECT;
3989
+ }
3990
+ else {
3991
+ for (j = i + 1; j < NPY_NTYPES; ++j) {
3992
+ /* Don't let number promote to string/unicode/void */
3993
+ if (j == NPY_STRING || j == NPY_UNICODE || j == NPY_VOID) {
3994
+ _npy_type_promotion_table[i][j] = -1;
3995
+ _npy_type_promotion_table[j][i] = -1;
3996
+ }
3997
+ else if (_npy_can_cast_safely_table[i][j]) {
3998
+ _npy_type_promotion_table[i][j] = j;
3999
+ _npy_type_promotion_table[j][i] = j;
4000
+ }
4001
+ else if (_npy_can_cast_safely_table[j][i]) {
4002
+ _npy_type_promotion_table[i][j] = i;
4003
+ _npy_type_promotion_table[j][i] = i;
4004
+ }
4005
+ else {
4006
+ int k, iskind, jskind, skind;
4007
+ iskind = _npy_scalar_kinds_table[i];
4008
+ jskind = _npy_scalar_kinds_table[j];
4009
+ /* If there's no kind (void/string/etc) */
4010
+ if (iskind == NPY_NOSCALAR || jskind == NPY_NOSCALAR) {
4011
+ k = -1;
4012
+ }
4013
+ else {
4014
+ /* Start with the type of larger kind */
4015
+ if (iskind > jskind) {
4016
+ skind = iskind;
4017
+ k = i;
4018
+ }
4019
+ else {
4020
+ skind = jskind;
4021
+ k = j;
4022
+ }
4023
+ for (;;) {
4024
+ /* Try the next larger type of this kind */
4025
+ k = _npy_next_larger_type_table[k];
4026
+
4027
+ /* If there is no larger, try a larger kind */
4028
+ if (k < 0) {
4029
+ ++skind;
4030
+ /* Use -1 to signal no promoted type found */
4031
+ if (skind < NPY_NSCALARKINDS) {
4032
+ k = _npy_smallest_type_of_kind_table[skind];
4033
+ }
4034
+ else {
4035
+ k = -1;
4036
+ break;
4037
+ }
4038
+ }
4039
+
4040
+ if (_npy_can_cast_safely_table[i][k] &&
4041
+ _npy_can_cast_safely_table[j][k]) {
4042
+ break;
4043
+ }
4044
+ }
4045
+ }
4046
+ _npy_type_promotion_table[i][j] = k;
4047
+ _npy_type_promotion_table[j][i] = k;
4048
+ }
4049
+ }
4050
+ }
4051
+ }
4052
+ }
4053
+
4054
+
4055
+ static PyNumberMethods longdoubletype_as_number;
4056
+ static PyNumberMethods clongdoubletype_as_number;
4057
+ static void init_basetypes(void);
4058
+
4059
+
4060
+ NPY_NO_EXPORT void
4061
+ initialize_numeric_types(void)
4062
+ {
4063
+ init_basetypes();
4064
+ PyGenericArrType_Type.tp_dealloc = (destructor)gentype_dealloc;
4065
+ PyGenericArrType_Type.tp_as_number = &gentype_as_number;
4066
+ PyGenericArrType_Type.tp_as_buffer = &gentype_as_buffer;
4067
+ PyGenericArrType_Type.tp_as_mapping = &gentype_as_mapping;
4068
+ PyGenericArrType_Type.tp_flags = BASEFLAGS;
4069
+ PyGenericArrType_Type.tp_methods = gentype_methods;
4070
+ PyGenericArrType_Type.tp_getset = gentype_getsets;
4071
+ PyGenericArrType_Type.tp_new = NULL;
4072
+ PyGenericArrType_Type.tp_alloc = gentype_alloc;
4073
+ PyGenericArrType_Type.tp_free = (freefunc)gentype_free;
4074
+ PyGenericArrType_Type.tp_repr = gentype_repr;
4075
+ PyGenericArrType_Type.tp_str = gentype_str;
4076
+ PyGenericArrType_Type.tp_richcompare = gentype_richcompare;
4077
+
4078
+ PyBoolArrType_Type.tp_as_number = &bool_arrtype_as_number;
4079
+ /*
4080
+ * need to add dummy versions with filled-in nb_index
4081
+ * in-order for PyType_Ready to fill in .__index__() method
4082
+ */
4083
+
4084
+ /**begin repeat
4085
+ * #name = byte, short, int, long, longlong, ubyte, ushort,
4086
+ * uint, ulong, ulonglong#
4087
+ * #NAME = Byte, Short, Int, Long, LongLong, UByte, UShort,
4088
+ * UInt, ULong, ULongLong#
4089
+ */
4090
+ Py@NAME@ArrType_Type.tp_as_number = &@name@_arrtype_as_number;
4091
+ Py@NAME@ArrType_Type.tp_as_number->nb_index = (unaryfunc)@name@_index;
4092
+
4093
+ /**end repeat**/
4094
+ PyBoolArrType_Type.tp_as_number->nb_index = (unaryfunc)bool_index;
4095
+
4096
+ PyStringArrType_Type.tp_alloc = NULL;
4097
+ PyStringArrType_Type.tp_free = NULL;
4098
+
4099
+ PyStringArrType_Type.tp_repr = stringtype_repr;
4100
+ PyStringArrType_Type.tp_str = stringtype_str;
4101
+
4102
+ PyUnicodeArrType_Type.tp_repr = unicodetype_repr;
4103
+ PyUnicodeArrType_Type.tp_str = unicodetype_str;
4104
+
4105
+ PyVoidArrType_Type.tp_methods = voidtype_methods;
4106
+ PyVoidArrType_Type.tp_getset = voidtype_getsets;
4107
+ PyVoidArrType_Type.tp_as_mapping = &voidtype_as_mapping;
4108
+ PyVoidArrType_Type.tp_as_sequence = &voidtype_as_sequence;
4109
+
4110
+ PyIntegerArrType_Type.tp_getset = inttype_getsets;
4111
+
4112
+ /**begin repeat
4113
+ * #NAME= Number, Integer, SignedInteger, UnsignedInteger, Inexact,
4114
+ * Floating, ComplexFloating, Flexible, Character#
4115
+ */
4116
+
4117
+ Py@NAME@ArrType_Type.tp_flags = BASEFLAGS;
4118
+
4119
+ /**end repeat**/
4120
+
4121
+ /**begin repeat
4122
+ * #name = bool, byte, short, int, long, longlong, ubyte, ushort, uint,
4123
+ * ulong, ulonglong, half, float, double, longdouble, cfloat,
4124
+ * cdouble, clongdouble, string, unicode, void, object, datetime,
4125
+ * timedelta#
4126
+ * #NAME = Bool, Byte, Short, Int, Long, LongLong, UByte, UShort, UInt,
4127
+ * ULong, ULongLong, Half, Float, Double, LongDouble, CFloat,
4128
+ * CDouble, CLongDouble, String, Unicode, Void, Object, Datetime,
4129
+ * Timedelta#
4130
+ */
4131
+
4132
+ Py@NAME@ArrType_Type.tp_flags = BASEFLAGS;
4133
+ Py@NAME@ArrType_Type.tp_new = @name@_arrtype_new;
4134
+ Py@NAME@ArrType_Type.tp_richcompare = gentype_richcompare;
4135
+
4136
+ /**end repeat**/
4137
+
4138
+ /**begin repeat
4139
+ * #name = bool, byte, short, ubyte, ushort, uint, ulong, ulonglong,
4140
+ * half, float, longdouble, cfloat, clongdouble, void, object,
4141
+ * datetime, timedelta#
4142
+ * #NAME = Bool, Byte, Short, UByte, UShort, UInt, ULong, ULongLong,
4143
+ * Half, Float, LongDouble, CFloat, CLongDouble, Void, Object,
4144
+ * Datetime, Timedelta#
4145
+ */
4146
+
4147
+ Py@NAME@ArrType_Type.tp_hash = @name@_arrtype_hash;
4148
+
4149
+ /**end repeat**/
4150
+
4151
+ /**begin repeat
4152
+ * #name = cfloat, clongdouble#
4153
+ * #NAME = CFloat, CLongDouble#
4154
+ */
4155
+
4156
+ Py@NAME@ArrType_Type.tp_methods = @name@type_methods;
4157
+
4158
+ /**end repeat**/
4159
+
4160
+ #if (NPY_SIZEOF_INT != NPY_SIZEOF_LONG) || defined(NPY_PY3K)
4161
+ /* We won't be inheriting from Python Int type. */
4162
+ PyIntArrType_Type.tp_hash = int_arrtype_hash;
4163
+ #endif
4164
+
4165
+ #if defined(NPY_PY3K)
4166
+ /* We won't be inheriting from Python Int type. */
4167
+ PyLongArrType_Type.tp_hash = long_arrtype_hash;
4168
+ #endif
4169
+
4170
+ #if (NPY_SIZEOF_LONG != NPY_SIZEOF_LONGLONG) || defined(NPY_PY3K)
4171
+ /* We won't be inheriting from Python Int type. */
4172
+ PyLongLongArrType_Type.tp_hash = longlong_arrtype_hash;
4173
+ #endif
4174
+
4175
+ /**begin repeat
4176
+ * #name = repr, str#
4177
+ */
4178
+
4179
+ PyHalfArrType_Type.tp_@name@ = halftype_@name@;
4180
+
4181
+ PyFloatArrType_Type.tp_@name@ = floattype_@name@;
4182
+ PyCFloatArrType_Type.tp_@name@ = cfloattype_@name@;
4183
+
4184
+ PyDoubleArrType_Type.tp_@name@ = doubletype_@name@;
4185
+ PyCDoubleArrType_Type.tp_@name@ = cdoubletype_@name@;
4186
+
4187
+ PyDatetimeArrType_Type.tp_@name@ = datetimetype_@name@;
4188
+ PyTimedeltaArrType_Type.tp_@name@ = timedeltatype_@name@;
4189
+
4190
+ /**end repeat**/
4191
+
4192
+ PyHalfArrType_Type.tp_print = halftype_print;
4193
+ PyFloatArrType_Type.tp_print = floattype_print;
4194
+ PyDoubleArrType_Type.tp_print = doubletype_print;
4195
+ PyLongDoubleArrType_Type.tp_print = longdoubletype_print;
4196
+
4197
+ PyCFloatArrType_Type.tp_print = cfloattype_print;
4198
+ PyCDoubleArrType_Type.tp_print = cdoubletype_print;
4199
+ PyCLongDoubleArrType_Type.tp_print = clongdoubletype_print;
4200
+
4201
+ /*
4202
+ * These need to be coded specially because getitem does not
4203
+ * return a normal Python type
4204
+ */
4205
+ PyLongDoubleArrType_Type.tp_as_number = &longdoubletype_as_number;
4206
+ PyCLongDoubleArrType_Type.tp_as_number = &clongdoubletype_as_number;
4207
+
4208
+ /**begin repeat
4209
+ * #name = int, float, repr, str#
4210
+ * #kind = tp_as_number->nb*2, tp*2#
4211
+ */
4212
+
4213
+ PyLongDoubleArrType_Type.@kind@_@name@ = longdoubletype_@name@;
4214
+ PyCLongDoubleArrType_Type.@kind@_@name@ = clongdoubletype_@name@;
4215
+
4216
+ /**end repeat**/
4217
+
4218
+
4219
+ #if !defined(NPY_PY3K)
4220
+ /**begin repeat
4221
+ * #name = long, hex, oct#
4222
+ * #kind = tp_as_number->nb*3#
4223
+ */
4224
+
4225
+ PyLongDoubleArrType_Type.@kind@_@name@ = longdoubletype_@name@;
4226
+ PyCLongDoubleArrType_Type.@kind@_@name@ = clongdoubletype_@name@;
4227
+
4228
+ /**end repeat**/
4229
+
4230
+ #endif
4231
+
4232
+ PyStringArrType_Type.tp_itemsize = sizeof(char);
4233
+ PyVoidArrType_Type.tp_dealloc = (destructor) void_dealloc;
4234
+
4235
+ PyArrayIter_Type.tp_iter = PyObject_SelfIter;
4236
+ PyArrayMapIter_Type.tp_iter = PyObject_SelfIter;
4237
+ }
4238
+
4239
+ typedef struct {
4240
+ PyTypeObject * type;
4241
+ int typenum;
4242
+ } scalar_type;
4243
+
4244
+ static scalar_type typeobjects[] = {
4245
+ {&PyBoolArrType_Type, NPY_BOOL},
4246
+ {&PyByteArrType_Type, NPY_BYTE},
4247
+ {&PyUByteArrType_Type, NPY_UBYTE},
4248
+ {&PyShortArrType_Type, NPY_SHORT},
4249
+ {&PyUShortArrType_Type, NPY_USHORT},
4250
+ {&PyIntArrType_Type, NPY_INT},
4251
+ {&PyUIntArrType_Type, NPY_UINT},
4252
+ {&PyLongArrType_Type, NPY_LONG},
4253
+ {&PyULongArrType_Type, NPY_ULONG},
4254
+ {&PyLongLongArrType_Type, NPY_LONGLONG},
4255
+ {&PyULongLongArrType_Type, NPY_ULONGLONG},
4256
+ {&PyFloatArrType_Type, NPY_FLOAT},
4257
+ {&PyDoubleArrType_Type, NPY_DOUBLE},
4258
+ {&PyLongDoubleArrType_Type, NPY_LONGDOUBLE},
4259
+ {&PyCFloatArrType_Type, NPY_CFLOAT},
4260
+ {&PyCDoubleArrType_Type, NPY_CDOUBLE},
4261
+ {&PyCLongDoubleArrType_Type, NPY_CLONGDOUBLE},
4262
+ {&PyObjectArrType_Type, NPY_OBJECT},
4263
+ {&PyStringArrType_Type, NPY_STRING},
4264
+ {&PyUnicodeArrType_Type, NPY_UNICODE},
4265
+ {&PyVoidArrType_Type, NPY_VOID},
4266
+ {&PyDatetimeArrType_Type, NPY_DATETIME},
4267
+ {&PyTimedeltaArrType_Type, NPY_TIMEDELTA},
4268
+ {&PyHalfArrType_Type, NPY_HALF}
4269
+ };
4270
+
4271
+ static int compare_types(const void * a_, const void * b_)
4272
+ {
4273
+ const PyTypeObject * a = ((const scalar_type *)a_)->type;
4274
+ const PyTypeObject * b = ((const scalar_type *)b_)->type;
4275
+ if (a < b) {
4276
+ return -1;
4277
+ }
4278
+ else if (a > b) {
4279
+ return 1;
4280
+ }
4281
+ return 0;
4282
+ }
4283
+
4284
+ static void init_basetypes(void)
4285
+ {
4286
+ qsort(typeobjects, sizeof(typeobjects) / sizeof(typeobjects[0]),
4287
+ sizeof(typeobjects[0]),
4288
+ compare_types);
4289
+ }
4290
+
4291
+
4292
+ NPY_NO_EXPORT int
4293
+ get_typeobj_idx(PyTypeObject * obj)
4294
+ {
4295
+ npy_intp imin = 0, imax = sizeof(typeobjects) / sizeof(typeobjects[0]) - 1;
4296
+ while (imax >= imin)
4297
+ {
4298
+ npy_intp imid = ((imax - imin) / 2) + imin;
4299
+ if(typeobjects[imid].type == obj) {
4300
+ return imid;
4301
+ }
4302
+ else if (typeobjects[imid].type < obj) {
4303
+ imin = imid + 1;
4304
+ }
4305
+ else {
4306
+ imax = imid - 1;
4307
+ }
4308
+ }
4309
+
4310
+ return -1;
4311
+ }
4312
+
4313
+ NPY_NO_EXPORT int
4314
+ is_anyscalar_exact(PyObject *obj)
4315
+ {
4316
+ return get_typeobj_idx(Py_TYPE(obj)) >= 0;
4317
+ }
4318
+
4319
+ NPY_NO_EXPORT int
4320
+ _typenum_fromtypeobj(PyObject *type, int user)
4321
+ {
4322
+ int typenum, i;
4323
+
4324
+ typenum = NPY_NOTYPE;
4325
+ i = get_typeobj_idx((PyTypeObject*)type);
4326
+ if (i >= 0) {
4327
+ typenum = typeobjects[i].typenum;
4328
+ }
4329
+
4330
+ if (!user) {
4331
+ return typenum;
4332
+ }
4333
+ /* Search any registered types */
4334
+ i = 0;
4335
+ while (i < NPY_NUMUSERTYPES) {
4336
+ if (type == (PyObject *)(userdescrs[i]->typeobj)) {
4337
+ typenum = i + NPY_USERDEF;
4338
+ break;
4339
+ }
4340
+ i++;
4341
+ }
4342
+ return typenum;
4343
+ }