Skip to content

DOC: Update install page in Sphinx docs#17365

Closed
bjnath wants to merge 248 commits intonumpy:masterfrom
bjnath:delete-install-page
Closed

DOC: Update install page in Sphinx docs#17365
bjnath wants to merge 248 commits intonumpy:masterfrom
bjnath:delete-install-page

Conversation

@bjnath
Copy link
Contributor

@bjnath bjnath commented Sep 22, 2020

Removed the install page (user/install.rst) from Sphinx,
since we've put the install instructions in Hugo. install.rst
was inadequate in any case.

The docs front page now leads with "What is NumPy"?

The "Troubleshooting InstallError"
(user/troubleshooting-importerror.rst) page remains, but
since Hugo has the install instructions, it's
linked to from the Hugo install page (via numpy.org PR #360).

bjnath and others added 30 commits September 7, 2020 11:38
Entries added, explanations revised,
Python-only entries now point to Python glossary.
More clearly describe `shares_memory` as being
not always *feasible* rather than *possible*
Also reworded `stride` entry for clarity, moved
'axis' entry to correct alphabetical position.

Also added anchors to reference/arrays.indexing for glossary references
to point to.
Failing CI because it's running doctest on the example strings.

Also, deleting glossary.py, source file of the original glossary.
strctured -> structured, caught by @WarrenWeckesser.

Fixed missing language in `view` entry.
Also adding <BLANKLINE>s to some examples for clarity.
This also allows at least in principle numba dynamically
generated ufuncs to be pickled (with some hacking), see:

dask/distributed#3450

If the name of the ufunc is set to a qualname, using this method,
pickle should be able to unpickle the ufunc correctly.
We may want to allow setting the module and qualname explicitly
on the ufunc object to remove the need for the custom pickler
completely.
This is just a small preparation to make the code slightly more
modular, since I definitely will need to retain the wrapping for
legacy dtype `dtype->f->castfuncs` and the `dtype->f->copyswapn`,
but want more freedom to see whether I can split out the specialized
casts we use internally (since NumPy has those cast functions, but
normally never uses them).

Splitting these two out should make it easier to write a function
to support current "legacy" dtype cast functions without worrying
as much about the casts used internally for NumPy dtypes.
This also includes `NPY_ITEM_IS_POINTER`.  A previous changed
raised an error when this happened, but some downstream libraries
use it to create a custom dtype with a single object field.

It seems acceptable to create such a dtype if (and only if) that
dtype hardcodes names and fields at creation time, so this change
allows that, but otherwise keeps the error intact.

This should work fine, although some care may be required
This allows running `xpress` on current master. `xpress` copies the
type from `np.dtype(object)` rather than using `&PyArrayDescr_Type`.
That seems overall fine, we can just replace it.
The only reason for this check is to ensure that the user does not
override our updated `type(user_dtype)` and thus corrupting it.
This includes a few error paths. Note that the test creates
a new dtype ever time it is run, and dtypes in NumPy are persistent
so that this leaks references.
Also added "contiguous," which is referenced in docs but hadn't been
defined.
Migrated from numpy-tutorials
Migrated from numpy-tutorials
bjnath and others added 19 commits October 7, 2020 23:39
* DOC: Revise NEP 42 "common DType" section

* DOC: Eliminate duplicate doc in NEP42

* DOC: Fix missing 'not' in NEP42 edit

* DOC: Minor typos in NEP42 edit

* DOC: Reword opening sentence of NEP 42 revision

Also clarify a wording.

* DOC: Correct :class: reference in NEP42 edit

* DOC: Fix Windows line-enders on NEP42 edit

* DOC: New round of common DType edits of NEP 42

* DOC: Uniquify anchors in NEP 42

* DOC: Typo in NEP42 edit

* DOC: Last push for NEP 42 edit

* Small fixups and moving example

One paragraph on `__common_dtype` in the alternatives was already
before very confusing. This makes it hopefully more clear.

* NEP: Change title to "New and extensible DTypes"

Co-authored-by: Sebastian Berg <sebastian@sipsolutions.net>
BUG: Fix failures in master related to userdtype registeration
DOC: Use consistent lowercase on docs landing page
BUG: remove `sys` from the type stubs
Reduce the need to scroll, per @mattip suggestion in numpy#17440
DOC: Fewer blank lines in PR template
Remove tutorial wording in favor of article, minor wording updates.
Co-authored-by: Eric Wieser <wieser.eric@gmail.com>
MAINT: Remove duplicate placeholder annotations
BLD: circleCI- merge before build, add -n to sphinx
Co-authored-by: Bas van Beek <43369155+BvB93@users.noreply.github.com>
Co-authored-by: Bas van Beek <43369155+BvB93@users.noreply.github.com>
ENH: Add annotations for bitwise operations
ENH: Added the Final feature for all constants
@charris
Copy link
Member

charris commented Oct 9, 2020

@bjnath Needs rebase.

@bjnath
Copy link
Contributor Author

bjnath commented Oct 9, 2020

Rebase attempt went bad, closing.

@bjnath bjnath closed this Oct 9, 2020
@bjnath bjnath deleted the delete-install-page branch October 9, 2020 19:25
@charris
Copy link
Member

charris commented Oct 9, 2020

Oops :) Just do git rebase master next time and fix the conflicts. It helps to squash your commits first if you have a bunch of them. You can also fix this by fast forward merging it (--ff-only) to a new pr branch from current master, the extra commits will go away.

bjnath added a commit to bjnath/numpy-1 that referenced this pull request Oct 9, 2020
Same intent as PR numpy#17365 -- point "Installation" links to Hugo, start
page with "What is NumPy", let Hugo page link to
"Troubleshooting ImportError".
@bjnath
Copy link
Contributor Author

bjnath commented Oct 9, 2020

Thanks, @charris -- I saw those hundreds of commits and panicked. Resurrected as #17523.

@charris
Copy link
Member

charris commented Oct 9, 2020

Slightly more complicated, you can also do a hard reset to the state before the oops. To find the hash for that state do git reflog.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.