From 078f66510f82a2b3fbc642012ee47efdef3356ba Mon Sep 17 00:00:00 2001 From: maekawatoshiki Date: Wed, 11 Sep 2024 16:02:00 +0900 Subject: [PATCH] Rename session* --- Cargo.lock | 44 +++++++++---------- Cargo.toml | 4 +- crates/altius_py/Cargo.toml | 12 ++--- crates/session/Cargo.toml | 2 +- .../{session-cpu => session_cpu}/Cargo.toml | 4 +- .../examples/deit_cpu.rs | 0 .../examples/mnist_cpu.rs | 0 .../examples/mobilenet_cpu.rs | 0 .../examples/vit_cpu.rs | 0 .../src/builder.rs | 0 .../{session-cpu => session_cpu}/src/lib.rs | 0 .../src/session.rs | 0 .../src/translator.rs | 0 .../tests/ops_bin.rs | 0 .../tests/ops_conv.rs | 0 .../Cargo.toml | 4 +- .../benches/interpreter.rs | 0 .../examples/deit.rs | 0 .../examples/infer.rs | 0 .../examples/mnist.rs | 0 .../examples/mobilenet.rs | 0 .../examples/vit.rs | 0 .../src/builder.rs | 0 .../src/conv2d.rs | 0 .../src/fast_math.rs | 0 .../src/gemm.rs | 0 .../src/lib.rs | 0 .../src/session.rs | 0 .../src/thread.rs | 0 .../tests/mobilenet.rs | 0 .../tests/op_bin.rs | 0 crates/wasm/Cargo.toml | 6 +-- crates/wasm/package.json | 2 +- 33 files changed, 39 insertions(+), 39 deletions(-) rename crates/{session-cpu => session_cpu}/Cargo.toml (92%) rename crates/{session-cpu => session_cpu}/examples/deit_cpu.rs (100%) rename crates/{session-cpu => session_cpu}/examples/mnist_cpu.rs (100%) rename crates/{session-cpu => session_cpu}/examples/mobilenet_cpu.rs (100%) rename crates/{session-cpu => session_cpu}/examples/vit_cpu.rs (100%) rename crates/{session-cpu => session_cpu}/src/builder.rs (100%) rename crates/{session-cpu => session_cpu}/src/lib.rs (100%) rename crates/{session-cpu => session_cpu}/src/session.rs (100%) rename crates/{session-cpu => session_cpu}/src/translator.rs (100%) rename crates/{session-cpu => session_cpu}/tests/ops_bin.rs (100%) rename crates/{session-cpu => session_cpu}/tests/ops_conv.rs (100%) rename crates/{session-interpreter => session_interpreter}/Cargo.toml (93%) rename crates/{session-interpreter => session_interpreter}/benches/interpreter.rs (100%) rename crates/{session-interpreter => session_interpreter}/examples/deit.rs (100%) rename crates/{session-interpreter => session_interpreter}/examples/infer.rs (100%) rename crates/{session-interpreter => session_interpreter}/examples/mnist.rs (100%) rename crates/{session-interpreter => session_interpreter}/examples/mobilenet.rs (100%) rename crates/{session-interpreter => session_interpreter}/examples/vit.rs (100%) rename crates/{session-interpreter => session_interpreter}/src/builder.rs (100%) rename crates/{session-interpreter => session_interpreter}/src/conv2d.rs (100%) rename crates/{session-interpreter => session_interpreter}/src/fast_math.rs (100%) rename crates/{session-interpreter => session_interpreter}/src/gemm.rs (100%) rename crates/{session-interpreter => session_interpreter}/src/lib.rs (100%) rename crates/{session-interpreter => session_interpreter}/src/session.rs (100%) rename crates/{session-interpreter => session_interpreter}/src/thread.rs (100%) rename crates/{session-interpreter => session_interpreter}/tests/mobilenet.rs (100%) rename crates/{session-interpreter => session_interpreter}/tests/op_bin.rs (100%) diff --git a/Cargo.lock b/Cargo.lock index e8847cfc..a7a6304a 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -66,7 +66,21 @@ dependencies = [ ] [[package]] -name = "altius-session" +name = "altius_py" +version = "0.1.0" +dependencies = [ + "altius-core", + "altius_session", + "altius_session_cpu", + "altius_session_interpreter", + "cargo-util", + "numpy", + "pyo3", + "pyo3-log", +] + +[[package]] +name = "altius_session" version = "0.1.0" dependencies = [ "altius-core", @@ -86,11 +100,11 @@ dependencies = [ ] [[package]] -name = "altius-session-cpu" +name = "altius_session_cpu" version = "0.1.0" dependencies = [ "altius-core", - "altius-session", + "altius_session", "blis-src", "color-backtrace", "cranelift", @@ -116,11 +130,11 @@ dependencies = [ ] [[package]] -name = "altius-session-interpreter" +name = "altius_session_interpreter" version = "0.1.0" dependencies = [ "altius-core", - "altius-session", + "altius_session", "blas-src", "blis-src", "cblas-sys", @@ -145,32 +159,18 @@ dependencies = [ ] [[package]] -name = "altius-wasm" +name = "altius_wasm" version = "0.1.0" dependencies = [ "altius-core", - "altius-session", - "altius-session-interpreter", + "altius_session", + "altius_session_interpreter", "console_error_panic_hook", "image", "ndarray", "wasm-bindgen", ] -[[package]] -name = "altius_py" -version = "0.1.0" -dependencies = [ - "altius-core", - "altius-session", - "altius-session-cpu", - "altius-session-interpreter", - "cargo-util", - "numpy", - "pyo3", - "pyo3-log", -] - [[package]] name = "android-tzdata" version = "0.1.1" diff --git a/Cargo.toml b/Cargo.toml index c0cebb62..b366c2fd 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -2,8 +2,8 @@ members = [ "crates/core", "crates/session", - "crates/session-cpu", - "crates/session-interpreter", + "crates/session_cpu", + "crates/session_interpreter", "crates/altius_py", "crates/wasm" ] diff --git a/crates/altius_py/Cargo.toml b/crates/altius_py/Cargo.toml index 99e6e31c..26815ddc 100644 --- a/crates/altius_py/Cargo.toml +++ b/crates/altius_py/Cargo.toml @@ -9,9 +9,9 @@ crate-type = ["cdylib"] [dependencies] altius-core = { path = "../core" } -altius-session = { path = "../session" } -altius-session-cpu = { path = "../session-cpu" } -altius-session-interpreter = { path = "../session-interpreter" } +altius_session = { path = "../session" } +altius_session_cpu = { path = "../session_cpu" } +altius_session_interpreter = { path = "../session_interpreter" } pyo3 = { version = "^0.20.0", features = ["extension-module"] } pyo3-log = "^0.9.0" numpy = "^0.20.0" @@ -21,7 +21,7 @@ cargo-util = "^0.2.1" [features] default = ["cblas"] -matrixmultiply-threading = [ "altius-session-interpreter/matrixmultiply-threading" ] -cuda = [ "altius-session-interpreter/cuda" ] -heavy-log = [ "altius-session-interpreter/heavy-log" ] +matrixmultiply-threading = [ "altius_session_interpreter/matrixmultiply-threading" ] +cuda = [ "altius_session_interpreter/cuda" ] +heavy-log = [ "altius_session_interpreter/heavy-log" ] cblas = [] diff --git a/crates/session/Cargo.toml b/crates/session/Cargo.toml index fc4bbe04..01457d54 100644 --- a/crates/session/Cargo.toml +++ b/crates/session/Cargo.toml @@ -1,5 +1,5 @@ [package] -name = "altius-session" +name = "altius_session" version = "0.1.0" edition = "2021" diff --git a/crates/session-cpu/Cargo.toml b/crates/session_cpu/Cargo.toml similarity index 92% rename from crates/session-cpu/Cargo.toml rename to crates/session_cpu/Cargo.toml index 194e70f2..5e672d89 100644 --- a/crates/session-cpu/Cargo.toml +++ b/crates/session_cpu/Cargo.toml @@ -1,5 +1,5 @@ [package] -name = "altius-session-cpu" +name = "altius_session_cpu" version = "0.1.0" edition = "2021" @@ -7,7 +7,7 @@ edition = "2021" log = { workspace = true } rustc-hash = { workspace = true } altius-core = { path = "../core" } -altius-session = { path = "../session" } +altius_session = { path = "../session" } cranelift = { workspace = true } cranelift-module = { workspace = true } cranelift-object = { workspace = true } diff --git a/crates/session-cpu/examples/deit_cpu.rs b/crates/session_cpu/examples/deit_cpu.rs similarity index 100% rename from crates/session-cpu/examples/deit_cpu.rs rename to crates/session_cpu/examples/deit_cpu.rs diff --git a/crates/session-cpu/examples/mnist_cpu.rs b/crates/session_cpu/examples/mnist_cpu.rs similarity index 100% rename from crates/session-cpu/examples/mnist_cpu.rs rename to crates/session_cpu/examples/mnist_cpu.rs diff --git a/crates/session-cpu/examples/mobilenet_cpu.rs b/crates/session_cpu/examples/mobilenet_cpu.rs similarity index 100% rename from crates/session-cpu/examples/mobilenet_cpu.rs rename to crates/session_cpu/examples/mobilenet_cpu.rs diff --git a/crates/session-cpu/examples/vit_cpu.rs b/crates/session_cpu/examples/vit_cpu.rs similarity index 100% rename from crates/session-cpu/examples/vit_cpu.rs rename to crates/session_cpu/examples/vit_cpu.rs diff --git a/crates/session-cpu/src/builder.rs b/crates/session_cpu/src/builder.rs similarity index 100% rename from crates/session-cpu/src/builder.rs rename to crates/session_cpu/src/builder.rs diff --git a/crates/session-cpu/src/lib.rs b/crates/session_cpu/src/lib.rs similarity index 100% rename from crates/session-cpu/src/lib.rs rename to crates/session_cpu/src/lib.rs diff --git a/crates/session-cpu/src/session.rs b/crates/session_cpu/src/session.rs similarity index 100% rename from crates/session-cpu/src/session.rs rename to crates/session_cpu/src/session.rs diff --git a/crates/session-cpu/src/translator.rs b/crates/session_cpu/src/translator.rs similarity index 100% rename from crates/session-cpu/src/translator.rs rename to crates/session_cpu/src/translator.rs diff --git a/crates/session-cpu/tests/ops_bin.rs b/crates/session_cpu/tests/ops_bin.rs similarity index 100% rename from crates/session-cpu/tests/ops_bin.rs rename to crates/session_cpu/tests/ops_bin.rs diff --git a/crates/session-cpu/tests/ops_conv.rs b/crates/session_cpu/tests/ops_conv.rs similarity index 100% rename from crates/session-cpu/tests/ops_conv.rs rename to crates/session_cpu/tests/ops_conv.rs diff --git a/crates/session-interpreter/Cargo.toml b/crates/session_interpreter/Cargo.toml similarity index 93% rename from crates/session-interpreter/Cargo.toml rename to crates/session_interpreter/Cargo.toml index 9341a74d..3eb94d5a 100644 --- a/crates/session-interpreter/Cargo.toml +++ b/crates/session_interpreter/Cargo.toml @@ -1,5 +1,5 @@ [package] -name = "altius-session-interpreter" +name = "altius_session_interpreter" version = "0.1.0" edition = "2021" @@ -7,7 +7,7 @@ edition = "2021" log = { workspace = true } rustc-hash = { workspace = true } altius-core = { path = "../core" } -altius-session = { path = "../session" } +altius_session = { path = "../session" } ndarray = "0.15.6" core_affinity = "^0.7.6" matrixmultiply = "0.3.2" diff --git a/crates/session-interpreter/benches/interpreter.rs b/crates/session_interpreter/benches/interpreter.rs similarity index 100% rename from crates/session-interpreter/benches/interpreter.rs rename to crates/session_interpreter/benches/interpreter.rs diff --git a/crates/session-interpreter/examples/deit.rs b/crates/session_interpreter/examples/deit.rs similarity index 100% rename from crates/session-interpreter/examples/deit.rs rename to crates/session_interpreter/examples/deit.rs diff --git a/crates/session-interpreter/examples/infer.rs b/crates/session_interpreter/examples/infer.rs similarity index 100% rename from crates/session-interpreter/examples/infer.rs rename to crates/session_interpreter/examples/infer.rs diff --git a/crates/session-interpreter/examples/mnist.rs b/crates/session_interpreter/examples/mnist.rs similarity index 100% rename from crates/session-interpreter/examples/mnist.rs rename to crates/session_interpreter/examples/mnist.rs diff --git a/crates/session-interpreter/examples/mobilenet.rs b/crates/session_interpreter/examples/mobilenet.rs similarity index 100% rename from crates/session-interpreter/examples/mobilenet.rs rename to crates/session_interpreter/examples/mobilenet.rs diff --git a/crates/session-interpreter/examples/vit.rs b/crates/session_interpreter/examples/vit.rs similarity index 100% rename from crates/session-interpreter/examples/vit.rs rename to crates/session_interpreter/examples/vit.rs diff --git a/crates/session-interpreter/src/builder.rs b/crates/session_interpreter/src/builder.rs similarity index 100% rename from crates/session-interpreter/src/builder.rs rename to crates/session_interpreter/src/builder.rs diff --git a/crates/session-interpreter/src/conv2d.rs b/crates/session_interpreter/src/conv2d.rs similarity index 100% rename from crates/session-interpreter/src/conv2d.rs rename to crates/session_interpreter/src/conv2d.rs diff --git a/crates/session-interpreter/src/fast_math.rs b/crates/session_interpreter/src/fast_math.rs similarity index 100% rename from crates/session-interpreter/src/fast_math.rs rename to crates/session_interpreter/src/fast_math.rs diff --git a/crates/session-interpreter/src/gemm.rs b/crates/session_interpreter/src/gemm.rs similarity index 100% rename from crates/session-interpreter/src/gemm.rs rename to crates/session_interpreter/src/gemm.rs diff --git a/crates/session-interpreter/src/lib.rs b/crates/session_interpreter/src/lib.rs similarity index 100% rename from crates/session-interpreter/src/lib.rs rename to crates/session_interpreter/src/lib.rs diff --git a/crates/session-interpreter/src/session.rs b/crates/session_interpreter/src/session.rs similarity index 100% rename from crates/session-interpreter/src/session.rs rename to crates/session_interpreter/src/session.rs diff --git a/crates/session-interpreter/src/thread.rs b/crates/session_interpreter/src/thread.rs similarity index 100% rename from crates/session-interpreter/src/thread.rs rename to crates/session_interpreter/src/thread.rs diff --git a/crates/session-interpreter/tests/mobilenet.rs b/crates/session_interpreter/tests/mobilenet.rs similarity index 100% rename from crates/session-interpreter/tests/mobilenet.rs rename to crates/session_interpreter/tests/mobilenet.rs diff --git a/crates/session-interpreter/tests/op_bin.rs b/crates/session_interpreter/tests/op_bin.rs similarity index 100% rename from crates/session-interpreter/tests/op_bin.rs rename to crates/session_interpreter/tests/op_bin.rs diff --git a/crates/wasm/Cargo.toml b/crates/wasm/Cargo.toml index e482936b..51159c7c 100644 --- a/crates/wasm/Cargo.toml +++ b/crates/wasm/Cargo.toml @@ -1,5 +1,5 @@ [package] -name = "altius-wasm" +name = "altius_wasm" version = "0.1.0" edition = "2021" @@ -9,8 +9,8 @@ crate-type = ["cdylib"] [dependencies] wasm-bindgen = "0.2" altius-core = { path = "../core" } -altius-session = { path = "../session" } -altius-session-interpreter = { path = "../session-interpreter" } +altius_session = { path = "../session" } +altius_session_interpreter = { path = "../session_interpreter" } console_error_panic_hook = "0.1.7" image = "0.24.2" ndarray = "0.15.6" diff --git a/crates/wasm/package.json b/crates/wasm/package.json index 239215f4..acd86bf6 100644 --- a/crates/wasm/package.json +++ b/crates/wasm/package.json @@ -1,5 +1,5 @@ { - "name": "altius-wasm", + "name": "altius_wasm", "version": "1.0.0", "description": "", "main": "index.js",