-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Description
Report incorrect documentation
Location of incorrect documentation
Provide links and line numbers if applicable.
Put into words, `A o B = A o s:d`, for integral `s` and `d` means that we want (1) "remove" the first `d` elements from `A`, and then (2) "keep" the first `s` of those strided elements. |
2. Keeping the first `s` elements of the strided `A` layout can be computed by "modding out" the first `s` elements from the shape of `A` starting from the left. For example, |
Describe the problems or issues found in the documentation
A clear and concise description of what you found to be incorrect.
The description for composition currently reads:
Put into words, `A o B = A o s:d`, for integral `s` and `d` means that we want (1) "remove" the first `d` elements from `A`, and then (2) "keep" the first `s` of those strided elements.
'Remove' is quite confusing here, especially with the quotation marks. Instead what the first step in composition suggests to be doing is selecting every d'th element of A starting from index 0. This aligns with the integer shape/stride example.
'Remove the first...' suggests truncation, which I don't think is what is happening here.
For the second associated issue, the 'modding out' of the required elements from the reduced view of A is also confusing
Keeping the first s elements of the strided A layout can be computed by “modding out” the first s elements from the shape of A starting from the left. For example,
This isn't a standard modulo operation - and though the meaning becomes clear with repeated readings, as it stands it doesn't really make sense as the notation doesn't reflect the actual modulo operation.
Steps taken to verify documentation is incorrect
List any steps you have taken:
Suggested fix for documentation
Detail proposed changes to fix the documentation if you have any.
Both of these docs should have some clarifying examples, or alternatively terminology/notation that reflects the nature of the operations.
I propose changing the description to clarify the meaning of 'remove' and 'keep' with reference to the 1D example. As the '/' operation is really about indexing views based on the 'd' stride, it would be helpful to clarify this if this is indeed what is going on.
Report needed documentation
Report needed documentation
A clear and concise description of what documentation you believe it is needed and why.
Describe the documentation you'd like
A clear and concise description of what you want to happen.
Steps taken to search for needed documentation
List any steps you have taken:
I will submit a PR with some clarifying changes.