Skip to content

Latest commit

 

History

History
13 lines (8 loc) · 277 Bytes

README.md

File metadata and controls

13 lines (8 loc) · 277 Bytes

pytorch-op

Basic example of how to build a custom op for a PyTorch model

python3 -m pip install torch numpy onnx

cmake -DCMAKE_PREFIX_PATH="$(python3 -c 'import torch.utils; print(torch.utils.cmake_prefix_path)')" -S . -B build

make -C build

python3 test_add.py