-
Notifications
You must be signed in to change notification settings - Fork 2
docs: migrate from readme to docs #90
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
9 commits
Select commit
Hold shift + click to select a range
f7f081c
docs: migrate from readme to docs
ianna 2c8c16f
docs: converting readme to docs
ianna fa8775e
docs: move instructions to a separate file
ianna 9f5303d
fix: remove duplicates
ianna 251ba30
chore: add icon and rename api
ianna d622fcc
add icon
ianna 6422cd4
correct icon
ianna 9b936c7
update logo
ianna 30ad5f0
remove dir
ianna File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
Binary file not shown.
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1 +1,48 @@ | ||
| # API | ||
| ## List of functions | ||
|
|
||
| Every `Content` subclass has the following built-in functions: | ||
|
|
||
| * `Base.length` | ||
| * `Base.size` (1-tuple of `length`) | ||
| * `Base.firstindex`, `Base.lastindex` (1-based or inherited from its index) | ||
| * `Base.getindex`: select by `Int` (single item), `UnitRange{Int}` (slice), and `Symbol` (record field) | ||
| * `Base.iterate` | ||
| * `Base.(==)` (equality defined by values: a `ListOffsetArray` and a `ListArray` may be considered the same) | ||
| * `Base.push!` | ||
| * `Base.append!` | ||
| * `Base.show` | ||
|
|
||
| They also have the following functions for manipulating and checking structure: | ||
|
|
||
| * `AwkwardArray.parameters_of`: gets all parameters | ||
| * `AwkwardArray.has_parameter`: returns true if a parameter exists | ||
| * `AwkwardArray.get_parameter`: returns a parameter or raises an error | ||
| * `AwkwardArray.with_parameter`: returns a copy of this node with a specified parameter | ||
| * `AwkwardArray.copy`: shallow-copy of the array, allowing properties to be replaced | ||
| * `AwkwardArray.is_valid`: verifies that the structure adheres to Awkward Array's protocol | ||
|
|
||
| They have the following functions for filling an array: | ||
|
|
||
| * `AwkwardArray.end_list!`: closes off a `ListType` array (`ListOffsetArray`, `ListArray`, or `RegularArray`) in the manner of Python's [ak.ArrayBuilder](https://awkward-array.org/doc/main/reference/generated/ak.ArrayBuilder.html) (no `begin_list` is necessary) | ||
| * `AwkwardArray.end_record!`: closes off a `RecordArray` | ||
| * `AwkwardArray.end_tuple!`: closes off a `TupleArray` | ||
| * `AwkwardArray.push_null!`: pushes a missing value onto `OptionType` arrays (`IndexedOptionArray`, `ByteMaskedArray`, `BitMaskedArray`, or `UnmaskedArray`) | ||
| * `AwkwardArray.push_dummy!`: pushes an unspecified value onto the array (used by `ByteMaskedArray` and `BitMaskedArray`, which need to have a placeholder in memory behind each `missing` value) | ||
|
|
||
| `RecordArray` and `TupleArray` have the following for selecting fields (as opposed to rows): | ||
|
|
||
| * `AwkwardArray.slot`: gets a `RecordArray` or `TupleArray` field, to avoid conflicts with `Base.getindex` for `TupleArrays` (both use integers to select a field) | ||
| * `AwkwardArray.Record`: scalar representation of an item from a `RecordArray` | ||
| * `AwkwardArray.Tuple`: scalar representation of an item from a `TupleArray` (note: not the same as `Base.Tuple`) | ||
|
|
||
| `UnionArray` has the following for dealing with specializations: | ||
|
|
||
| * `AwkwardArray.Specialization`: selects a `UnionArray` specialization for `push!`, `append!`, etc. | ||
|
|
||
| Finally, all `Content` subclasses can be converted with the following: | ||
|
|
||
| * `AwkwardArray.layout_for`: returns an appropriately-nested `Content` type for a given Julia type (`DataType`) | ||
| * `AwkwardArray.from_iter`: converts Julia data into an Awkward Array | ||
| * `AwkwardArray.to_vector`: converts an Awkward Array into Julia data | ||
| * `AwkwardArray.from_buffers`: constructs an Awkward Array from a Form (JSON), length, and buffers for zero-copy passing from Python | ||
| * `AwkwardArray.to_buffers`: deconstructs an Awkward Array into a Form (JSON), length, and buffers for zero-copy passing to Python |
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
This file was deleted.
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@jpivarski - the idea is to trim the top README.md file and have full documentation here that is generated as a documentation by Documeter.jl. The full infrastructure is already in place. The dev version of documentation is at https://juliahep.github.io/AwkwardArray.jl/dev/