Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'tests/performance/api/device.py')
-rw-r--r--tests/performance/api/device.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/tests/performance/api/device.py b/tests/performance/api/device.py
index e27540da747..b61ae42be36 100644
--- a/tests/performance/api/device.py
+++ b/tests/performance/api/device.py
@@ -4,6 +4,7 @@ import platform
import subprocess
from typing import List
+
def get_cpu_name() -> str:
# Get full CPU name.
if platform.system() == "Windows":
@@ -19,6 +20,7 @@ def get_cpu_name() -> str:
return "Unknown CPU"
+
def get_gpu_device(args: None) -> List:
# Get the list of available Cycles GPU devices.
import bpy
@@ -41,6 +43,7 @@ def get_gpu_device(args: None) -> List:
return result
+
class TestDevice:
def __init__(self, device_type: str, device_id: str, name: str, operating_system: str):
self.type = device_type
@@ -48,6 +51,7 @@ class TestDevice:
self.name = name
self.operating_system = operating_system
+
class TestMachine:
def __init__(self, env, need_gpus: bool):
operating_system = platform.system()
@@ -65,4 +69,3 @@ class TestMachine:
def cpu_device(self) -> TestDevice:
return self.devices[0]
-