Use optimised release for visual haar
This commit is contained in:
parent
8b64e8301b
commit
16c37ee750
3 changed files with 5 additions and 5 deletions
|
@ -28,4 +28,4 @@ The installation in Windows can be done, though it is quite elaborate:
|
|||
* `cd .\dnn\face_detector`
|
||||
* `python.exe .\download_weights.py`
|
||||
* `cd .\visualhaar`
|
||||
* `cargo build --lib`
|
||||
* `cargo build --lib --release`
|
||||
|
|
|
@ -344,12 +344,12 @@ def process3_haar(in_q, out_q, cascade_file):
|
|||
|
||||
typedef void* haarclassifier;
|
||||
haarclassifier classifier_new(char *filename);
|
||||
void scan_image(haarclassifier, size_t width,size_t height, char *input, char *buffer, size_t length, bool debug);
|
||||
void scan_image(haarclassifier, size_t width,size_t height, char *input, char *buffer, size_t length, size_t min_face_factor, bool debug);
|
||||
""")
|
||||
|
||||
dir_path = os.path.dirname(os.path.realpath(__file__))
|
||||
|
||||
lib_path = os.path.join(dir_path, "..", "visualhaar", "target", "debug")
|
||||
lib_path = os.path.join(dir_path, "..", "visualhaar", "target", "release")
|
||||
so_path = os.path.join(lib_path, "libvisual_haarcascades_lib.so")
|
||||
dll_path = os.path.join(lib_path, "visual_haarcascades_lib.dll")
|
||||
|
||||
|
@ -404,7 +404,7 @@ def process3_haar(in_q, out_q, cascade_file):
|
|||
logger.info("Start haar scan")
|
||||
|
||||
start = time.time()
|
||||
C.scan_image(haar, width, height, buffer2, buffer, buffer_len, False)
|
||||
C.scan_image(haar, width, height, buffer2, buffer, buffer_len, 5, False)
|
||||
logger.info(f"Visualised scan into buffer: {buffer}")
|
||||
print(f"duration: {time.time() - start}s")
|
||||
|
||||
|
|
|
@ -1 +1 @@
|
|||
Subproject commit 7c7ae29bf9e1390ea304e3708e8f92f6d57f87ff
|
||||
Subproject commit ac1aea1d68f346be194e64a3275629a177327f2e
|
Loading…
Reference in a new issue