Conversation
31 tasks
rgommers
commented
Sep 13, 2020
rgommers
commented
Sep 13, 2020
spec/purpose_and_scope.md
Outdated
| implementation to access the API namespace, namely a function: | ||
|
|
||
| ``` | ||
| mod = x.__array_namespace__(api_version='2020.10') |
Member
Author
There was a problem hiding this comment.
In the last call, everyone seemed happy with this.
Ref discussion from 20 Aug. The thing I left out of this text
is a global dispatch. The last point made on that was:
... there is some inherent difficulties. Local dispatch is the more
straightforward approach, but difficulties arise when you want a
particular function to use a particular backend implementation.
and I wasn't quite sure if that concern is valid - maybe I'm missing
some details. If the "you" in there is the library author, then
they should just ignore the whole API standard namespace and just do
`import lib_I_want; lib_I_want.<somefunc>`.
If it is the end user, then they normally would pass in an array of
the right type that would control this. So the one case I see where
the concern applies is if there is some function that does _not_ take
any array input, but creates arrays internally _and_ the default array
type for that creation is somehow undesirable. That seems a bit
unlikely.
7850e2e to
fd63c5d
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Ref discussion from 20 Aug, and gh-16. The thing I left out of this text is a global dispatch. The last point made on that was:
and I wasn't quite sure if that concern is valid - maybe I'm missing some details. If the "you" in there is the library author, then they should just ignore the whole API standard namespace and just do
If the "you" is the end user, then they normally would pass in an array of the right type that would control this. So the one case I see where the concern applies is if there is some function that does not take any array input, but creates arrays internally and the default array type for that creation is somehow undesirable. That seems a bit unlikely.