Commit Graph

931 Commits

Author SHA1 Message Date
louisfd c77f1f1479 Merge branch 'main' into feat/jit/reduce_dim 2024-02-28 14:15:51 -05:00
louisfd 08f1b46dd3 Merge branch 'main' of github.com:tracel-ai/burn 2024-02-28 14:15:42 -05:00
louisfd 8cb1098269 remove sandbox kernel 2024-02-28 14:10:32 -05:00
louisfd a5cadc2b2b tmp sandbox kernel 2024-02-28 14:07:03 -05:00
louisfd 2773f26433 instruction set for reduce workgroup 2024-02-28 14:06:10 -05:00
Yu Sun 330552afb4
docs(book-&-examples): modify book and examples with new `prelude` module (#1372) 2024-02-28 13:25:25 -05:00
louisfd 67de96130c argmin argmax, autotune moved 2024-02-27 12:23:14 -05:00
louisfd d1214ddb3b reduce dim trait 2024-02-27 11:39:42 -05:00
louisfd 0c08f29b98 reduction 2024-02-27 11:12:43 -05:00
Nathaniel Simard 57887e7a47
Refactor/elemwise/kernel selection + dynamic fused inplace operations and broadcasting (#1359) 2024-02-27 08:41:31 -05:00
Nathaniel Simard bdec8d5813
[Refactor - JIT] Gather Scatter new implementations (#1356) 2024-02-26 17:20:09 -05:00
Louis Fortier-Dubois 576bb44bc8
Feat/autodiff/checkpoint ops (#1358) 2024-02-26 17:19:09 -05:00
Mathias Insley bb5e6faff2
Feat/autotune int ops (#1136)
* Add int_random to int tensor ops

* Int random for tch backend

* Int random for burn-fusion

* int random for autodiff

* Int random for candle backend

* Int random for ndarray backend

* Int random for wgpu backend

* Merge imports

* Typo

* Shader file for int uniform distribution

* Create AutotuneOperationSet and public int_sum_dim_autotune

* Adjust bounds to 0..10

* Create uniform_int_kernel, unit tests, use new kernel

* Reduction kernels for regular and shared memory sum_dim int operations

* Macro that accomadates wgpu IntElement

* Add autotuning to int_mean_dim

* Use correct macro for Int autotuning

* Add int_mean_dim_shared_memory

* Add int_mean_dim and unit test

* Create autotunables for mean_dim

* Run fmt

* Remove comment

* Finish resolving merge conflict, fix doc

* Make the element trait bound a parameter to reduce_tune_ops macro

* Update book

* Fix requested change

* Change range to [0, 255] and update test accordingly

* Forgot to include candle in last commit

* Fix comment

* Use correct int autotune for mean dim

* Fix typo- not sure how this passed earlier

* Resolve syntax issues from merge

* Fix cast_float

* Saving here

* Continue fixing merge conflicts, all tests pass locally

* Run fmt

* Change cast_float to cast_u32_to_float

* Make uniform_int_inner_loop safer

* Be even more explicit about u32 casts

* Skip an intermediate step and cast directly to u32

* Replace JitElement + Element with IntElement

* Run fmt

* This should fix the CI

* This time for sure
2024-02-26 14:53:21 -05:00
dependabot[bot] cbf7550d43
Bump serde_json from 1.0.113 to 1.0.114 (#1330)
Bumps [serde_json](https://github.com/serde-rs/json) from 1.0.113 to 1.0.114.
- [Release notes](https://github.com/serde-rs/json/releases)
- [Commits](https://github.com/serde-rs/json/compare/v1.0.113...v1.0.114)

---
updated-dependencies:
- dependency-name: serde_json
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-02-24 11:29:33 -06:00
dependabot[bot] a9d741ed83
Bump serde from 1.0.196 to 1.0.197 (#1331)
Bumps [serde](https://github.com/serde-rs/serde) from 1.0.196 to 1.0.197.
- [Release notes](https://github.com/serde-rs/serde/releases)
- [Commits](https://github.com/serde-rs/serde/compare/v1.0.196...v1.0.197)

---
updated-dependencies:
- dependency-name: serde
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-02-24 11:29:23 -06:00
dependabot[bot] 212bdb779c
Bump syn from 2.0.49 to 2.0.50 (#1332)
Bumps [syn](https://github.com/dtolnay/syn) from 2.0.49 to 2.0.50.
- [Release notes](https://github.com/dtolnay/syn/releases)
- [Commits](https://github.com/dtolnay/syn/compare/2.0.49...2.0.50)

---
updated-dependencies:
- dependency-name: syn
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-02-24 11:29:06 -06:00
dependabot[bot] 5742b00a2b
Bump anyhow from 1.0.79 to 1.0.80 (#1333)
Bumps [anyhow](https://github.com/dtolnay/anyhow) from 1.0.79 to 1.0.80.
- [Release notes](https://github.com/dtolnay/anyhow/releases)
- [Commits](https://github.com/dtolnay/anyhow/compare/1.0.79...1.0.80)

---
updated-dependencies:
- dependency-name: anyhow
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-02-24 11:28:47 -06:00
Joshua Ferguson 706e0ebce2
Parser rewrite (#1296)
* Running into issues with identity nodes

* Vec<RefCell<Node>> seems to work for this

* back to passing tests

* Reworked IO into separate struct

* working towards exploiting topological ordering and more informative ident errors

* the passing of an initializer to coalesce is temporary

* cleaning up dead code

* handled unsqueeze

* reworked node initialization and dim inference

* mainly cleanup

* changed how io use is tracked, moved unsqueeze remapping out of dim inference

* `cargo xtask run-checks all` now passes

* added a fixme and a few doc strings

* removing println and dead code

* spaces in doc strings

* altered top sort to work on node proto, moved prior to node gen

* Update ir.rs

* Update from_onnx.rs

removed dead code

* updated doc string

* camalcased Onnx Graph Builder

* removed self import?
2024-02-24 10:51:58 -06:00
Arjun31415 8e23057c6b
Feature Addition: PRelu Module (#1328) 2024-02-24 10:24:22 -05:00
Yu Sun 1da47c9bf1
feat: add prelude module for convenience (#1335) 2024-02-24 10:17:30 -05:00
Tushushu 27f2095bcd
Implement Instance Normalization (#1321)
* config

* rename as instances, otherwise won't work

* refactor

* InstanceNormConfig

* remove unused var

* forward

* rename

* based on gn

* unit tests

* fix tests

* update doc

* update onnx doc

* renaming method

* add comment

---------

Co-authored-by: VungleTienan <tienan.liu@vungle.com>
2024-02-23 23:31:43 -06:00
Guillaume Lagrange f5bd2a474f
Check that pa_type is valid before checking if is_binary (#1354) 2024-02-23 09:44:03 -06:00
Dilshod Tadjibaev 08302e38fc
Fix broken test and run-checks script (#1347) 2024-02-23 10:06:51 -05:00
Aasheesh Singh c86db83fa9
Add support for Any, All operations to Tensor (#1342)
* add any, all op implementation for all tensor types

* add op to burn-book

* fix formatting

* refactor tensor operations from numeric to BaseOps.

* fix book doc

* comments fix and add more tests
2024-02-23 10:06:31 -05:00
Dilshod Tadjibaev 261e7eca1d
Add sub-crates as members of workspace (#1348) 2024-02-22 16:39:20 -05:00
Dilshod Tadjibaev d6e859330f
Pytorch message updates (#1344)
* Update pytorch-model.md

* Update error.rs
2024-02-22 12:12:50 -06:00
Nathaniel Simard b256c0404e
Refactor/wgpu/memco (#1340) 2024-02-22 07:59:54 -05:00
Guillaume Lagrange bff4961426
Add enum module support (#1337) 2024-02-21 17:03:34 -05:00
Sylvain Benner 4427768570
[refactor] Move burn crates to their own crates directory (#1336) 2024-02-20 13:57:55 -05:00
Dilshod Tadjibaev e9bb273700
Pytorch config extraction (#1323)
* PyTorch config deserializer from .pt file

* Update pytorch-model.md

* Format the book section

* Update Cargo.lock

* Recommend to resave config as json

* Fix comment wording
2024-02-20 09:52:36 -06:00
Richard Santos fc493c4cf2
Refactor xtask (#1288)
* refactor the publish.rs file in xtask

* fixes after running checks

* remove extra space

* Update messages to be more conventional and follow rust guidelines

---------

Co-authored-by: iamricks <richardsantos@Richards-MacBook-Pro.local>
2024-02-20 08:54:48 -05:00
Luni-4 32bd8792cc
[CI] Fix codecov and update to weekly the `.dependabot` file for `cargo` (#1320)
* ci: Fix codecov

* ci: Add all dependencies to a dependabot group

* Update dependabot scheduling for cargo
2024-02-20 08:44:44 -05:00
github-actions[bot] 188b619002
Combined PRs (#1327)
* Bump clap from 4.5.0 to 4.5.1

Bumps [clap](https://github.com/clap-rs/clap) from 4.5.0 to 4.5.1.
- [Release notes](https://github.com/clap-rs/clap/releases)
- [Changelog](https://github.com/clap-rs/clap/blob/master/CHANGELOG.md)
- [Commits](https://github.com/clap-rs/clap/compare/clap_complete-v4.5.0...v4.5.1)

---
updated-dependencies:
- dependency-name: clap
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

* Bump syn from 2.0.48 to 2.0.49

Bumps [syn](https://github.com/dtolnay/syn) from 2.0.48 to 2.0.49.
- [Release notes](https://github.com/dtolnay/syn/releases)
- [Commits](https://github.com/dtolnay/syn/compare/2.0.48...2.0.49)

---
updated-dependencies:
- dependency-name: syn
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-02-19 08:53:41 -05:00
dependabot[bot] 866daa0fa4
Bump clap from 4.5.0 to 4.5.1 (#1318)
Bumps [clap](https://github.com/clap-rs/clap) from 4.5.0 to 4.5.1.
- [Release notes](https://github.com/clap-rs/clap/releases)
- [Changelog](https://github.com/clap-rs/clap/blob/master/CHANGELOG.md)
- [Commits](https://github.com/clap-rs/clap/compare/clap_complete-v4.5.0...v4.5.1)

---
updated-dependencies:
- dependency-name: clap
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-02-19 08:49:09 -05:00
Guillaume Lagrange 80f3cddcc1
Fix LogEventStore end epoch log (#1314) 2024-02-19 08:45:54 -05:00
Sylvain Benner 9e61b6687a
[CI] Trigger test suite when Cargo.lock file is updated (#1326) 2024-02-19 06:38:45 -05:00
Nathaniel Simard 843dd492c2
[Refactor] Just-In-Time Compilation Pipeline (#1313) 2024-02-16 14:45:59 -05:00
dependabot[bot] 24287237d1
Bump env_logger from 0.11.1 to 0.11.2 (#1308)
Bumps [env_logger](https://github.com/rust-cli/env_logger) from 0.11.1 to 0.11.2.
- [Release notes](https://github.com/rust-cli/env_logger/releases)
- [Changelog](https://github.com/rust-cli/env_logger/blob/main/CHANGELOG.md)
- [Commits](https://github.com/rust-cli/env_logger/compare/v0.11.1...v0.11.2)

---
updated-dependencies:
- dependency-name: env_logger
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-02-16 14:19:53 -05:00
dependabot[bot] 89520b2b73
Bump arboard from 3.3.0 to 3.3.1 (#1307)
Bumps [arboard](https://github.com/1Password/arboard) from 3.3.0 to 3.3.1.
- [Release notes](https://github.com/1Password/arboard/releases)
- [Changelog](https://github.com/1Password/arboard/blob/master/CHANGELOG.md)
- [Commits](https://github.com/1Password/arboard/compare/v3.3.0...v3.3.1)

---
updated-dependencies:
- dependency-name: arboard
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-02-16 14:19:42 -05:00
Dilshod Tadjibaev 44266d5fd4
Make all struct CamelCase (#1316) 2024-02-15 13:00:37 -06:00
Dilshod Tadjibaev dfb739c89a
Rename GELU to Gelu (#1311)
* Rename GELU to Gelu

This is to follow Rust naming convention
2024-02-15 10:39:06 -06:00
Joshua Ferguson d1273d4963
Unsqueeze op (#1236) 2024-02-15 10:33:41 -05:00
Jakub 3592f3799a
fix(book): add missing second parameter to CrosEntropyLoss constructor (#1301)
* fix(book): add missing second parameter to CrosEntropyLoss constructor

CrossEntropyLoss::new() expects two parameters, the pad_index and the device

* fix: fix missing closing parenthese
2024-02-15 09:46:41 -05:00
Sylvain Benner 00b6c7d136
[backend-comparison] Add GitHub authentication to burnbench CLI (#1285)
* [backend-comparison] Add auth command to burnbench CLI

* [backend-comparison] Add --share argument to Burnbench CLI

* Cargo clippy fixes

* Fix typos

* Add comment to explain the FIVE_SECONDS constant

* Use num_args to force at least one arg value and make args required

In the run command, makes the --benches and --backends required
The manual check is no longer necessary

* Use and_then instead of match

* Simplify token verification

* Use map_or instead of match
2024-02-13 11:16:53 -05:00
Sylvain Benner 62809cdb30
[CI] Add workflow to test dependencies and update Cargo.lock (#1303) 2024-02-13 10:49:13 -05:00
Jakub a68b494531
fix(book): add missing device parameter to mode.init() (#1302) 2024-02-13 09:34:03 -05:00
dependabot[bot] 938a9d00b3
Bump clap from 4.4.18 to 4.5.0 (#1281)
Bumps [clap](https://github.com/clap-rs/clap) from 4.4.18 to 4.5.0.
- [Release notes](https://github.com/clap-rs/clap/releases)
- [Changelog](https://github.com/clap-rs/clap/blob/master/CHANGELOG.md)
- [Commits](https://github.com/clap-rs/clap/compare/v4.4.18...clap_complete-v4.5.0)

---
updated-dependencies:
- dependency-name: clap
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-02-12 16:24:18 -05:00
Sylvain Benner 5b48e8d131
[CI] Set minimum supported version of Rust to 1.75 (#1297) 2024-02-12 15:16:42 -05:00
Nathaniel Simard dfc65abd52
[Refactor] Just-In-Time Backend (#1280) 2024-02-12 12:15:07 -05:00
github-actions[bot] 03bbc64031
Combined PRs (#1295)
Combined PRs ➡️📦⬅️
 The following pull requests have been successfully combined on this PR:

Closes Bump thiserror from 1.0.56 to 1.0.57 #1293 Bump thiserror from 1.0.56 to 1.0.57
Closes Bump tokenizers from 0.15.1 to 0.15.2 #1292 Bump tokenizers from 0.15.1 to 0.15.2
Closes Bump bytemuck from 1.14.1 to 1.14.3 #1291 Bump bytemuck from 1.14.1 to 1.14.3
Closes Bump indicatif from 0.17.7 to 0.17.8 #1290 Bump indicatif from 0.17.7 to 0.17.8
2024-02-12 10:42:15 -05:00