summaryrefslogtreecommitdiff
path: root/numpy/lib/npyio.py
Commit message (Collapse)AuthorAgeFilesLines
...
* DOC: Add missing bracket (gh-16051)Chunlin2020-04-251-1/+1
| | | Add missing closing brackets, script to generate the list in the PR gh-16051.
* DOC: Add converters example to the loadtxt docstring (gh-16043)Warren Weckesser2020-04-231-4/+15
| | | Co-Authored-By: Ross Barnowski <rossbar@berkeley.edu>
* STY: use 'yield from <expr>' for simple cases (#15444)Mike Taves2020-01-271-8/+4
| | | | | | | | | This PR uses simple cases of PEP 380 to rewrite: for v in g: yield v into: yield from <expr>
* ENH: Make use of ExitStack in npyio.pySeth Troisi2020-01-241-21/+12
|
* MAINT: Replace basestring with str.Charles Harris2020-01-231-5/+5
| | | | | | | This replaces basestring with str except in - tools/npy_tempita/ - numpy/compat/py3k.py
* MAINT: Cleanup python2 referencesSeth Troisi2020-01-211-1/+1
|
* [MAINT] Cleanup python2 sys.version checksSeth Troisi2020-01-201-40/+21
|
* MAINT: Remove implicit inheritance from object class (#15236)Jon Dufresne2020-01-051-3/+3
| | | | | | | Inheriting from object was necessary for Python 2 compatibility to use new-style classes. In Python 3, this is unnecessary as there are no old-style classes. Dropping the object is more idiomatic Python.
* MAINT: Remove unnecessary 'from __future__ import ...' statementsJon Dufresne2020-01-031-2/+0
| | | | | As numpy is Python 3 only, these import statements are now unnecessary and don't alter runtime behavior.
* DOC: Fix typo in loadtxt and genfromtxtAnis Ladram2019-11-291-2/+2
|
* DOC: Fix typo in numpy.loadtxt documentationAnis Ladram2019-11-291-1/+1
| | | Parameter fname: generator must return byte strings for Python 3, not Python3k.
* MAINT: Remove uses of scalar aliasesEric Wieser2019-11-131-2/+2
| | | | Relates to gh-6103
* Use filename (vs file name) consistentlyStefan van der Walt2019-10-151-8/+8
|
* Tidy up savez keys-as-file-names languageStefan van der Walt2019-10-151-20/+8
|
* DOC: edited numpy.savez docstring note to be more specificDmytro2019-10-151-4/+13
| | | | | | | Note states that dictionary keys are stored as file names and may undergo unintended changes when they are not recognized as valid file names. In such cases the keys must be properly encapsulated and escaped to avoid being changed.
* DOC: added note to docstring of numpy.savezDmytro2019-10-151-0/+5
| | | | | | Note indicates that when used with dictionaries, savez will remove leading "/" in dictionary keys. See #9265
* Merge remote-tracking branch 'upstream/master' into fix-if-fieldsEric Wieser2019-08-191-317/+372
|\
| * DOC:Add example to clarify "numpy.save" behavior on already open file #10445 ↵Omar Merghany2019-08-161-1/+12
| | | | | | | | | | (#14070) * DOC:Add example to clarify "numpy.save" behavior on already unclosed file
| * fixes StopIteration error for empty file with skip_header > 0Maxwell Aladago2019-08-111-5/+6
| |
| * BUG: Fix file-like object check when saving arraysLuis Pedro Coelho2019-07-201-2/+2
| | | | | | | | For writing arrays, only the ``write`` method is necessary.
| * Merge branch 'master' into force-zip64Charles Harris2019-06-261-0/+22
| |\
| | * Merge pull request #13222 from kritisingh1/patch1Matti Picus2019-06-101-0/+22
| | |\ | | | | | | | | DOC: Document/ Deprecate functions exposed in "numpy" namespace
| | | * fix testskritisingh12019-06-071-4/+12
| | | |
| | | * Issue deprecation warningskritisingh12019-04-051-0/+14
| | | |
| * | | ENH: always use zip64, upgrade pickle protocol to 3mattip2019-05-231-2/+2
| |/ /
| * | Complete the exampleBharat123rox2019-05-121-0/+2
| | |
| * | Add suggested exampleBharat123rox2019-05-121-5/+9
| | |
| * | Merge upstream branch 'master' of https://github.com/numpy/numpy into ↵Bharat123rox2019-05-121-2/+3
| |\ \ | | | | | | | | | | | | fix-genfromtxt
| | * \ Merge pull request #13402 from eric-wieser/genfromtxt-defaultsSebastian Berg2019-05-111-1/+2
| | |\ \ | | | | | | | | | | DOC: Show the default value of deletechars in the signature of genfromtxt
| | | * | DOC: Show the default value of deletechars in the signature of genfromtxtEric Wieser2019-05-111-1/+2
| | | | |
| | * | | Merge pull request #13409 from seberg/fix-unicode-fmt-savetxtMatti Picus2019-04-261-1/+1
| | |\ \ \ | | | |/ / | | |/| | BUG: (py2 only) fix unicode support for savetxt fmt string
| | | * | BUG: (py2 only) fix unicode support for savetxt fmt stringSebastian Berg2019-04-261-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | By now, all that is needed is to also allow unicode strings to pass through. Adds a test for the support which already succeeds on python3. Closes gh-4053 (replaces the old PR)
| * | | | Clarify deletechars in docsBharat123rox2019-04-241-2/+5
| | | | |
| * | | | Resolve confusion regarding hashtag in header line of csvBharat123rox2019-04-241-0/+1
| |/ / /
| * | | BUG: load fails when using pickle without allow_pickle=TruePaul Ivanov2019-04-161-5/+12
| | | | | | | | | | | | | | | | | | | | | | | | a partial mitigation of #12759. see also https://nvd.nist.gov/vuln/detail/CVE-2019-6446
| * | | BUG: Close files if an error occurs in genfromtxtEric Wieser2019-04-121-269/+270
| |/ / | | | | | | | | | | | | | | | Mostly indentation changes Fixes gh-13200
| * | BUG: Fix crash when calling savetxt on a padded arrayEric Wieser2019-04-111-1/+1
| |/ | | | | | | | | | | As a general rule, _every_ use of `.descr` is broken. Fixes #13297
| * DEV: cleanup imports and some assignments (from LGTM)mattip2019-03-171-4/+1
| |
| * MAINT: Move pickle import to numpy.compatCharles Harris2019-02-211-2/+1
| | | | | | | | | | | | | | The pickle module was being imported from numpy.core.numeric. It was defined there in order to use pickle5 when available in Python3 and cpickle in Python2. The numpy.compat module seems a better place for that.
| * DOC: Add warning about arbitrary code execution to numpy.loadAndras Deak2019-02-021-0/+6
| | | | | | | | | | | | Load uses pickle under the hood for object arrays, this is made more visible in the documentation using a warning. See also gh-12759
| * Clarify skiprows in loadtxtIlja2018-12-181-1/+1
| |
| * MAINT: address several reviewer commentsTyler Reddy2018-12-141-2/+2
| |
| * TST, DOC: enable refguide_checkTyler Reddy2018-12-141-27/+27
| | | | | | | | | | | | | | | | * ported the refguide_check module from SciPy for usage in NumPy docstring execution/ verification; added the refguide_check run to Azure Mac OS CI * adjusted NumPy docstrings such that refguide_check passes
* | BUG: Don't construct masked arrays with the wrong mask type in genfromtxtEric Wieser2019-08-191-1/+1
| | | | | | | | This only affects arrays with `dtype([])`, but also follows the recommended way to check for structured arrays in our docs
* | BUG: Don't allow extra fields to be added in genfromtxtEric Wieser2019-08-191-1/+1
|/ | | | Previously passing `dtype=[], names=['a']` would append an extra field, even though `dtype=['a'], names=['b', 'c']` does not.
* Use set litteralsRoman Yurchak2018-11-241-2/+2
|
* MNT: Reword error message about loading pickled data.Elliott Sales de Andrade2018-11-191-2/+2
| | | | This double negative is confusing to me.
* ENH: set correct __module__ for objects in numpy's public APIStephan Hoyer2018-11-131-1/+13
| | | | | | | | | | | | | Fixes GH-12271 Tests verify that everything in ``dir(numpy)`` either has ``__module__`` set to ``'numpy'``, or appears in an explicit whitelist of undocumented functions and exported bulitins. These should eventually be documented or removed. I also identified a handful of functions for which I had accidentally not setup dispatch for with ``__array_function__`` before, because they were listed under "ndarray methods" in ``_add_newdocs.py``. I guess that should be a lesson in trusting code comments :).
* Merge pull request #12157 from eric-wieser/fspathMatti Picus2018-10-311-28/+19
|\ | | | | ENH: Add support for third-party path-like objects by backporting os.fspath
| * ENH: Add support for third-party path-like objects by backporting os.fspathEric Wieser2018-10-121-28/+19
| |