index
int64
repo_name
string
branch_name
string
path
string
content
string
import_graph
string
13,827
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/tunables/tunables_copy_test.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Unit tests for deep copy of tunable objects and groups. """ from mlos_bench.tunables.covariant_group import CovariantTunableGroup from mlos_bench.tunables.tunable import Tunable, TunableValue from mlos_bench.tunables.tunable_groups import...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,828
microsoft/MLOS
refs/heads/main
/mlos_core/mlos_core/spaces/adapters/identity_adapter.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Contains the Identity (no-op) Space Adapter class. """ import ConfigSpace import pandas as pd from mlos_core.spaces.adapters.adapter import BaseSpaceAdapter class IdentityAdapter(BaseSpaceAdapter): """Identity (no-op) SpaceAdapter ...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,829
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/services/remote/mock/mock_remote_exec_service.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ A collection Service functions for mocking remote script execution. """ from typing import Any, Dict, Optional from mlos_bench.services.base_service import Service from mlos_bench.services.types.remote_exec_type import SupportsRemoteExec...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,830
microsoft/MLOS
refs/heads/main
/mlos_core/mlos_core/tests/optimizers/one_hot_test.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Tests for one-hot encoding for certain optimizers. """ import pytest import pandas as pd import numpy as np import numpy.typing as npt import ConfigSpace as CS from mlos_core.optimizers import SmacOptimizer # pylint: disable=protected-...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,831
microsoft/MLOS
refs/heads/main
/doc/source/conf.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # # Configuration file for the Sphinx documentation builder. # # This file only contains a selection of the most common options. For a full # list see the documentation: # https://www.sphinx-doc.org/en/master/usage/configuration.html # -- Path...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,832
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/services/__init__.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Services for implementing Environments for mlos_bench. """ from mlos_bench.services.base_service import Service from mlos_bench.services.base_fileshare import FileShareService from mlos_bench.services.local.local_exec import LocalExecServ...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,833
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/services/local/__init__.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Local scheduler side Services for mlos_bench. """ from mlos_bench.services.local.local_exec import LocalExecService __all__ = [ 'LocalExecService', ]
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,834
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/environments/remote/os_env.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ OS-level remote Environment on Azure. """ from typing import Optional import logging from mlos_bench.environments.base_environment import Environment from mlos_bench.environments.status import Status from mlos_bench.services.base_servic...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,835
microsoft/MLOS
refs/heads/main
/mlos_core/mlos_core/spaces/adapters/adapter.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Contains the BaseSpaceAdapter abstract class. """ from abc import ABCMeta, abstractmethod import ConfigSpace import pandas as pd class BaseSpaceAdapter(metaclass=ABCMeta): """SpaceAdapter abstract class defining the basic interface...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,836
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/launcher.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ A helper class to load the configuration files, parse the command line parameters, and instantiate the main components of mlos_bench system. It is used in `mlos_bench.run` module to run the benchmark/optimizer from the command line. """ ...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,837
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/optimizers/mlos_core_opt_smac_test.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Unit tests for mock mlos_bench optimizer. """ import os import sys import pytest from mlos_bench.util import path_join from mlos_bench.optimizers.mlos_core_optimizer import MlosCoreOptimizer from mlos_bench.tunables.tunable_groups impor...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,838
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/services/remote/azure/conftest.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Configuration test fixtures for azure_services in mlos_bench. """ from unittest.mock import patch import pytest from mlos_bench.services.config_persistence import ConfigPersistenceService from mlos_bench.services.remote.azure import Azu...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,839
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/optimizers/toy_optimization_loop_test.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Toy optimization loop to test the optimizers on mock benchmark environment. """ from typing import Tuple import logging import pytest from mlos_core import config_to_dataframe from mlos_core.optimizers.bayesian_optimizers.smac_optimize...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,840
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/tunables/tunable_comparison_test.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Unit tests for checking tunable comparisons. """ import pytest from mlos_bench.tunables.covariant_group import CovariantTunableGroup from mlos_bench.tunables.tunable import Tunable from mlos_bench.tunables.tunable_groups import TunableGr...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,841
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/services/config_persistence.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Helper functions to load, instantiate, and serialize Python objects that encapsulate benchmark environments, tunable parameters, and service functions. """ import os import sys import json # For logging only import logging from typin...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,842
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/optimizers/mock_optimizer.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Mock optimizer for mlos_bench. """ import random import logging from typing import Callable, Dict, Optional, Sequence, Tuple, Union from mlos_bench.environments.status import Status from mlos_bench.tunables.tunable import Tunable, Tunab...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,843
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/storage/trial_telemetry_test.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Unit tests for saving and restoring the telemetry data. """ from datetime import datetime, timedelta from typing import Any, List, Optional, Tuple import pytest from mlos_bench.environments.status import Status from mlos_bench.tunables.t...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,844
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/storage/base_storage.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Base interface for saving and restoring the benchmark data. """ import logging from abc import ABCMeta, abstractmethod from datetime import datetime from types import TracebackType from typing import Optional, Union, List, Tuple, Dict, It...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,845
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/optimizers/llamatune_opt_test.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Unit tests for mock mlos_bench optimizer. """ import pytest from mlos_bench.environments.status import Status from mlos_bench.tunables.tunable_groups import TunableGroups from mlos_bench.optimizers.mlos_core_optimizer import MlosCoreOpti...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,846
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/services/local/local_exec_python_test.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Unit tests for LocalExecService to run Python scripts locally. """ from typing import Any, Dict import json import pytest from mlos_bench.tunables.tunable import TunableValue from mlos_bench.services.local.local_exec import LocalExecSe...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,847
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/config/environments/os/linux/boot/scripts/local/generate_grub_config.py
#!/usr/bin/env python3 # # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Helper script to generate GRUB config from tunable parameters JSON. Run: `./generate_grub_config.py ./input-boot-params.json ./output-grub.cfg` """ import json import argparse def _main(fname_input: str, fname_ou...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,848
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/services/types/local_exec_type.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Protocol interface for Service types that provide helper functions to run scripts and commands locally on the scheduler side. """ from typing import Iterable, Mapping, Optional, Tuple, Union, Protocol, runtime_checkable import tempfile i...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,849
microsoft/MLOS
refs/heads/main
/conftest.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Provides some pytest configuration overrides for both modules. """ # Note: This file is named conftest.py so that pytest picks it up automatically # without the need to adjust PYTHONPATH or sys.path as much. import os from warnings impor...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,850
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/services/remote/__init__.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Tests for mlos_bench.services.remote. Used to make mypy happy about multiple conftest.py modules. """ from .mock.mock_fileshare_service import MockFileShareService from .mock.mock_remote_exec_service import MockRemoteExecService from .moc...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,851
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/optimizers/opt_bulk_register_test.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Unit tests for mock mlos_bench optimizer. """ from typing import Optional, List import pytest from mlos_bench.environments.status import Status from mlos_bench.optimizers.base_optimizer import Optimizer from mlos_bench.optimizers.mock_o...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,852
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/environments/local/local_env_test.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Unit tests for LocalEnv benchmark environment. """ import pytest from mlos_bench.tunables.tunable_groups import TunableGroups from mlos_bench.tests.environments.local import create_local_env, check_local_env_success def test_local_env(t...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,853
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/optimizers/__init__.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Tests for mlos_bench.optimizers. Used to make mypy happy about multiple conftest.py modules. """
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,854
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/environments/remote/vm_env.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ "Remote" VM Environment. """ from typing import Optional import logging from mlos_bench.environments.base_environment import Environment from mlos_bench.services.base_service import Service from mlos_bench.services.types.vm_provisioner_...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,855
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/storage/__init__.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Interfaces to the storage backends for OS Autotune. """ from mlos_bench.storage.base_storage import Storage __all__ = [ 'Storage', ]
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,856
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/tunables/tunable_to_configspace_test.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Unit tests for Tunable to ConfigSpace conversion. """ import pytest from ConfigSpace import UniformIntegerHyperparameter from ConfigSpace import UniformFloatHyperparameter from ConfigSpace import CategoricalHyperparameter from ConfigSpac...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,857
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/optimizers/conftest.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Test fixtures for mlos_bench optimizers. """ import pytest from mlos_bench.tunables.tunable_groups import TunableGroups from mlos_bench.optimizers.mock_optimizer import MockOptimizer from mlos_bench.optimizers.mlos_core_optimizer import ...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,858
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/optimizers/convert_configspace.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Functions to convert TunableGroups to ConfigSpace for use with the mlos_core optimizers. """ import logging from typing import Optional from ConfigSpace.hyperparameters import Hyperparameter from ConfigSpace import UniformIntegerHyperpa...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,859
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/tunables/tunable_accessors_test.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Unit tests for accessing values to the individual parameters within tunable groups. """ import pytest from mlos_bench.tunables.covariant_group import CovariantTunableGroup from mlos_bench.tunables.tunable import Tunable def test_catego...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,860
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/util.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Various helper functions for mlos_bench. """ # NOTE: This has to be placed in the top-level mlos_bench package to avoid circular imports. import os import json import logging import importlib import subprocess from typing import Any, Dic...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,861
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/services/remote/azure/azure_services_test.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Tests for mlos_bench.services.remote.azure.azure_services """ from unittest.mock import MagicMock, patch import pytest from mlos_bench.environments.status import Status from mlos_bench.services.remote.azure.azure_services import AzureV...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,862
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/services/local/local_exec_test.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Unit tests for the service to run the scripts locally. """ import sys import pytest import pandas from mlos_bench.services.local.local_exec import LocalExecService, split_cmdline from mlos_bench.services.config_persistence import ConfigP...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,863
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/optimizers/__init__.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Interfaces and wrapper classes for optimizers to be used in Autotune. """ from mlos_bench.optimizers.base_optimizer import Optimizer from mlos_bench.optimizers.mock_optimizer import MockOptimizer from mlos_bench.optimizers.one_shot_optimi...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,864
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/config/schemas/services/test_services_schemas.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Tests for service schema validation. """ from os import path from typing import Any, Dict, List import pytest from mlos_core.tests import get_all_concrete_subclasses from mlos_bench.config.schemas import ConfigSchema from mlos_bench.se...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,865
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/environments/base_env_test.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Unit tests for base environment class functionality. """ import pytest from mlos_bench.environments.base_environment import Environment _GROUPS = { "group": ["a", "b"], "list": ["c", "d"], "str": "efg", "empty": [], ...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,866
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/config/environments/os/linux/boot/scripts/local/create_new_grub_cfg.py
#!/usr/bin/env python3 # # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Python script to parse through JSON and create new config file. This script will be run in the SCHEDULER. NEW_CFG will need to be copied over to the VM (/etc/default/grub.d). """ import json JSON_CONFIG_FILE = "con...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,867
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/tunables/tunables_str_test.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Unit tests to make sure we always produce a string representation of a TunableGroup in canonical form. """ from mlos_bench.tunables.tunable_groups import TunableGroups def test_tunable_groups_str(tunable_groups: TunableGroups) -> None: ...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,868
microsoft/MLOS
refs/heads/main
/mlos_core/mlos_core/spaces/adapters/llamatune.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Implementation of LlamaTune space adapter. """ from typing import Dict, Optional from warnings import warn import ConfigSpace import numpy as np import numpy.typing as npt import pandas as pd from sklearn.preprocessing import MinMaxScaler...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,869
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/tunables/tunable_definition_test.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Unit tests for checking tunable definition rules. """ import json5 as json import pytest from mlos_bench.tunables.tunable import Tunable def test_categorical_required_params() -> None: """ Check that required parameters are pre...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,870
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/config/services/test_load_service_config_examples.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Tests for loading service config examples. """ import logging from typing import List import pytest from mlos_bench.tests.config import locate_config_examples from mlos_bench.config.schemas.config_schemas import ConfigSchema from mlos_b...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,871
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/config/conftest.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Test fixtures for mlos_bench config loader tests. """ import sys import pytest from mlos_bench.services.config_persistence import ConfigPersistenceService if sys.version_info < (3, 10): from importlib_resources import files else: ...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,872
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/services/base_fileshare.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Base class for remote file shares. """ import logging from abc import ABCMeta, abstractmethod from typing import Any, Dict, Optional from mlos_bench.services.base_service import Service from mlos_bench.services.types.fileshare_type impo...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,873
microsoft/MLOS
refs/heads/main
/mlos_core/mlos_core/optimizers/random_optimizer.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Contains the RandomOptimizer class. """ from typing import Optional import pandas as pd from mlos_core.optimizers.optimizer import BaseOptimizer class RandomOptimizer(BaseOptimizer): """Optimizer class that produces random suggest...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,874
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Mock local services for testing purposes. """ from .mock_local_exec_service import MockLocalExecService __all__ = [ 'MockLocalExecService', ]
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,875
microsoft/MLOS
refs/heads/main
/mlos_core/mlos_core/optimizers/bayesian_optimizers/smac_optimizer.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Contains the wrapper class for SMAC Bayesian optimizers. See Also: <https://automl.github.io/SMAC3/main/index.html> """ from logging import warning from pathlib import Path from typing import Dict, List, Optional, Union, TYPE_CHECKING fro...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,876
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/storage/trial_config_test.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Unit tests for saving and retrieving additional parameters of pending trials. """ from mlos_bench.storage.base_storage import Storage from mlos_bench.tunables.tunable_groups import TunableGroups def test_exp_trial_pending(exp_storage_me...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,877
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/environments/script_env.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Base scriptable benchmark environment. """ import abc import re from typing import Dict, Iterable, Optional from mlos_bench.environments.base_environment import Environment from mlos_bench.services.base_service import Service from mlos_b...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,878
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/storage/sql/schema.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ DB schema definition. """ import logging from typing import List, Any from sqlalchemy import ( Engine, MetaData, Dialect, create_mock_engine, Table, Column, Sequence, Integer, String, DateTime, PrimaryKeyConstraint, ForeignKe...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,879
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/storage/sql/trial.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Saving and updating benchmark data using SQLAlchemy backend. """ import logging from datetime import datetime from typing import List, Optional, Tuple, Union, Dict, Any from sqlalchemy import Engine from sqlalchemy.exc import IntegrityEr...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,880
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/environments/mock_env.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Scheduler-side environment to mock the benchmark results. """ import random import logging from typing import Dict, Optional, Tuple import numpy from mlos_bench.services.base_service import Service from mlos_bench.environments.status im...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,881
microsoft/MLOS
refs/heads/main
/mlos_core/mlos_core/spaces/converters/flaml.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Contains space converters for FLAML. """ from typing import Dict import sys import ConfigSpace import numpy as np import flaml.tune import flaml.tune.sample if sys.version_info >= (3, 10): from typing import TypeAlias else: fr...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,882
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/config/schemas/globals/test_globals_schemas.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Tests for CLI schema validation. """ from os import path import pytest from mlos_bench.config.schemas import ConfigSchema from mlos_bench.tests.config.schemas import get_schema_test_cases, check_test_case_against_schema # General tes...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,883
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/services/remote/azure/azure_services.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ A collection Service functions for managing VMs on Azure. """ import json import time import logging from typing import Any, Callable, Dict, Iterable, Optional, Tuple import requests from mlos_bench.environments.status import Status fr...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,884
microsoft/MLOS
refs/heads/main
/doc/source/_templates/numpydoc_docstring.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # {{index}} {{summary}} {{extended_summary}} {{parameters}} {{returns}} {{yields}} {{other_parameters}} {{attributes}} {{raises}} {{warns}} {{warnings}} {{see_also}} {{notes}} {{references}} {{examples}} {{methods}}
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,885
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/storage/sql/experiment.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Saving and restoring the benchmark data using SQLAlchemy. """ import logging import hashlib from datetime import datetime from typing import Optional, Tuple, List, Dict, Iterator, Any from sqlalchemy import Engine, Connection, Table, col...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,886
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/config/environments/os/linux/runtime/scripts/local/generate_kernel_config_script.py
#!/usr/bin/env python3 # # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Helper script to generate a script to update kernel parameters from tunables JSON. Run: `./generate_kernel_config_script.py ./kernel-params.json ./kernel-params-meta.json ./config-kernel.sh` """ import json import ...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,887
microsoft/MLOS
refs/heads/main
/mlos_core/mlos_core/tests/optimizers/__init__.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Optimizer tests. Note: this file is required so that mypy doesn't complain about overlapping conftest.py modules. """
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,888
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/services/local/mock/mock_local_exec_service.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ A collection Service functions for mocking local exec. """ import logging from typing import Any, Dict, Iterable, Mapping, Optional, Tuple, TYPE_CHECKING from mlos_bench.services.base_service import Service from mlos_bench.services.local...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,889
microsoft/MLOS
refs/heads/main
/mlos_core/mlos_core/optimizers/bayesian_optimizers/bayesian_optimizer.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Contains the wrapper classes for base Bayesian optimizers. """ from abc import ABCMeta, abstractmethod from typing import Optional import pandas as pd import numpy.typing as npt from mlos_core.optimizers.optimizer import BaseOptimizer ...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,890
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/services/types/vm_provisioner_type.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Protocol interface for VM provisioning operations. """ from typing import Tuple, Protocol, runtime_checkable, TYPE_CHECKING if TYPE_CHECKING: from mlos_bench.environments.status import Status @runtime_checkable class SupportsVMOps(...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,891
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/tunables/tunable_slice_references_test.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Unit tests for unique references to tunables when they're loaded multiple times. """ import json5 as json import pytest from mlos_bench.tunables.tunable_groups import TunableGroups def test_duplicate_merging_tunable_groups(tunable_grou...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,892
microsoft/MLOS
refs/heads/main
/mlos_core/mlos_core/tests/spaces/spaces_test.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Tests for mlos_core.spaces """ # pylint: disable=missing-function-docstring from abc import ABCMeta, abstractmethod from typing import Any, Callable, List, NoReturn, Union import numpy as np import numpy.typing as npt import pytest imp...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,893
microsoft/MLOS
refs/heads/main
/mlos_bench/setup.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Setup instructions for the mlos_bench package. """ from logging import warning from itertools import chain from typing import Dict, List from setuptools import setup, find_packages from _version import _VERSION # pylint: disable=impo...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,894
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tunables/tunable.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Tunable parameter definition. """ import copy import collections import logging from typing import Any, Dict, List, Optional, Sequence, Tuple, Type, TypedDict, Union _LOG = logging.getLogger(__name__) """A tunable parameter value type ...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,895
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/environments/__init__.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Tunable Environments for mlos_bench. """ from mlos_bench.environments.status import Status from mlos_bench.environments.base_environment import Environment from mlos_bench.environments.mock_env import MockEnv from mlos_bench.environments...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,896
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/config/schemas/config_schemas.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ A simple class for describing where to find different config schemas and validating configs against them. """ import logging from enum import Enum from os import path, walk, environ from typing import Dict, Iterator, Mapping import json ...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,897
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/services/base_service.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Base class for the service mix-ins. """ import json import logging from typing import Any, Callable, Dict, List, Optional, Union from mlos_bench.services.types.config_loader_type import SupportsConfigLoading from mlos_bench.util import ...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,898
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/config/__init__.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Helper functions for config example loading tests. """ from typing import List import os from mlos_bench.util import path_join def locate_config_examples(config_examples_dir: str) -> List[str]: """Locates all config examples in th...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,899
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/optimizers/mlos_core_optimizer.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ A wrapper for mlos_core optimizers for mlos_bench. """ import logging import os from typing import Optional, Sequence, Tuple, Union import pandas as pd from mlos_core.optimizers import BaseOptimizer, OptimizerType, OptimizerFactory, Sp...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,900
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/__init__.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Tests for mlos_bench. Used to make mypy happy about multiple conftest.py modules. """ from typing import Optional from mlos_bench.util import get_class_from_name # A common seed to use to avoid tracking down race conditions and intermi...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,901
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/config/storage/test_load_storage_config_examples.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Tests for loading storage config examples. """ import logging from typing import List import pytest from mlos_bench.tests.config import locate_config_examples from mlos_bench.config.schemas.config_schemas import ConfigSchema from mlos_b...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,902
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/__init__.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ mlos_bench is a framework to help automate benchmarking and and OS/application parameter autotuning. """
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,903
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/services/remote/mock/__init__.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Mock remote services for testing purposes. """ from typing import Any, Tuple from mlos_bench.environments.status import Status def mock_operation(*_args: Any, **_kwargs: Any) -> Tuple[Status, dict]: """ Mock VM operation that a...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,904
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/optimizers/mock_opt_test.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Unit tests for mock mlos_bench optimizer. """ import pytest from mlos_bench.environments.status import Status from mlos_bench.optimizers.mock_optimizer import MockOptimizer # pylint: disable=redefined-outer-name @pytest.fixture def mo...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,905
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/util_git_test.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Unit tests for get_git_info utility function. """ import re from mlos_bench.util import get_git_info def test_get_git_info() -> None: """ Check that we can retrieve git info about the current repository correctly. """ (g...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,906
microsoft/MLOS
refs/heads/main
/mlos_core/mlos_core/optimizers/flaml_optimizer.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Contains the FlamlOptimizer class. """ from typing import Dict, NamedTuple, Optional, Union from warnings import warn import ConfigSpace import numpy as np import pandas as pd from mlos_core.optimizers.optimizer import BaseOptimizer fro...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,907
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/services/local/local_exec.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Helper functions to run scripts and commands locally on the scheduler side. """ import errno import logging import os import shlex import subprocess import sys from typing import Any, Dict, Iterable, List, Mapping, Optional, Tuple, TYPE_...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,908
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/launcher_test.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Unit tests to check the main CLI launcher. """ import os import re from typing import List import pytest from mlos_bench.services.local.local_exec import LocalExecService from mlos_bench.services.config_persistence import ConfigPersisten...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,909
microsoft/MLOS
refs/heads/main
/mlos_core/mlos_core/optimizers/optimizer.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Contains the BaseOptimizer abstract class. """ import collections from abc import ABCMeta, abstractmethod from typing import List, Optional, Tuple import ConfigSpace import numpy as np import numpy.typing as npt import pandas as pd from...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,910
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/services/local/temp_dir_context.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Helper functions to work with temp files locally on the scheduler side. """ import abc import logging from contextlib import nullcontext from tempfile import TemporaryDirectory from typing import Any, Dict, Optional, Union from mlos_benc...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,911
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/services/types/fileshare_type.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Protocol interface for file share operations. """ from typing import Protocol, runtime_checkable @runtime_checkable class SupportsFileShareOps(Protocol): """ Protocol interface for file share operations. """ def downloa...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,912
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/tunables/tunables_assign_test.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Unit tests for assigning values to the individual parameters within tunable groups. """ import json5 as json import pytest from mlos_bench.tunables.tunable import Tunable from mlos_bench.tunables.tunable_groups import TunableGroups def...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,913
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/optimizers/base_optimizer.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Base class for an interface between the benchmarking framework and mlos_core optimizers. """ import logging from typing import Dict, Optional, Sequence, Tuple, Union from abc import ABCMeta, abstractmethod from distutils.util import strto...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,914
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/config/environments/test_load_environment_config_examples.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Tests for loading environment config examples. """ import logging from typing import List import pytest from mlos_bench.tests.config import locate_config_examples from mlos_bench.config.schemas.config_schemas import ConfigSchema from ml...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,915
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/storage/exp_load_test.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Unit tests for the storage subsystem. """ from datetime import datetime import pytest from mlos_bench.environments.status import Status from mlos_bench.tunables.tunable_groups import TunableGroups from mlos_bench.storage.base_storage imp...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,916
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/conftest.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Common fixtures for mock TunableGroups and Environment objects. """ from typing import Any, Dict import json5 as json import pytest from mlos_bench.tests import SEED from mlos_bench.environments.mock_env import MockEnv from mlos_bench.t...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,917
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/environments/composite_env.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Composite benchmark environment. """ import logging from datetime import datetime from types import TracebackType from typing import Any, Dict, List, Optional, Tuple, Type from typing_extensions import Literal from mlos_bench.services.b...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,918
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/environments/local/__init__.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Local Environments for mlos_bench. """ from mlos_bench.environments.local.local_env import LocalEnv from mlos_bench.environments.local.local_fileshare_env import LocalFileShareEnv __all__ = [ 'LocalEnv', 'LocalFileShareEnv', ]
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,919
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/config/schemas/__init__.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Common tests for config schemas and their validation and test cases. """ from copy import deepcopy from dataclasses import dataclass from typing import Any, Dict, Set import os import json5 import jsonschema import pytest from mlos_ben...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,920
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/services/types/__init__.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Service types for implementing declaring Service behavior for Environments to use in mlos_bench. """ from mlos_bench.services.types.config_loader_type import SupportsConfigLoading from mlos_bench.services.types.fileshare_type import Suppo...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,921
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/config/environments/apps/redis/scripts/local/process_redis_results.py
#!/usr/bin/env python3 # # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Script for post-processing redis-benchmark results. """ import argparse import pandas as pd def _main(input_file: str, output_file: str) -> None: """ Re-shape Redis benchmark CSV results from wide to long...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,922
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/config/cli/test_load_cli_config_examples.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Tests for loading storage config examples. """ from typing import List import logging import pytest from mlos_bench.tests.config import locate_config_examples from mlos_bench.config.schemas import ConfigSchema from mlos_bench.services...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,923
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/config/schemas/environments/test_environment_schemas.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Tests for environment schema validation. """ from os import path import pytest from mlos_core.tests import get_all_concrete_subclasses from mlos_bench.config.schemas import ConfigSchema from mlos_bench.environments.base_environment imp...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,924
microsoft/MLOS
refs/heads/main
/mlos_bench/_version.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Version number for the mlos_core package. """ # NOTE: This should be managed by bumpversion. _VERSION = '0.1.0'
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,925
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/tests/services/remote/azure/azure_fileshare_test.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ Tests for mlos_bench.services.remote.azure.azure_fileshare """ import os from unittest.mock import MagicMock, Mock, patch, call from mlos_bench.services.remote.azure.azure_fileshare import AzureFileShareService # pylint: disable=missing...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...
13,926
microsoft/MLOS
refs/heads/main
/mlos_bench/mlos_bench/services/remote/azure/azure_fileshare.py
# # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # """ A collection FileShare functions for interacting with Azure File Shares. """ import os import logging from typing import Any, Dict, Optional, Set from azure.storage.fileshare import ShareClient from azure.core.exceptions import Resource...
{"/mlos_bench/mlos_bench/tests/services/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/__init__.py", "/mlos_bench/mlos_bench/tests/services/remote/__init__.py"], "/mlos_bench/mlos_bench/tests/services/local/__init__.py": ["/mlos_bench/mlos_bench/tests/services/local/mock/__init__.py"], "/mlos_bench/mlos_be...