Skip to content

Commit

Permalink
feat/everything: introduce most of the changes for 0.2.0
Browse files Browse the repository at this point in the history
  • Loading branch information
hobofan committed Feb 22, 2016
1 parent 14cc654 commit 1e0db77
Show file tree
Hide file tree
Showing 36 changed files with 3,883 additions and 865 deletions.
20 changes: 9 additions & 11 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,25 +6,23 @@ rust:
- stable
matrix:
allow_failures:
- rust: beta
- rust: stable
- rust: nightly
env: TRAVIS_CARGO_NIGHTLY_FEATURE=lint
env: FEATURES=lint
exclude:
- rust: beta
env: TRAVIS_CARGO_NIGHTLY_FEATURE=lint
env: FEATURES=lint
- rust: stable
env: TRAVIS_CARGO_NIGHTLY_FEATURE=lint
env: FEATURES=lint
before_script:
- |
pip install 'travis-cargo<0.2' --user &&
export PATH=$HOME/.local/bin:$PATH
script:
- |
travis-cargo build &&
travis-cargo test &&
travis-cargo bench &&
travis-cargo --only stable doc
travis-cargo build -- --no-default-features --features $FEATURES &&
travis-cargo test -- --no-default-features --features $FEATURES &&
travis-cargo bench -- --no-default-features --features $FEATURES &&
travis-cargo --only stable doc -- --no-default-features --features $FEATURES
addons:
apt:
packages:
Expand All @@ -47,5 +45,5 @@ env:
global:
- secure: QcJ9u0BrVpvjYnerd/3dukvM+GLFQNikIoDHhtKjVenuM2ozZtW6+/RyyXVC1YMh/SghwTnu4Kcnv1sdmwuiC5KWdPoppfalXdxafPkl5PGEfTOexe6L5UAJNW6BdA4lbRKM3xnaUg0Guq6x6tD/zdABIkh8nym/gRLGKT40e9Xitkf6wUQqPBHTGZimip59qg5Fty8lAD48pCBEXynJm+ihA2tz6EDhp0/7wvieHyEl/FqNwvUL5+Z9EeTzEJfKNF8PA5DTHkgeXgeCnWKLm8cCdPEziRZlgdQtvIW27oZBkNTQGHyqI9/tVYhaW4AeKstzE5BoJuyRzmerWYRQCNiz8bgyAjc5HnpWLJPmPSFaGBWTRzwYwUk/iOUP4YEZiN3p0Xj1sKgSB0TA2AjKWND7cufwjrW8NdPdZ3hURVOnM8DHYSQMm2HOfbUNnkw+P5M8n+flT2HKWFdnPhJ3n12rDlLYdHeg9PQ3emJ6kE8Y/jrNT+6yZRrSwLQnsV0uU8Ii44MFQHpdUOGuOIxZFGh9rjKsUwhruUpGtbwI4FWPOqiQJvIaBFY1IUjIVlVCZevvIG3fPXvPksIEKwK93hM/ThDi2PLq2qwBpA87RNfKxDG4S0aR2j19IG+ludbpPcP95mYFVnGCb4rpj44iZoCifC8c9tVqC4L85hEGzik=
matrix:
- TRAVIS_CARGO_NIGHTLY_FEATURE=dev
- TRAVIS_CARGO_NIGHTLY_FEATURE=lint
- FEATURES=travis
- FEATURES=lint
31 changes: 27 additions & 4 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,35 @@ keywords = ["deep-learning", "neural-networks", "machine-learning", "framework"]
license = "MIT"

[dependencies]
phloem = "~0.3.0"
collenchyma = "= 0.0.3"
log = "~0.3.2"
collenchyma = { version = "0.0.8", default-features = false }
collenchyma-blas = { version = "0.2.0", default-features = false }
collenchyma-nn = { version = "0.3.0", default-features = false }

log = "0.3.2"
rand = "0.3.0"

clippy = { version = "0.0.41", optional = true }

timeit = "0.1.2"

[dev-dependencies]
env_logger = "0.3"

[features]
default = []
default = ["native", "cuda", "opencl"]
native = ["collenchyma/native", "collenchyma-blas/native", "collenchyma-nn/native"]
cuda = ["collenchyma/cuda", "collenchyma-blas/cuda", "collenchyma-nn/cuda"]
opencl = ["collenchyma/opencl", "collenchyma-blas/opencl", "collenchyma-nn/opencl"]

travis = ["native"]
dev = []
unstable = [] # for travis-cargo
lint = ["clippy"]

[profile.bench]
opt-level = 3
debug = false
rpath = false
lto = false
debug-assertions = false
codegen-units = 1
20 changes: 17 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,7 @@ such as feeding in data, logging, or returning results. You can use the layers
that ship with Leaf (e.g. Convolutional, ReLU, RNN, SVM,
etc.) or thanks to Rust, easily extend Leaf with your own layers.

Leaf strives for leading-edge performance
([benchmarks are next][benchmarks-issue]), while providing a clear and
Leaf strives for [leading-edge performance][benchmarks], while providing a clear and
expressive architecture that creates - as we hope - an innovative and active
community around machine intelligence and fuels future research.

Expand All @@ -42,7 +41,7 @@ For more information,
[rust]: https://www.rust-lang.org/
[autumn]: http://autumnai.com
[tensorflow]: https://github.com/tensorflow/tensorflow
[benchmarks-issue]: https://github.com/autumnai/leaf/issues/26
[benchmarks]: #benchmarks
[documentation]: http://autumnai.github.io/leaf

> Disclaimer: Leaf is currently in a very early and heavy stage of development.
Expand All @@ -69,6 +68,21 @@ Leaf right from the command line.
[cargo-edit]: https://github.com/killercup/cargo-edit
[leaf-examples]: https://github.com/autumnai/leaf-examples

## Benchmarks

| (in ms) | Leaf | Torch | Neon | Caffe | Tensorflow |
| ---------------- |---------|----------|---------|----------|------------|
| **Alexnet**
| *FORWARD* | 30.8 | 33.0 | 30.9 | 42.0 | 46.1 |
| *BACKWARD* | 70.6 | 66.1 | 67.2 | 85.3 | 156.0 |
| *TOTAL* | 101.4 | 99.1 | 98.1 | 127.3 | 202.1 |
| **Overfeat**
| *FORWARD* | 104.6 | 113.5 | | 142.3 | |
| *BACKWARD* | 216.7 | 213.7 | | 287.9 | |
| *TOTAL* | 321.3 | 327.2 | | 430.2 | |
| | | | | | | |


## Leaf Ecosystem and Extensions

We design Leaf and all other crates for machine learning completely modular and
Expand Down
Loading

0 comments on commit 1e0db77

Please sign in to comment.