Skip to content

a-palonskaa/TensorCompiler

Repository files navigation

Tensor Compiler

FRONTEND

A frontend for a tensor compiler that parses neural network models in ONNX format and converts them into an internal graph representation. The graph can be visualized using Graphviz.

qr

Frontend features

  • Reads ONNX models (.onnx) using Protocol Buffers;
  • Builds a computational graph with tensors and operations;
  • Supports operations: Add, Mul, Conv, Relu, MatMul, Gemm;
  • Visualizes the graph as a DOT file and renders it to PNG (requires Graphviz);
  • Logging system with configurable log file (can be found in ./logs);

Requirements

  • C++17
  • CMake 3.10+
  • Protobuf compiler (protoc) and library (libprotobuf-dev)
  • Graphviz
  • Python 3 with onnx and numpy (optional, for generating test models)

Installation

git clone https://github.com/a-palonskaa/TensorCompiler
cd TensorCompiler

Build

cmake -S . -B build -DCMAKE-COMPILE-OPTIONS=ON
cmake --build build --parallel

Run

./build/run [name].onnx [optional -d]

-d is a flag for debug vesion with debug text dump Name from ./models. Image of graph and a dot file are located in ./images.

Testing

cd build
ctest --output-on-failure

Notes

To get absl:

git clone https://github.com/abseil/abseil-cpp.git

Authors:

  • Palonskaya Alina, B01-405 DREC
  • Makarskaya Alexandra, B01-401 DREC

About

No description, website, or topics provided.

Resources

License

Stars

0 stars

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors