summaryrefslogtreecommitdiff
path: root/numpy/lib
Commit message (Collapse)AuthorAgeFilesLines
...
| * | | Add space after argument nameOscar Gustafsson2022-04-033-32/+31
| |/ /
* | | Improve documentation formattingOscar Gustafsson2022-04-032-10/+28
|/ /
* | Merge pull request #21232 from ganesh-k13/bug_21051_kronMatti Picus2022-03-272-11/+46
|\ \ | | | | | | BUG: Fixes `ValueError` in `np.kron`
| * | BUG: Convert other inputs to arrayGanesh Kathiresan2022-03-261-2/+4
| | | | | | | | | | | | Input such as matrix will cause a `ValueError` due to dim restrictions
| * | MAINT: Linting fixesGanesh Kathiresan2022-03-252-2/+3
| | |
| * | ENH: Refactor kron to not use concatGanesh Kathiresan2022-03-251-8/+15
| | |
| * | TST: Added testcases for `np.kron`Ganesh Kathiresan2022-03-221-0/+26
| | | | | | | | | | | | | | | | | | * Smoke tests to ensure `np.kron` works. * Shape tests to check if `np.kron` computes the right shape for different edge cases of input arrays
| * | BUG: Refactor `np.kron` to handle 0 in shapeGanesh Kathiresan2022-03-221-11/+10
| | | | | | | | | | | | | | | | | | * `np.kron` uses `np.concatenate` which fails when shape is 0 along an axis * Refactor shape normalising portion.
* | | Merge pull request #21216 from BvB93/_typingCharles Harris2022-03-2514-14/+14
|\ \ \ | |/ / |/| | MAINT: Split `numpy.typing` into a public and private component
| * | MAINT: Split `numpy.typing` into a public and private componentBas van Beek2022-03-1814-14/+14
| | | | | | | | | | | | i.e. `numpy.typing` and `numpy._typing`
* | | DOC: misc fixes:Matthias Bussonnier2022-03-212-3/+4
|/ / | | | | | | | | | | | | | | | | | | - improper urls - a few use of single bakcticks where many are expected - Proper numpydoc format [ci skip] [skip azp] [skip circle]
* | TYP, BUG: Fix `np.lib.stride_tricks` being re-exported under the wrong nameBas van Beek2022-03-121-1/+1
| |
* | Merge pull request #16895 from DevinShanahan/delete-speedupMatti Picus2022-02-272-5/+25
|\ \ | | | | | | MAINT: extend delete single value optimization
| * | MAINT: single value identification and testDevin Shanahan2022-01-162-3/+15
| | |
| * | MAINT: Merge branch 'main' into delete-speedupDevin Shanahan2022-01-1659-2901/+7570
| |\ \
| * | | Update numpy/lib/function_base.pyDevin Shanahan2020-07-191-1/+1
| | | | | | | | | | | | Co-authored-by: Eric Wieser <wieser.eric@gmail.com>
| * | | ENH: extend delete single value optimizationDevinShanahan2020-07-181-5/+13
| | | | | | | | | | | | | | | | | | | | Allow arrays of shape (1,) for delete's obj parameter to utilize the optimization for a single value. See #16685.
* | | | DOC: Fix spelling and grammar in documentation for quantile(). (#21068)Don Kirkby2022-02-151-12/+12
| | | |
* | | | BUG: (loadtxt) Ignore last empty field when `delimiter=None`Sebastian Berg2022-02-141-1/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When the delimiter is None and we are splitting on whitespace, a final empty field is always ignored to match the behaviour of pythons split: `" 1 ".split()`. Closes gh-21052
* | | | DOC: disambiguate :: in rst. (#21037)Matthias Bussonnier2022-02-111-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Having the `::` on new line can be ambiguous for RST parsers, as `:` is a valid character for header underlines. And as underlines do not have to be as long as the title for some rst parser this appears to be a title. Workaround is to have either a blank line, or put the `::` at the end of previous one.
* | | | DOC: Include special case in `hsplit` doc (#20974)Bharat Raghunathan2022-02-091-1/+7
| | | |
* | | | Merge pull request #20580 from seberg/add-npreadtextMatti Picus2022-02-083-341/+1490
|\ \ \ \ | | | | | | | | | | ENH: Move `loadtxt` to C for much better speed
| * | | | Add two new examples of converters to docstring examplesRoss Barnowski2022-02-071-0/+19
| | | | | | | | | | | | | | | | | | | | | | | | | - Floats with underscores - Floats + hex floats.
| * | | | TST: Skip error test using on PyPy (test uses %.100R)Sebastian Berg2022-01-301-0/+2
| | | | |
| * | | | TST: Fix exception msg matching in tests.Ross Barnowski2022-01-281-5/+5
| | | | |
| * | | | Linting.Ross Barnowski2022-01-281-3/+4
| | | | |
| * | | | Handle delimiter as bytes.Ross Barnowski2022-01-282-1/+9
| | | | |
| * | | | Add test for str dtype len discovery with converters.Ross Barnowski2022-01-281-1/+23
| | | | | | | | | | | | | | | | | | | | nrows gt chunksize.
| * | | | Add test for empty string as control characters.Ross Barnowski2022-01-282-0/+16
| | | | | | | | | | | | | | | | | | | | Includes comments param, which is handled on the Python side.
| * | | | Add test for unicode, parametrize for chunksize.Ross Barnowski2022-01-281-5/+15
| | | | |
| * | | | Add test for datetime parametric unit discovery.Ross Barnowski2022-01-281-1/+23
| | | | |
| * | | | TST: Some tests for control character collisions.Ross Barnowski2022-01-282-6/+57
| | | | | | | | | | | | | | | Adds some tests for the behavior of control characters, e.g. comments, delimiter and quotechar, when they have the same value. At this stage, these tests are more to frame the discussion about what the behavior should be, not to test what it currently is. I personally think raising an exception is correct for most of these situations, though it's worth noting that np.loadtxt currently doesn't for most of these corner cases (and seems to randomly assign precedence to delimiter over comments or vice versa depending on the values).
| * | | | TST: Use repr in byteswapping testsSebastian Berg2022-01-191-3/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The `str` values for those weird values used for longdouble are truncated by PyPy's complex `str` output. Which seems fine probably since PyPy's `repr` does the right thing and will not truncate.
| * | | | TST: Catch two more errors that runs into the PyPy issueSebastian Berg2022-01-191-0/+4
| | | | |
| * | | | TST: Use hand-picked values for byte-swapping testsSebastian Berg2022-01-191-15/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Longdouble is a source of problems here especially (mainly due to it sometimes using double in the background, or maybe just buggy implementations). Together with strings that correctly parsed do not roundtrip (if printed using less precision), things just do not work out... This fixes it, and is simpler/clearer anyway.
| * | | | TST: Skip unparsable field error tests on PyPySebastian Berg2022-01-192-1/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PyPy has a small bug with error formatting, so these cause it to crash. Simply skip the tests on old PyPy versions for now. (Matti fixed the issue long ago, just waiting for a new PyPy release :))
| * | | | Add quotechar to examples.Ross Barnowski2022-01-181-1/+21
| | | | |
| * | | | Update and add converters examples.Ross Barnowski2022-01-181-1/+33
| | | | |
| * | | | TST,BUG: Fortify byteswapping tests and make a small fixSebastian Berg2022-01-151-3/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | I had a lingering feeling I should double check this, turns out that feeling was right ;). (Fixes up the tokenizer doc a bit.)
| * | | | BUG: Fix loadtxt no data warning stacklevelSebastian Berg2022-01-141-1/+1
| | | | |
| * | | | DOC: Remove outdated loadtxt TODOs from codeSebastian Berg2022-01-141-3/+5
| | | | |
| * | | | TST,STY: Add small additional tests for converters/usecolsSebastian Berg2022-01-142-20/+27
| | | | | | | | | | | | | | | | | | | | | | | | | Also fix style a bit to silence linter (hopefully), removes some black style, but I am not too opinionated about that :)
| * | | | TST: Move most new loadtxt tests to its own fileSebastian Berg2022-01-142-767/+836
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This also adds two basic new tests around files/strings containing the \0 character (prooving that we handle that gracefully). Also adds tests for: * the `_` thousands delimiter (should fail, but doesn't for float128 right now) * Failure modes when the number of rows changes (negative specifically) Many of these tests came originally from Warren Weckesser and others were added by Ross Barnowsky: Co-authored-by: Warren Weckesser <warren.weckesser@gmail.com> Co-authored-by: Ross Barnowski <rossbar@berkeley.edu>
| * | | | MAINT: Use skiplines rather than skiprows internally throughoutSebastian Berg2022-01-141-6/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Skiplines is just the more clear names since "rows" make a lot of sense for output rows (which implies that a line is not empty for example)
| * | | | TST: Add test for hard/impossible to reach universal-newline support pathsSebastian Berg2022-01-141-0/+15
| | | | |
| * | | | TST: Improve test coverage, replace impossible error with assertSebastian Berg2022-01-141-0/+49
| | | | |
| * | | | TST,MAINT: New tests, byteswap cleanups and fixed assertSebastian Berg2022-01-141-6/+25
| | | | |
| * | | | TST,BUG: Additional bad-file-like test, add missing error path freeSebastian Berg2022-01-141-0/+14
| | | | | | | | | | | | | | | | | | | | And remove one silly leftover struct member that was unused
| * | | | MAINT,TST,BUG: Simplify streamer init, fix issues, and add testsSebastian Berg2022-01-141-0/+45
| | | | |
| * | | | ENH: Give warning for empty-lines not counting towards max-rowsSebastian Berg2022-01-141-0/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This also slightly cleans up the empty-line handling: previously we sometimes just had some extra empty-lines that just effectively never mattered