Commit Graph

1043 Commits

Author SHA1 Message Date
Sylvain Benner 09d4c709f4
Add BSL notice for error-code and clipboard-win (#1612) 2024-04-12 14:06:28 -04:00
Guillaume Lagrange 9ce9dd4c21
Add burn-jit crate to publish workflow (#1609) 2024-04-12 13:18:31 -04:00
Guillaume Lagrange 63947d20a2
Fix missing clone derive for MnistBatcher in the book (#1608) 2024-04-12 12:16:28 -04:00
Nathaniel Simard ff844b1667
Fix candle backend sync (#1579)
* Fix candle backend sync

* tch mps sync

* clippy

---------

Co-authored-by: louisfd <louisfd94@gmail.com>
2024-04-12 12:15:50 -04:00
Aasheesh Singh fb1da53a38
support for rotary positional encoding to transformer modules. (#1604)
* add rotary positional encoding to transformer modules.

* fix f64 error

* use num_traits

* add panic condition
2024-04-12 11:45:49 -04:00
Guillaume Lagrange 06ce2b02d6
Fix missing device in custom training loop book example (#1606) 2024-04-12 10:34:04 -04:00
Louis Fortier-Dubois 23210f05f2
JIT: Autotune matmul tiling 2d unroll (#1601)
* autotune tiling 2d unroll

* clippy

* forgotten important stuff
2024-04-12 10:15:21 -04:00
Nathaniel Simard 07a61a1cec
Fix autodiff memory management graph cleaning (#1602) 2024-04-11 16:21:00 -04:00
Guillaume Lagrange 0cbe9a927d
Add learner training report summary (#1591)
* Add training report summary

* Fix LossMetric batch size state

* Add NumericEntry de/serialize

* Fix clippy suggestion

* Compact recorder does not use compression (anymore)

* Add learner summary expected results tests

* Add summary to learner builder and automatically display in fit

- Add LearnerSummaryConfig
- Keep track of summary metrics names
- Add model field when displaying from learner.fit()
2024-04-11 12:32:25 -04:00
Louis Fortier-Dubois bdb62fbcd0
Repeat ops autodiff & fusion + fix autodiff ones & zeros (#1600)
* added repeat to autodiff and fusion + zero one backend init in autodiff

* autodiff for repeat
2024-04-11 11:32:45 -04:00
Sylvain Benner 15f2e49aca
Add Blaze badge. (#1595)
* Add Blaze badge.

Co-authored-by: David Chavez <david@dcvz.io>
2024-04-11 09:53:55 -04:00
David Chavez 4488e89704
[CI] Add a retry on adding ppa for kisak (#1599)
* Add a retry on adding ppa for kisak

* Share llvmpipe installation
2024-04-11 09:13:57 -04:00
David Chavez a880d2cf64
Migrate workflows to use Blaze runners (#1596) 2024-04-10 14:07:41 -04:00
github-actions[bot] 4befea5f70
Combined PRs (#1590)
* Bump h2 from 0.3.24 to 0.3.26 in the cargo group

Bumps the cargo group with 1 update: [h2](https://github.com/hyperium/h2).


Updates `h2` from 0.3.24 to 0.3.26
- [Release notes](https://github.com/hyperium/h2/releases)
- [Changelog](https://github.com/hyperium/h2/blob/v0.3.26/CHANGELOG.md)
- [Commits](https://github.com/hyperium/h2/compare/v0.3.24...v0.3.26)

---
updated-dependencies:
- dependency-name: h2
  dependency-type: indirect
  dependency-group: cargo
...

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

* Bump getrandom from 0.2.12 to 0.2.13

Bumps [getrandom](https://github.com/rust-random/getrandom) from 0.2.12 to 0.2.13.
- [Changelog](https://github.com/rust-random/getrandom/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rust-random/getrandom/compare/v0.2.12...v0.2.13)

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

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

* Bump async-trait from 0.1.77 to 0.1.79

Bumps [async-trait](https://github.com/dtolnay/async-trait) from 0.1.77 to 0.1.79.
- [Release notes](https://github.com/dtolnay/async-trait/releases)
- [Commits](https://github.com/dtolnay/async-trait/compare/0.1.77...0.1.79)

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

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

* Bump half from 2.3.1 to 2.4.1

Bumps [half](https://github.com/starkat99/half-rs) from 2.3.1 to 2.4.1.
- [Release notes](https://github.com/starkat99/half-rs/releases)
- [Changelog](https://github.com/starkat99/half-rs/blob/main/CHANGELOG.md)
- [Commits](https://github.com/starkat99/half-rs/compare/v2.3.1...v2.4.1)

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

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

* Bump sysinfo from 0.30.7 to 0.30.8

Bumps [sysinfo](https://github.com/GuillaumeGomez/sysinfo) from 0.30.7 to 0.30.8.
- [Changelog](https://github.com/GuillaumeGomez/sysinfo/blob/master/CHANGELOG.md)
- [Commits](https://github.com/GuillaumeGomez/sysinfo/compare/v0.30.7...v0.30.8)

---
updated-dependencies:
- dependency-name: sysinfo
  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>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2024-04-09 15:01:58 -04:00
M S Hrishikesh 80a41b810e
Fixes to code examples in section 5.2 (#1594)
* Fixes to code examples in section 5.2

* A more generic way to get a device for code examples in Burn book section 5.2

* Change run-checks instruction + fix comment spacing

---------

Co-authored-by: hrishim <hrishim@gail.com>
Co-authored-by: Guillaume Lagrange <lagrange.guillaume.1@gmail.com>
2024-04-09 11:12:37 -04:00
Dilshod Tadjibaev 2f885480ed
Use num-traits for float ops (#1584) 2024-04-08 10:16:20 -05:00
Sylvain Benner ca3dcb9daf
[backend-comparison] Update README (#1581) 2024-04-06 21:06:03 -04:00
Guillaume Lagrange f3e0aa6689
Add multi-label classification dataset and metric (#1572)
* Add multilabel classification dataset

- Add MultiLabel annotation support
- Refactor de/serialize annotation with AnnotationRaw
- Add ImageFolderDataset::with_items methods

* Fix custom-image-classification example deps

* Add image_folder_dataset_multilabel test

* Do not change class names order when provided

* Add hamming score and multi-label classification output

* Add new_classification_with_items test

* Fix clippy suggestions

* Implement default trait for hamming score

* Remove de/serialization and use AnnotationRaw as type

* Fix clippy

* Fix metric backend phantom data
2024-04-05 13:16:46 -04:00
Louis Fortier-Dubois f5159b6d22
Refactor: split JitKernel and SourceKernel (#1569)
* refactor execute_dynamic into Execution

* minor change

* extension cfg

* jitkernel and sourcekernel

* add todo statement

* cleanup and docs

* update book

* fix server dependancy on compiler

* refactor into shader information

* refactor to compile shader once

* clippy

* clippy

* clippy

* fix doc

* fix doc

* fmt

* rename feature flag

* refactor

* All broked

* compile at the right time

* todo done

* all dynamic

* all dynamic in template too

* fmt

* fix ci

---------

Co-authored-by: nathaniel <nathaniel.simard.42@gmail.com>
2024-04-05 12:58:10 -04:00
Nathaniel Simard 1239d9bfa3
[Breaking] Make Tensor, Module, Optimizer !Sync + Refactor Autodiff (#1575) 2024-04-04 16:01:17 -04:00
Guillaume Lagrange ce898ff899
Fix pytorch recorder adapt_linear when using autodiff backend (#1576)
* Fix pytorch recorder adapt_linear when using autodiff backend

* Fix comment typo
2024-04-04 12:29:24 -04:00
Sylvain Benner 65222761fd
[backend-comparison] Add URL to browse results on burn.dev website (#1573) 2024-04-04 10:06:30 -04:00
Sylvain Benner 9a1459797f
[backend-comparison] Rework burnbench output to be nicer and more compact (#1568)
* [backend-comparison] Remove tui

* [backend-comparison] Add nice and compact burnbench output

* [backend-comparison] Cargo check fixes

* Tweak bar style for consistency on different terminals

* [backend-comparison] Add uploading state to nice processor

Also simplified with only one processor for both stdout and stderr
since now we also need to process stdout to detect uploading.

* [backend-comparison] Add spinner to have feedback while compiling

* [backend-comparison] Fix Compiling status message on MacOS

* [backend-comparison] Remove prefix in progress bar message

* [backend-comparison] Refactor tracker to use tick and AtomicU64

* [backend-comparison] Set OutputProcessor bounds at the trait level

* [backend-comparison] Fix typos and remove dead code

* [backend-comparison] Create run_cargo function in for loops
2024-04-03 15:41:35 -04:00
Guillaume Lagrange 0978c8a586
Support multilabel binary cross entropy (#1571)
* Support multilabel binary cross entropy

* Add missing alloc Vec
2024-04-03 08:03:07 -04:00
dependabot[bot] 93fac73e6d
Bump clap from 4.5.2 to 4.5.4 (#1563)
Bumps [clap](https://github.com/clap-rs/clap) from 4.5.2 to 4.5.4.
- [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.5.2...v4.5.4)

---
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-04-02 23:31:36 -04:00
Dilshod Tadjibaev beff9a8c57
Update pytorch-model.md (#1570) 2024-04-02 14:17:51 -05:00
Nathaniel Simard b0c5986d16
Feat/lazy init (#1539) 2024-04-02 10:13:35 -04:00
Sylvain Benner c4eac86ce5
[backend-comparison] Add all choice to --benches and --backends (#1567)
+ Make some tweaks in logs
2024-04-02 09:27:49 -04:00
Guillaume Lagrange 8d210a152f
Move log_sigmoid to activation ops (#1558) 2024-04-02 09:25:40 -04:00
github-actions[bot] 38479be726
Combined PRs (#1566)
* Bump wasm-bindgen-futures from 0.4.41 to 0.4.42

Bumps [wasm-bindgen-futures](https://github.com/rustwasm/wasm-bindgen) from 0.4.41 to 0.4.42.
- [Release notes](https://github.com/rustwasm/wasm-bindgen/releases)
- [Changelog](https://github.com/rustwasm/wasm-bindgen/blob/main/CHANGELOG.md)
- [Commits](https://github.com/rustwasm/wasm-bindgen/commits)

---
updated-dependencies:
- dependency-name: wasm-bindgen-futures
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

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

* Bump reqwest from 0.11.25 to 0.11.27

Bumps [reqwest](https://github.com/seanmonstar/reqwest) from 0.11.25 to 0.11.27.
- [Release notes](https://github.com/seanmonstar/reqwest/releases)
- [Changelog](https://github.com/seanmonstar/reqwest/blob/master/CHANGELOG.md)
- [Commits](https://github.com/seanmonstar/reqwest/compare/v0.11.25...v0.11.27)

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

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

* Bump tokio from 1.36.0 to 1.37.0

Bumps [tokio](https://github.com/tokio-rs/tokio) from 1.36.0 to 1.37.0.
- [Release notes](https://github.com/tokio-rs/tokio/releases)
- [Commits](https://github.com/tokio-rs/tokio/compare/tokio-1.36.0...tokio-1.37.0)

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

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

* Bump serde_json from 1.0.114 to 1.0.115

Bumps [serde_json](https://github.com/serde-rs/json) from 1.0.114 to 1.0.115.
- [Release notes](https://github.com/serde-rs/json/releases)
- [Commits](https://github.com/serde-rs/json/compare/v1.0.114...v1.0.115)

---
updated-dependencies:
- dependency-name: serde_json
  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>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2024-04-01 10:03:19 -04:00
Ilya Dmitrichenko 67994c02d5
Make backend names in JSON reports match burnbench CLI (#1375)
* Make backend names in JSON reports match burnbench CLI

- add `config_name`  to `Backend` trait
- add `backend_config_name` to  `Benchmark` trait
- fix documentation for JSON reports to use correct unit of time

* Revert "Make backend names in JSON reports match burnbench CLI"

This reverts commit a09edb6389.

* [backend-comparison] Serialize the feature name passed to burnbench

---------

Co-authored-by: syl20bnr <sylvain.benner@gmail.com>
2024-04-01 09:48:44 -04:00
Dilshod Tadjibaev edc683bc4b
Update module.md (#1557) 2024-03-29 13:14:01 -04:00
Louis Fortier-Dubois edcd92f13d
Refactor execute_dynamic with Execution struct (#1550) 2024-03-28 17:27:48 -04:00
Nathaniel Simard efc3b2d243
[Breaking] add runtime options in wgpu init methods (#1505) 2024-03-28 12:44:38 -04:00
Sylvain Benner 32a8d8041c
Tweak/add kind to gelu benchmark name (#1533)
* Add kind to gelu benchmark name

* [backend-comparison] Compute column size in benchmarks report
2024-03-28 12:35:15 -04:00
Louis Fortier-Dubois 279be0496a
Conv Transpose: migration + decent speedup (#1541)
* convtranspose benchmark

* adjust bench

* conv transpose works

* Conv Transpose: migration + decent speedup

* delete template folder

* typos

* fix
2024-03-28 12:13:06 -04:00
Guillaume Lagrange b8fc3f141e
Numerically stable log_sigmoid (#1548) 2024-03-28 11:54:23 -04:00
Dilshod Tadjibaev 70b92cb2fb
Update SUPPORTED-ONNX-OPS.md (#1547) 2024-03-28 10:38:53 -05:00
Sylvain Benner 3a1d52067f
[backend-comparison] Fix automatic fusion activation with wgpu (#1542) 2024-03-27 17:40:12 -04:00
Alex Errant 5f7fd5952a
remove exit (#1543) 2024-03-27 16:36:59 -05:00
Sylvain Benner 9f9b52c728
[CI] Switch codecov to informational mode (#1540) 2024-03-27 15:19:06 -04:00
Karsten Becker c21d5a3207
Add LeakyReLu implementation (#1208)
* Implement LeakyReLu

* Cargo fmt

* Apply suggestions

* cargo fmt

* Use float_mul_scalar

* Should be grad

* Add to books module

* Move test files

* Update leaky relu to use activation function

* Update tensor.md

* Fix failing test due to approx

* Add back the function comment

* Fix comment per PR feedback

---------

Co-authored-by: Dilshod Tadjibaev <939125+antimora@users.noreply.github.com>
2024-03-27 13:57:51 -05:00
jcmullwh 626457e1c6
Provide Tensor Padding Helpers #960 (#1097)
* Initial padding approach

Create padding implementation for the last two dimensions of Float and Int Tensors.

Create PadMode Enum, allowing Constant padding.

Create Padding Struct with Uniform, Asymmetric, height, and width implementations.

Create tests for the padding implementation.

* Update padding.rs

remove unneeded import

* Update from Merge

Use crate Element

Swap from old from_data() to new from_data_devauto()

* Formatting Changes

Formatting changes from cargo fmt --all

* Additional Format Change

One more format change that cargo fmt didn't get the first time.

* Changes to Example

Modify Example to ensure it works.

* modify naming

better names for impl / input variables.

* Modify API

- Change Padding to PadSize.
- integrate padding value into PadMode.
- update tests and examples.

* Comments and print

Improve comments+naming and remove println

* Pad Fixes

Moved pad to numeric

Simplified PadMode Element

updated tensor creations

fixed doc example

* Fix test location

* Simplified pad API

* Fix for failed unit tests

* Remove bool_full

* Rename `pads` to `padding`

---------

Co-authored-by: Dilshod Tadjibaev <939125+antimora@users.noreply.github.com>
2024-03-27 12:46:55 -05:00
dependabot[bot] f6f6b5c0fa
Bump uuid from 1.7.0 to 1.8.0 (#1514)
Bumps [uuid](https://github.com/uuid-rs/uuid) from 1.7.0 to 1.8.0.
- [Release notes](https://github.com/uuid-rs/uuid/releases)
- [Commits](https://github.com/uuid-rs/uuid/compare/1.7.0...1.8.0)

---
updated-dependencies:
- dependency-name: uuid
  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>
Co-authored-by: Dilshod Tadjibaev <939125+antimora@users.noreply.github.com>
2024-03-27 12:42:06 -05:00
Nathaniel Simard 40a26bd2ea
Feat/backend bridge (#1529) 2024-03-26 19:24:45 -04:00
Sylvain Benner 28233d9f59
[backend-comparison] Add Operating System information (#1531)
* [backend-comparison] Add Operating System information

* [backend-comparison] Simplify serialization of os info
2024-03-26 15:58:38 -04:00
Louis Fortier-Dubois 5bac300688
Migrate/jit/interpolate (#1528)
* separate forward backward

* refactor with pool strategy

* refactor further

* pooling refactored

* refactoring for adaptive wip

* wip adaptive

* adaptive

* delete some wgsl

* avg pool backward

* clippy

* refactor interpolate files

* nearest shader

* nearest

* some boilerplate

* wip

* bilinear

* nearest backward

* cubic

* cleanup

* minor refactor

* add some white space
2024-03-26 08:57:26 -04:00
Louis Fortier-Dubois 37b61ea646
Migrate/jit/adaptive avg pool backward (#1530)
* separate forward backward

* refactor with pool strategy

* refactor further

* pooling refactored

* refactoring for adaptive wip

* wip adaptive

* adaptive

* delete some wgsl

* avg pool backward

* clippy

* minor refactor

* works

* delete wgsl
2024-03-26 08:38:06 -04:00
Aasheesh Singh a77979e0b6
add rms norm layer (#1527) 2024-03-25 18:59:11 -04:00
dependabot[bot] ea7263859a
Bump regex from 1.10.3 to 1.10.4 (#1513)
Bumps [regex](https://github.com/rust-lang/regex) from 1.10.3 to 1.10.4.
- [Release notes](https://github.com/rust-lang/regex/releases)
- [Changelog](https://github.com/rust-lang/regex/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rust-lang/regex/compare/1.10.3...1.10.4)

---
updated-dependencies:
- dependency-name: regex
  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-03-25 16:53:35 -04:00