* Migrate to xtask-common crate
* Fix example crate name for simple-regression
* Refactor CI workflows
* Flatten linux workflows
* Install grcov and typos from binaries
Although xtask-common support auto-installation of these tools via cargo
it is a lot faster to install them via the distributed binaries
* [CI] Update Rust caches on failure
* [CI] Add shell bash to jobs steps
* [CI] Try cache all crates
* Fix no-std tests not executing
* [CI] Add CARGO_INCREMENTAL 0
* Exclude tch and cuda from tests and merge crates and examples steps
* Fix some typos found with typos cli
* Add Windows and MacOS jobs
* Only test no-std with default rust target
* Fix syntax in composite action setup-windows
* Enable incremental build
* Upate cargo alias for xtask
* Bump to github action checkout v4
* Revert to tch 0.15 and disable WGPU on windows
* Fix color in output
* Add Test command
* Test long output errorring
* Build and test workspace before additional builds and tests
* Disable wgpu tests on windows
* Remove tests- prefix in CI workflow jobs name
* Add Checks command
* Rename ci workflow jobs
* Execute windows and macos CI tests on rust stable only
* Rename integration test files with a test_ prefix
* Fix format
* Don't auto-correct "arange" with typos
* Fix typos in code
* Merge unit and integration tests steps
* Fix macos tests
* Fix coverage step
* Name publish-crate workflow
* Fix bad cache name for macos
* Reorganize commands and get rid of the ci command
* Fix dispatch to customized commands for Burn
* Update to last version of tracel-xtask
* Remove unnecessary shell bash in ci workflow
* Update cargo.lock
* Fix format
* Bump tracel-xtask
* Simplify dispatch of base commands using updated macro
* Update to last version of tracel-xtask
* Adapt legacy run_checks script with new xtask commands
* Run xtask in debug for faster compilation time
* Ditch build step in ci and enable coverage for stable linux only
* Freeze tracel-xtask to specific commit rev
* Update cargo.lock
* Update Step 6 of CONTRIBUTING guidelines about run-checks script
* Remove unneeded CI and CD paragraphgs in CONRIBUTING.md
* Change cache version
* Fix typos
* Use centralized actions and workflows
* Update to last version of tracel-xtask
* Update CONTRIBUTING file to mention integration tests
* Add custom build for thumbv6m-none-eabi
* Ignore onnx files for typos check
* Fix action and workflow paths in github workflows
* Fix custom builds on MacOS
* Bump tracel-xtask crate to last version
* Update Cargo.lock
* Update publish workflow to use reusable workflow in tracel repo
* Add --ci flag for build and test commands
* implemented muli-dim index for GatherNode
The `NodeCodegen` impl for `GatherNode` now performs gather in complete
accordance with the ONNX Gather spec.
- a `gather` function was added to the gather.rs file
- `gather()` is now called within the codegen instead of `tensor.select()`
- a test with two test cases have been added
- test axes 0 and 1
- both use 2D index tensors
* add gather_onnx to numeric api
Added int and float implementations of gather to the burn-tensor numeric
api:
- named the methods `gather_onnx` to not be confused with the current
`gather`
- these implementations follow the `Gather` ONNX spec
Updated the gather*.py variants and their onnx outputs
* modified files didn't end up in last commit
* tests passing for onnx gather
The implementation of gather for the ONNX `Gather` spec is tentatively
complete:
- py test models are updated
- onnx_tests are modified and passing: `gather`, `gather_scalar`, and
`gather_shape`
- node/gather tests are passing
NOTE: The two additional tests in crates/burn-import/src/burn/node/gather.rs that test
the actual functionality of gather are likely to be deleted, since they
are redundant to the tests in
crates/burn-import/onnx-tests/tests/onnx_tests.rs.
* inlined onnx gather within codegen
* rm gather_onnx from public api; rm unnecessary tests
* add comments to gather py models
* some codegen changes; formatting to appease run-checks
- Some necessary changes and improvements to the codegen inlined code
after translating from public api (removed in previous commit).
- Changed some formatting that run-checks complained about.
* simplify gather codegen; include 1d and 2d onnx tests
Modified the `Gather` codegen per requested changes:
- combined match statements on index
- remove use of `alloc::vec::Vec`
- use map -> collect instead of procedural
- include a 1d index gather onnx test
- remove superflous tests
* delete unused gather.onnx
* renaming repeat to repeat_dim
* implementing repeat function
* renaming repeat files to repeat_dim
* renaming part 2
* renaming part 3
* renaming part 4
* renaming part 5
* adding test file
* adding unit test
* adding rust book documentation
* adding function args doc
* fixing tests
* changing repeat api to match pytorch equivalent
* fixing clippy error
* implementing tile onnx file
* temp
* working implementation and test
* working e2e test
* adding new supported onnx operation to the md file
* Add Hard Sigmoid activation function
* Add ONNX import conversion for HardSigmoid
* Update supported operators list
* Update book
* Make test comparison approximate to eliminate precision issues
* Add burn-candle test
* Fix name in E2E test generator
* make contacts deterministic across Worlds
* add top k acc
* add onnx mean
* fix
* push fix
* format
---------
Co-authored-by: Charles Bournhonesque <cbournhonesque@snapchat.com>
* Implement ONNX pad
* ONNX pad arguments fix
pad now requires 2 or more arguments
if the third argument is not given, it will default to 0
* fixing bug in input len fix
* change panic comment
Change panic comment from needing two inputs. This comes from the fact that the ONNX spec requires two necessary inputs but could have more two more optional argument.
---------
Co-authored-by: JC <you@example.com>
Co-authored-by: mepatrick73 <pameu17@ulaval.ca>
* Remove panic for squeeze when more than one axis is specified
* Remove extra Model()
* Change script to squeeze all singleton dimensions
* Revert change since burn requires axes to be specified
* Fix input tensor
* Try updating ONNX files again
* Add script for testing multiple axes along with new ONNX file
* Update squeeze.py comments
* Add squeeze_multiple model to tests
* Fix dim_inference
* Feat: burn-import implement ONNX ConstantOfShape
* Introduce shape type and use in ConstantOfShape and Shape
* Add tests for bool and int tensors for ConstantOfShape
* Fix ONNX test generation
* Undo comment
---------
Co-authored-by: Dilshod Tadjibaev <939125+antimora@users.noreply.github.com>
* Implement 3D and transposed 3D convolutions.
* Merge changes from onnx-ir #1921 pr
---------
Co-authored-by: Dilshod Tadjibaev <939125+antimora@users.noreply.github.com>
* separating onnx parsing from burn-import
* ran clippy and cargo-fmt
* removed unused deps from onnx-ir
* fixed clippy warnings that were causing run-checks to fail
* removed dead code
* removed unused dependencies from burn-import
* updated contributor-book, updated publish.yml, added readme
* update cargo lock
* formatted md document with prettier, rephrased sentence
* missed the errors with reduce_prod_conversion during merge
* formatted onnx-to-burn-conversion-tool.md, forgot to save
* Preliminary ReduceProd Support
* Add comma to keep formatter happy
* Give test results a 0.001 tolerance to account for floating-point multiplication
* Reformat assersions
* Correctly mark panic conditions in op_configuration
* Move distribution to module
* Add new TensorData with serialization support
* Implement display and from for TensorData
* Add missing Cargo.lock
* Add missing bytemuck feature
* Add zeros, ones, full and random TensorData methods
* Refactor Data -> TensorData usage
* Fix tests
Since TensorData is not generic over the element type anymore no type inference can be done by the compiler. We must explicitly cast the expected results to the expected backend type.
* Remove commented line
* Fix import
* Add record-backward-compat
* Remove dim const generic from TensorData
* Support NestedValue de/serialization with TensorData
* Fix burn-jit tests
* Remove eprinln
* Refactor onnx import to use TensorData
* Fix tch from_data
* Fix nested value serialization for u8
* Fix missing import
* Fix reduce min onnx test
* Fix deprecated attribute
* Remove shape getter
* Remove strict assert in tests
* Add tensor data as_bytes
* Add tensor check for rank mismatch
* Fix typo (dimensions plural)
* Fix error message
* Update book examples with from_data and fix Display impl for TensorData
* Add deprecation note
* draft for alternative burn import design
* passes onnx test, fails to build example
* pushing to test example on main
* fixed the issue with the example
* passes the test now
* spring cleaning and minor code changes
* removed pub visibility from most graph_data fields and functions
* comment fixes
* went ahead and removed the constant check for now
* removed unused function arg
* Move and redirect GatherElements to new folders/nodes
* Create PyTorch script for gather
* Add onnx file for gather
* Add a gather test to onnx_tests
* Update gather.rs to use select
* Rename codegen test
* Update gather and gather_elements conversion functions
* Validate rank of input node and update output
* Add check for Gather
* pre-test
* implementing argmax for burn-import from onnx
* tidying
* fixing return types and tests
* addressing feedback
* only warn when select_last_index!=0