Skip to content

tyui592/PytorchToCpp

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

C++ Code to Load a TorchScript Model

This is c++ implementation to load a torchscript object detector.

The detector should take a tensor (1 x Channel(rgb) x Height x Width) as input and output tuple of 3 tensors (boudning box, class id, confidence score)

Usage

Build

$ mkdir build
$ cd build
build$ cmake -DCMAKE_PREFIX_PATH=<libtorch_path> ..
build$ cmake --build . --config Release

Run

build$ ./main -m <model_path> -i <image_path>

References

TODO

  • Make docker file
  • Video Detection

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published