Skip to content

alan890104/mlgo

 
 

Repository files navigation

MLGO

MLGO is tensor library for machine learning in pure Golang that can run on MIPS.

The machine learning part of this project refers to the legendary ggml.cpp framework.

Build

pip install -r requirements.txt

Linear Model

See examples/linear_model/

  1. Export the AI model into ONNX

  2. Use ./scripts/convert_onnx_to_ggml.py to convert ONNX to ggml

    python3 ./scripts/convert_onnx_to_ggml.py ./examples/linear_model/onnx/simple_model.onnx ./examples/linear_model/ggml/simple_model.bin
  3. Run code_generator.py to generate /dist/simple_model.go

    mkdir dist
    python3 ./scripts/code_generator.py
  4. Run following command to check this model work

    go run ./dist/simple_model.go

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Go 84.7%
  • Python 12.4%
  • Shell 1.5%
  • Jinja 1.1%
  • Assembly 0.3%