Files
openvino/tests/model_hub_tests/models_hub_common/constants.py
T
Evgeny Kotov 90087dbb48 Use time limits instead of number iterations limits in GHA performance tests (#21407)
* use perf_counter_ns to measure performance; meausure within time not count

* fixes

* remove nightly

* set 60 secs by default

* fix output html

* code review fixes

* fix runtime duration

* remove unneeded inference

* cleanup
2023-12-07 11:53:27 +04:00

32 lines
1.1 KiB
Python

# -*- coding: utf-8 -*-
# Copyright (C) 2018-2023 Intel Corporation
# SPDX-License-Identifier: Apache-2.0
import os
import tempfile
'''
@brief Time in seconds of measurement performance on each of the networks. This time doesn't include
loading and heating and includes measurement only one of 2 models - got through convert and read_model.
Both "converted" and "read_model" modes will be 2 * runtime_measure_duration
'''
runtime_measure_duration = os.environ.get('RUNTIME_MEASURE_DURATION', '60')
'''
@brief Time in seconds of heating before measurement
'''
runtime_heat_duration = os.environ.get('RUNTIME_HEAT_DURATION', '5')
tf_hub_cache_dir = os.environ.get('TFHUB_CACHE_DIR',
os.path.join(tempfile.gettempdir(), "tfhub_modules"))
os.environ['TFHUB_CACHE_DIR'] = tf_hub_cache_dir
no_clean_cache_dir = False
hf_hub_cache_dir = tempfile.gettempdir()
if os.environ.get('USE_SYSTEM_CACHE', 'True') == 'False':
no_clean_cache_dir = True
os.environ['HUGGINGFACE_HUB_CACHE'] = hf_hub_cache_dir
# supported_devices : CPU, GPU, GNA
test_device = os.environ.get('TEST_DEVICE', 'CPU;GPU').split(';')