mirror of
https://github.com/deepinsight/insightface.git
synced 2026-07-26 01:07:48 +00:00
Update inspireface to 1.2.0
This commit is contained in:
@@ -1,6 +1,5 @@
|
||||
|
||||
import inspireface as ifac
|
||||
from inspireface.param import *
|
||||
import inspireface as isf
|
||||
import click
|
||||
|
||||
@click.command()
|
||||
@@ -9,12 +8,12 @@ def case_show_system_resource_statistics(resource_path):
|
||||
"""
|
||||
This case is used to test the system resource statistics.
|
||||
"""
|
||||
ret = ifac.launch(resource_path)
|
||||
ret = isf.launch(resource_path)
|
||||
assert ret, "Launch failure. Please ensure the resource path is correct."
|
||||
print("-" * 100)
|
||||
print("Initialization state")
|
||||
print("-" * 100)
|
||||
ifac.show_system_resource_statistics()
|
||||
isf.show_system_resource_statistics()
|
||||
print("-" * 100)
|
||||
print("Create 10 sessions")
|
||||
print("-" * 100)
|
||||
@@ -22,16 +21,16 @@ def case_show_system_resource_statistics(resource_path):
|
||||
num_created_sessions = 10
|
||||
sessions = []
|
||||
for i in range(num_created_sessions):
|
||||
session = ifac.InspireFaceSession(HF_ENABLE_FACE_RECOGNITION, HF_DETECT_MODE_ALWAYS_DETECT)
|
||||
session = isf.InspireFaceSession(isf.HF_ENABLE_FACE_RECOGNITION, isf.HF_DETECT_MODE_ALWAYS_DETECT)
|
||||
sessions.append(session)
|
||||
ifac.show_system_resource_statistics()
|
||||
isf.show_system_resource_statistics()
|
||||
print("-" * 100)
|
||||
print("Release 10 sessions")
|
||||
print("-" * 100)
|
||||
print()
|
||||
for session in sessions:
|
||||
session.release()
|
||||
ifac.show_system_resource_statistics()
|
||||
isf.show_system_resource_statistics()
|
||||
|
||||
if __name__ == "__main__":
|
||||
case_show_system_resource_statistics()
|
||||
|
||||
Reference in New Issue
Block a user