arcface-go

command module
v0.0.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 31, 2022 License: BSD-3-Clause Imports: 3 Imported by: 0

README

Arcface-go

Go implementation of Arcface inference

Prerequisites

  • The onnx-format models used in the code is "buffalo_l" from insightface.
  • ONNX Runtime (v1.12.1 in my environment) is required.
  • OpenCV (v4.5.5 in my environment) is required, because some codes borrowed from gocv to implement EstimateAffinePartial2DWithParams().

Run example

The example is too simple, detect faces in the input image and retrieve features of the first face.

CGO_CPPFLAGS="-I/usr/local/include/opencv4" CGO_LDFLAGS="-lopencv_core -lopencv_calib3d -lopencv_imgproc" LD_LIBRARY_PATH=/usr/local/lib go run example.go
  • If your onnxruntime and opencv is not installed in /usr/local, some paths in CGO flags and LD_LIARARY_PATH should be corrected.
  • path to "buffalo_l" should be corrected in example.go .

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis
Package to provide face-detection and features-retrieving
Package to provide face-detection and features-retrieving
Package to provide some OpenCV functions required in arcface inference.
Package to provide some OpenCV functions required in arcface inference.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL