About The Project • Getting Started • License • Literature
Table of Contents
Building a high performance native inference engine with a frontend is quite challenging. This project discovers possibilities in doing it using Flutter/Dart and Rust.
This project is a template.
This enumeration also includes submodules.
- Clone the repo
git clone --recurse-submodules [email protected]:Kataglyphis/Kataglyphis-Inference-Engine.git
Upgrading the flutter/dart bridge dependencies is as simple as this command:
see source
cargo install flutter_rust_bridge_codegen && flutter_rust_bridge_codegen generate
For windows we absolutely do not want to be dependent on MSVC compiler.
Therefore I use clang-cl.
Using clang-cl instead of MSVC needed adjustment. Therefore i give some instructions here.
Adjust the CXX-Flags in the auto-generated Cmake project. Find the folloeing line and adjust accordingly:
# comment this line
# target_compile_options(${TARGET} PRIVATE /W4 /WX /wd"4100")
# add the following:
# target_compile_options(${TARGET} PRIVATE /W3 /WX /wd4100 -Wno-cast-function-type-mismatch -Wno-unused-function)
Now you can build the project by running following commands:
Attention: Adjust paths accordingly.
cd rust
cargo build --release
cp rust\target\release\rust_lib_kataglyphis_inference_engine.dll build\windows\x64\plugins\rust_lib_kataglyphis_inference_engine
cmake C:\GitHub\Kataglyphis-Inference-Engine\windows -B C:\GitHub\Kataglyphis-Inference-Engine\build\windows\x64 -G "Ninja" -DFLUTTER_TARGET_PLATFORM=windows-x64 -DCMAKE_CXX_COMPILER="C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\VC\Tools\Llvm\bin\clang-cl.exe" -DCMAKE_CXX_COMPILER_TARGET=x86_64-pc-windows-msvc
cmake --build C:\GitHub\Kataglyphis-Inference-Engine\build\windows\x64 --config Release --target install --verbose
Upcoming :)
Contributions are what make the open source community such an amazing place to be learn, inspire, and create. Any contributions you make are greatly appreciated.
- Fork the Project
- Create your Feature Branch (
git checkout -b feature/AmazingFeature
) - Commit your Changes (
git commit -m 'Add some AmazingFeature'
) - Push to the Branch (
git push origin feature/AmazingFeature
) - Open a Pull Request
Jonas Heinle - @Cataglyphis_ - [email protected]
Project Link: https://github.com/Kataglyphis/...
Some very helpful literature, tutorials, etc.
CMake/C++