forked from tracel-ai/burn
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add image classification web demo with WebGPU, CPU backends (tracel-a…
- Loading branch information
Showing
31 changed files
with
2,045 additions
and
63 deletions.
There are no files selected for viewing
This file contains 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 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,9 +1,8 @@ | ||
[default] | ||
extend-ignore-identifiers-re = [ | ||
"ratatui", | ||
"NdArray*", | ||
"ND" | ||
] | ||
extend-ignore-identifiers-re = ["ratatui", "NdArray*", "ND"] | ||
|
||
[files] | ||
extend-exclude = ["assets/ModuleSerialization.xml"] | ||
extend-exclude = [ | ||
"assets/ModuleSerialization.xml", | ||
"examples/image-classification-web/src/model/label.txt", | ||
] |
This file contains 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 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 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 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 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 |
---|---|---|
@@ -0,0 +1,35 @@ | ||
[package] | ||
authors = ["Dilshod Tadjibaev (@antimora)"] | ||
edition = "2021" | ||
license = "MIT OR Apache-2.0" | ||
name = "image-classification-web" | ||
publish = false | ||
version = "0.10.0" | ||
|
||
[lib] | ||
crate-type = ["cdylib"] | ||
|
||
[features] | ||
default = [] | ||
|
||
[dependencies] | ||
burn = { path = "../../burn", default-features = false, features = [ | ||
"ndarray-no-std", | ||
"wgpu", | ||
] } | ||
|
||
burn-candle = { path = "../../burn-candle", version = "0.10.0", default-features = false } | ||
|
||
js-sys = "0.3.64" | ||
log = { workspace = true } | ||
serde = { workspace = true } | ||
serde_json = { workspace = true } | ||
serde-wasm-bindgen = "0.6.0" | ||
wasm-bindgen = "0.2.87" | ||
wasm-bindgen-futures = "0.4.37" | ||
wasm-logger = "0.2.0" | ||
wasm-timer = "0.2.5" | ||
|
||
[build-dependencies] | ||
# Used to generate code from ONNX model | ||
burn-import = { path = "../../burn-import" } |
This file contains 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 |
---|---|---|
@@ -0,0 +1,52 @@ | ||
# NOTICES AND INFORMATION | ||
|
||
This file contains notices and information required by libraries that this repository copied or derived from. The use of the following resources complies with the licenses provided. | ||
|
||
## Sample Images | ||
|
||
Image Title: Domestic cat, a ten month old female. | ||
Author: Von.grzanka | ||
Source: https://commons.wikimedia.org/wiki/File:Felis_catus-cat_on_snow.jpg | ||
License: https://creativecommons.org/licenses/by-sa/3.0/ | ||
|
||
Image Title: The George Washington Bridge over the Hudson River leading to New York City as seen from Fort Lee, New Jersey. | ||
Author: John O'Connell | ||
Source: https://commons.wikimedia.org/wiki/File:George_Washington_Bridge_from_New_Jersey-edit.jpg | ||
License: https://creativecommons.org/licenses/by/2.0/deed.en | ||
|
||
Image Title: Coyote from Yosemite National Park, California in snow | ||
Author: Yathin S Krishnappa | ||
Source https://commons.wikimedia.org/wiki/File:2009-Coyote-Yosemite.jpg | ||
License: https://creativecommons.org/licenses/by-sa/3.0/deed.en | ||
|
||
Image Title: Table lamp with a lampshade illuminated by sunlight. | ||
Author: LoMit | ||
Source: https://commons.wikimedia.org/wiki/File:Lamp_with_a_lampshade_illuminated_by_sunlight.jpg | ||
License: https://creativecommons.org/licenses/by-sa/4.0/deed.en | ||
|
||
Image Title: White Pelican Pelecanus onocrotalus at Walvis Bay, Namibia | ||
Author: Rui Ornelas | ||
Source: https://commons.wikimedia.org/wiki/File:Pelikan_Walvis_Bay.jpg | ||
License: https://creativecommons.org/licenses/by/2.0/deed.en | ||
|
||
Image Title: Photo of a traditional torch to be posted at gates | ||
Author: Faizul Latif Chowdhury | ||
Source: https://commons.wikimedia.org/wiki/File:Torch_traditional.jpg | ||
License: https://creativecommons.org/licenses/by-sa/3.0/deed.en | ||
|
||
Image Title: American Flamingo Phoenicopterus ruber at Gotomeer, Riscado, Bonaire | ||
Author: Paul Asman and Jill Lenoble | ||
Source: https://commons.wikimedia.org/wiki/File:Phoenicopterus_ruber_Bonaire_2.jpg | ||
License: https://creativecommons.org/licenses/by/2.0/deed.en | ||
|
||
## ONNX Model | ||
|
||
SqueezeNet 1.1 model is licensed under Apache License 2.0. The model is downloaded from the [ONNX model zoo](https://github.com/onnx/models/tree/main). | ||
|
||
Source: https://github.com/onnx/models/blob/main/vision/classification/squeezenet/model/squeezenet1.1-7.onnx | ||
License: Apache License 2.0 | ||
License URL: https://github.com/onnx/models/blob/main/LICENSE | ||
|
||
## ONNX Labels | ||
|
||
The labels for the SqueezeNet 1.1 model are licensed under Apache License 2.0. The labels are downloaded from the [ONNX model zoo](https://github.com/onnx/models/blob/main/vision/classification/synset.txt) |
Oops, something went wrong.