mirror of
https://github.com/lightbroker/llmsecops-research.git
synced 2026-07-06 13:07:52 +02:00
fix path
This commit is contained in:
@@ -22,7 +22,8 @@ class TestRunLoggingService(AbstractTestRunLoggingService):
|
||||
):
|
||||
self._lock = threading.Lock()
|
||||
timestamp = calendar.timegm(time.gmtime())
|
||||
self.log_file_path = str(f"./tests/logs/test_{test_id}/{str(model_id.value).replace("/", "_")}/{start}_{end}/test_{str(test_id).lower()}_logs_{timestamp}.json").lower()
|
||||
base_path = os.environ.get('TEST_RUNS', '.')
|
||||
self.log_file_path = os.path.join(base_path, str(f"test_{test_id}/{str(model_id.value).replace("/", "_")}/{start}_{end}/test_{str(test_id).lower()}_logs_{timestamp}.json").lower())
|
||||
self._ensure_log_file_exists()
|
||||
|
||||
def _ensure_log_file_exists(self):
|
||||
|
||||
@@ -75,6 +75,7 @@ def setup_test_environment():
|
||||
os.environ["LOG_LEVEL"] = "DEBUG"
|
||||
os.environ["PROMPT_TEMPLATES_DIR"] = "./infrastructure/prompt_templates"
|
||||
os.environ["INJECTION_DATA_DIR"] = "./tests/security/tests/results/01_garak_no_guidelines"
|
||||
os.environ["TEST_RUNS"] = "./tests/logs"
|
||||
os.environ["MODEL_BASE_DIR"] = "./infrastructure/foundation_model"
|
||||
os.environ["MODEL_CPU_DIR"] = "cpu_and_mobile/cpu-int4-rtn-block-32-acc-level-4"
|
||||
os.environ["MODEL_DATA_FILENAME"] = "phi3-mini-4k-instruct-cpu-int4-rtn-block-32-acc-level-4.onnx.data"
|
||||
|
||||
Reference in New Issue
Block a user