mlflow.environment_variables

This module defines environment variables used in MLflow.

mlflow.environment_variables.MLFLOW_ALLOW_HTTP_REDIRECTS = 'MLFLOW_ALLOW_HTTP_REDIRECTS'

Specifies whether or not to allow the MLflow server to follow redirects when making HTTP requests. If set to False, the server will throw an exception if it encounters a redirect response. (default: True)

mlflow.environment_variables.MLFLOW_ARTIFACT_UPLOAD_DOWNLOAD_TIMEOUT = 'MLFLOW_ARTIFACT_UPLOAD_DOWNLOAD_TIMEOUT'

(Experimental, may be changed or removed) Specifies the timeout to use when uploading or downloading a file (default: None). If None, individual artifact stores will choose defaults.

mlflow.environment_variables.MLFLOW_AUTH_CONFIG_PATH = 'MLFLOW_AUTH_CONFIG_PATH'

Specified the path to the configuration file for MLflow Authentication. (default: None)

mlflow.environment_variables.MLFLOW_CONDA_CREATE_ENV_CMD = 'MLFLOW_CONDA_CREATE_ENV_CMD'

Specifies the name of the command to use when creating the environments. For example, let’s say we want to use mamba (https://github.com/mamba-org/mamba) instead of conda to create environments. Then: > conda install mamba -n base -c conda-forge If not set, use the same as conda_path (default: conda)

mlflow.environment_variables.MLFLOW_CONDA_HOME = 'MLFLOW_CONDA_HOME'

Specifies the conda home directory to use. (default: conda)

mlflow.environment_variables.MLFLOW_CONFIGURE_LOGGING = 'MLFLOW_LOGGING_CONFIGURE_LOGGING'

Specifies whether or not to have mlflow configure logging on import. If set to True, mlflow will configure mlflow.<module_name> loggers with logging handlers and formatters. (default: True)

mlflow.environment_variables.MLFLOW_DEFAULT_PREDICTION_DEVICE = 'MLFLOW_DEFAULT_PREDICTION_DEVICE'

Specifies the device intended for use in the predict function - can be used to override behavior where the GPU is used by default when available by setting this environment variable to be cpu. Currently, this variable is only supported for the MLflow PyTorch and HuggingFace flavors. For the HuggingFace flavor, note that device must be parseable as an integer.

mlflow.environment_variables.MLFLOW_DEPLOYMENTS_CONFIG = 'MLFLOW_DEPLOYMENTS_CONFIG'

Specifies the path of the config file for the MLflow Deployments server. (default: None)

mlflow.environment_variables.MLFLOW_DEPLOYMENTS_TARGET = 'MLFLOW_DEPLOYMENTS_TARGET'

(Experimental, may be changed or removed) Specifies the uri of a MLflow Deployments Server instance to be used with the Deployments Client APIs (default: None)

mlflow.environment_variables.MLFLOW_DEPLOYMENT_FLAVOR_NAME = 'MLFLOW_DEPLOYMENT_FLAVOR_NAME'

Specifies the flavor to serve in the scoring server. (default None)

mlflow.environment_variables.MLFLOW_DFS_TMP = 'MLFLOW_DFS_TMP'

Specifies the dfs_tmpdir parameter to use for mlflow.spark.save_model, mlflow.spark.log_model and mlflow.spark.load_model. See https://www.mlflow.org/docs/latest/python_api/mlflow.spark.html#mlflow.spark.save_model for more information. (default: /tmp/mlflow)

mlflow.environment_variables.MLFLOW_DISABLE_ENV_CREATION = 'MLFLOW_DISABLE_ENV_CREATION'

Specifies whether to disable creating a new conda environment for mlflow models build-docker. (default: False)

mlflow.environment_variables.MLFLOW_DISABLE_ENV_MANAGER_CONDA_WARNING = 'MLFLOW_DISABLE_ENV_MANAGER_CONDA_WARNING'

Specifies whether or not to print a warning when –env-manager=conda is specified. (default: False)

mlflow.environment_variables.MLFLOW_DOCKER_OPENJDK_VERSION = 'MLFLOW_DOCKER_OPENJDK_VERSION'

The OpenJDK version to install in the Docker image used for MLflow models. (default: 11)

mlflow.environment_variables.MLFLOW_DOWNLOAD_CHUNK_TIMEOUT = 'MLFLOW_DOWNLOAD_CHUNK_TIMEOUT'

Specifies the timeout value for downloading chunks of mlflow artifacts. (default: 300)

mlflow.environment_variables.MLFLOW_ENABLE_ARTIFACTS_PROGRESS_BAR = 'MLFLOW_ENABLE_ARTIFACTS_PROGRESS_BAR'

Specifies whether to display the progress bar when uploading/downloading artifacts. (default: True)

mlflow.environment_variables.MLFLOW_ENABLE_ASYNC_LOGGING = 'MLFLOW_ENABLE_ASYNC_LOGGING'

If True, MLflow fluent logging APIs, e.g., mlflow.log_metric will log asynchronously.

mlflow.environment_variables.MLFLOW_ENABLE_DBFS_FUSE_ARTIFACT_REPO = 'MLFLOW_ENABLE_DBFS_FUSE_ARTIFACT_REPO'

Specifies whether or not to use DBFS FUSE mount to store artifacts on Databricks (default: False)

mlflow.environment_variables.MLFLOW_ENABLE_PROXY_MULTIPART_UPLOAD = 'MLFLOW_ENABLE_PROXY_MULTIPART_UPLOAD'

Specifies whether or not to use multipart upload for proxied artifact access. (default: False)

mlflow.environment_variables.MLFLOW_ENABLE_SYSTEM_METRICS_LOGGING = 'MLFLOW_ENABLE_SYSTEM_METRICS_LOGGING'

Specifies if system metrics logging should be enabled.

mlflow.environment_variables.MLFLOW_ENV_ROOT = 'MLFLOW_ENV_ROOT'

Specifies the root directory to create Python virtual environments in. (default: ~/.mlflow/envs)

mlflow.environment_variables.MLFLOW_EXPERIMENT_ID = 'MLFLOW_EXPERIMENT_ID'

Specifies the default experiment ID to create run to. (default: None)

mlflow.environment_variables.MLFLOW_EXPERIMENT_NAME = 'MLFLOW_EXPERIMENT_NAME'

Specifies the default experiment name to create run to. (default: None)

mlflow.environment_variables.MLFLOW_GATEWAY_CONFIG = 'MLFLOW_GATEWAY_CONFIG'

Specifies the path of the config file for MLflow AI Gateway. (default: None)

mlflow.environment_variables.MLFLOW_GATEWAY_URI = 'MLFLOW_GATEWAY_URI'

(Experimental, may be changed or removed) Specifies the uri of a MLflow Gateway Server instance to be used with the Gateway Client APIs (default: None)

mlflow.environment_variables.MLFLOW_GCS_DEFAULT_TIMEOUT = 'MLFLOW_GCS_DEFAULT_TIMEOUT'

(Deprecated, please use MLFLOW_ARTIFACT_UPLOAD_DOWNLOAD_TIMEOUT) Specifies the default timeout to use when downloading/uploading a file from/to GCS (default: None). If None, google.cloud.storage.constants._DEFAULT_TIMEOUT is used.

mlflow.environment_variables.MLFLOW_GCS_DOWNLOAD_CHUNK_SIZE = 'MLFLOW_GCS_DOWNLOAD_CHUNK_SIZE'

Specifies the chunk size to use when downloading a file from GCS (default: None). If None, the chunk size is automatically determined by the google-cloud-storage package.

mlflow.environment_variables.MLFLOW_GCS_UPLOAD_CHUNK_SIZE = 'MLFLOW_GCS_UPLOAD_CHUNK_SIZE'

Specifies the chunk size to use when uploading a file to GCS. (default: None). If None, the chunk size is automatically determined by the google-cloud-storage package.

mlflow.environment_variables.MLFLOW_HTTP_REQUEST_BACKOFF_FACTOR = 'MLFLOW_HTTP_REQUEST_BACKOFF_FACTOR'

Specifies the backoff increase factor between MLflow HTTP request failures (default: 2)

mlflow.environment_variables.MLFLOW_HTTP_REQUEST_BACKOFF_JITTER = 'MLFLOW_HTTP_REQUEST_BACKOFF_JITTER'

Specifies the backoff jitter between MLflow HTTP request failures (default: 1.0)

mlflow.environment_variables.MLFLOW_HTTP_REQUEST_MAX_RETRIES = 'MLFLOW_HTTP_REQUEST_MAX_RETRIES'

Specifies the maximum number of retries for MLflow HTTP requests (default: 5)

mlflow.environment_variables.MLFLOW_HTTP_REQUEST_TIMEOUT = 'MLFLOW_HTTP_REQUEST_TIMEOUT'

Specifies the timeout in seconds for MLflow HTTP requests (default: 120)

mlflow.environment_variables.MLFLOW_HUGGINGFACE_DEVICE_MAP_STRATEGY = 'MLFLOW_HUGGINGFACE_DEVICE_MAP_STRATEGY'

Specifies to Huggingface to use the automatic device placement logic of HuggingFace accelerate. This can be set to values supported by the version of HuggingFace Accelerate being installed.

mlflow.environment_variables.MLFLOW_HUGGINGFACE_MODEL_MAX_SHARD_SIZE = 'MLFLOW_HUGGINGFACE_MODEL_MAX_SHARD_SIZE'

Specifies the max_shard_size to use when mlflow transformers flavor saves the model checkpoint. This can be set to override the 500MB default.

mlflow.environment_variables.MLFLOW_HUGGINGFACE_USE_LOW_CPU_MEM_USAGE = 'MLFLOW_HUGGINGFACE_USE_LOW_CPU_MEM_USAGE'

Specifies to Huggingface to use the low_cpu_mem_usage flag powered by HuggingFace accelerate. If it’s set to false, the low_cpu_mem_usage flag will be set to False.

mlflow.environment_variables.MLFLOW_INPUT_EXAMPLE_INFERENCE_TIMEOUT = 'MLFLOW_INPUT_EXAMPLE_INFERENCE_TIMEOUT'

Specifies the timeout for model inference with input example(s) when logging/saving a model. MLflow runs a few inference requests against the model to infer model signature and pip requirements. Sometimes the prediction hangs for a long time, especially for a large model. This timeout limits the allowable time for performing a prediction for signature inference and will abort the prediction, falling back to the default signature and pip requirements.

mlflow.environment_variables.MLFLOW_KERBEROS_TICKET_CACHE = 'MLFLOW_KERBEROS_TICKET_CACHE'

Specifies the location of a Kerberos ticket cache to use for HDFS artifact operations. (default: None)

mlflow.environment_variables.MLFLOW_KERBEROS_USER = 'MLFLOW_KERBEROS_USER'

Specifies a Kerberos user for HDFS artifact operations. (default: None)

mlflow.environment_variables.MLFLOW_MULTIPART_DOWNLOAD_CHUNK_SIZE = 'MLFLOW_MULTIPART_DOWNLOAD_CHUNK_SIZE'

Specifies the chunk size in bytes to use when performing multipart download (default: 104_857_600 (100 MB))

mlflow.environment_variables.MLFLOW_MULTIPART_UPLOAD_CHUNK_SIZE = 'MLFLOW_MULTIPART_UPLOAD_CHUNK_SIZE'

Specifies the chunk size in bytes to use when performing multipart upload (default: 104_857_60 (10 MB))

mlflow.environment_variables.MLFLOW_MULTIPART_UPLOAD_MINIMUM_FILE_SIZE = 'MLFLOW_MULTIPART_UPLOAD_MINIMUM_FILE_SIZE'

Specifies the minimum file size in bytes to use multipart upload when logging artifacts (default: 524_288_000 (500 MB))

mlflow.environment_variables.MLFLOW_OPENAI_SECRET_SCOPE = 'MLFLOW_OPENAI_SECRET_SCOPE'

Specifies the name of the Databricks secret scope to use for storing OpenAI API keys.

mlflow.environment_variables.MLFLOW_PYARROW_EXTRA_CONF = 'MLFLOW_PYARROW_EXTRA_CONF'

Specifies extra pyarrow configurations for HDFS artifact operations. (default: None)

mlflow.environment_variables.MLFLOW_RECIPES_EXECUTION_DIRECTORY = 'MLFLOW_RECIPES_EXECUTION_DIRECTORY'

Specifies the execution directory for recipes. (default: None)

mlflow.environment_variables.MLFLOW_RECIPES_EXECUTION_TARGET_STEP_NAME = 'MLFLOW_RECIPES_EXECUTION_TARGET_STEP_NAME'

Specifies the target step to execute for recipes. (default: None)

mlflow.environment_variables.MLFLOW_RECIPES_PROFILE = 'MLFLOW_RECIPES_PROFILE'

Specifies the profile to use for recipes. (default: None)

mlflow.environment_variables.MLFLOW_REGISTRY_DIR = 'MLFLOW_REGISTRY_DIR'

Specifies the default root directory for registry FileStore. (default: None)

mlflow.environment_variables.MLFLOW_REGISTRY_URI = 'MLFLOW_REGISTRY_URI'

Specifies the registry URI. (default: None)

mlflow.environment_variables.MLFLOW_REQUIREMENTS_INFERENCE_TIMEOUT = 'MLFLOW_REQUIREMENTS_INFERENCE_TIMEOUT'

Specifies the timeout_seconds for MLflow Model dependency inference operations. (default: 120)

mlflow.environment_variables.MLFLOW_RUN_CONTEXT = 'MLFLOW_RUN_CONTEXT'

Specifies the MLflow Run context (default: None)

mlflow.environment_variables.MLFLOW_RUN_ID = 'MLFLOW_RUN_ID'

Specified the ID of the run to log data to. (default: None)

mlflow.environment_variables.MLFLOW_S3_ENDPOINT_URL = 'MLFLOW_S3_ENDPOINT_URL'

Specifies the S3 endpoint URL to use for S3 artifact operations. (default: None)

mlflow.environment_variables.MLFLOW_S3_IGNORE_TLS = 'MLFLOW_S3_IGNORE_TLS'

Specifies whether or not to skip TLS certificate verification for S3 artifact operations. (default: False)

mlflow.environment_variables.MLFLOW_S3_UPLOAD_EXTRA_ARGS = 'MLFLOW_S3_UPLOAD_EXTRA_ARGS'

Specifies extra arguments for S3 artifact uploads. (default: None)

mlflow.environment_variables.MLFLOW_SCORING_SERVER_REQUEST_TIMEOUT = 'MLFLOW_SCORING_SERVER_REQUEST_TIMEOUT'

Specifies the MLflow Model Scoring server request timeout in seconds (default: 60)

mlflow.environment_variables.MLFLOW_SQLALCHEMYSTORE_ECHO = 'MLFLOW_SQLALCHEMYSTORE_ECHO'

Specifies the echo parameter to use for sqlalchemy.create_engine in the SQLAlchemy tracking store. See https://docs.sqlalchemy.org/en/14/core/engines.html#sqlalchemy.create_engine.params.echo for more information. (default: False)

mlflow.environment_variables.MLFLOW_SQLALCHEMYSTORE_MAX_OVERFLOW = 'MLFLOW_SQLALCHEMYSTORE_MAX_OVERFLOW'

Specifies the max_overflow parameter to use for sqlalchemy.create_engine in the SQLAlchemy tracking store. See https://docs.sqlalchemy.org/en/14/core/engines.html#sqlalchemy.create_engine.params.max_overflow for more information. (default: None)

mlflow.environment_variables.MLFLOW_SQLALCHEMYSTORE_POOLCLASS = 'MLFLOW_SQLALCHEMYSTORE_POOLCLASS'

Specifies the poolclass parameter to use for sqlalchemy.create_engine in the SQLAlchemy tracking store. See https://docs.sqlalchemy.org/en/14/core/engines.html#sqlalchemy.create_engine.params.poolclass for more information. (default: None)

mlflow.environment_variables.MLFLOW_SQLALCHEMYSTORE_POOL_RECYCLE = 'MLFLOW_SQLALCHEMYSTORE_POOL_RECYCLE'

Specifies the pool_recycle parameter to use for sqlalchemy.create_engine in the SQLAlchemy tracking store. See https://docs.sqlalchemy.org/en/14/core/engines.html#sqlalchemy.create_engine.params.pool_recycle for more information. (default: None)

mlflow.environment_variables.MLFLOW_SQLALCHEMYSTORE_POOL_SIZE = 'MLFLOW_SQLALCHEMYSTORE_POOL_SIZE'

Specifies the pool_size parameter to use for sqlalchemy.create_engine in the SQLAlchemy tracking store. See https://docs.sqlalchemy.org/en/14/core/engines.html#sqlalchemy.create_engine.params.pool_size for more information. (default: None)

mlflow.environment_variables.MLFLOW_SYSTEM_METRICS_NODE_ID = 'MLFLOW_SYSTEM_METRICS_NODE_ID'

Specifies the node id of system metrics logging. This is useful in multi-node (distributed training) setup.

mlflow.environment_variables.MLFLOW_SYSTEM_METRICS_SAMPLES_BEFORE_LOGGING = 'MLFLOW_SYSTEM_METRICS_SAMPLES_BEFORE_LOGGING'

Specifies the number of samples before logging system metrics.

mlflow.environment_variables.MLFLOW_SYSTEM_METRICS_SAMPLING_INTERVAL = 'MLFLOW_SYSTEM_METRICS_SAMPLING_INTERVAL'

Specifies the sampling interval for system metrics logging.

mlflow.environment_variables.MLFLOW_TRACKING_AUTH = 'MLFLOW_TRACKING_AUTH'

Specifies the auth provider to sign the MLflow HTTP request (default: None). When set, it will overwrite the “Authorization” HTTP header.

mlflow.environment_variables.MLFLOW_TRACKING_AWS_SIGV4 = 'MLFLOW_TRACKING_AWS_SIGV4'

Specifies whether MLflow HTTP requests should be signed using AWS signature V4. It will overwrite (default: False). When set, it will overwrite the “Authorization” HTTP header. See https://docs.aws.amazon.com/general/latest/gr/signature-version-4.html for more information.

mlflow.environment_variables.MLFLOW_TRACKING_CLIENT_CERT_PATH = 'MLFLOW_TRACKING_CLIENT_CERT_PATH'

Sets the cert param in requests.request function, see https://requests.readthedocs.io/en/master/api/ (default: None)

mlflow.environment_variables.MLFLOW_TRACKING_DIR = 'MLFLOW_TRACKING_DIR'

Specifies the default root directory for tracking FileStore. (default: None)

mlflow.environment_variables.MLFLOW_TRACKING_INSECURE_TLS = 'MLFLOW_TRACKING_INSECURE_TLS'

Specifies whether to verify TLS connection in requests.request function, see https://requests.readthedocs.io/en/master/api/ (default: False).

mlflow.environment_variables.MLFLOW_TRACKING_PASSWORD = 'MLFLOW_TRACKING_PASSWORD'

Specifies the password used to authenticate with a tracking server. (default: None)

mlflow.environment_variables.MLFLOW_TRACKING_SERVER_CERT_PATH = 'MLFLOW_TRACKING_SERVER_CERT_PATH'

Sets the verify param in requests.request function, see https://requests.readthedocs.io/en/master/api/ (default: None)

mlflow.environment_variables.MLFLOW_TRACKING_TOKEN = 'MLFLOW_TRACKING_TOKEN'

Specifies and takes precedence for setting the basic/bearer auth on http requests. (default: None)

mlflow.environment_variables.MLFLOW_TRACKING_URI = 'MLFLOW_TRACKING_URI'

Specifies the tracking URI. (default: None)

mlflow.environment_variables.MLFLOW_TRACKING_USERNAME = 'MLFLOW_TRACKING_USERNAME'

Specifies the username used to authenticate with a tracking server. (default: None)

mlflow.environment_variables.MLFLOW_TRUNCATE_LONG_VALUES = 'MLFLOW_TRUNCATE_LONG_VALUES'

If set to True, the following entities will be truncated to their maximum length: - Param value - Tag value If set to False, an exception will be raised if the length of the entity exceeds the maximum length. (default: True)

mlflow.environment_variables.MLFLOW_WHEELED_MODEL_PIP_DOWNLOAD_OPTIONS = 'MLFLOW_WHEELED_MODEL_PIP_DOWNLOAD_OPTIONS'

(Experimental, may be changed or removed) Specifies the download options to be used by pip wheel when add_libraries_to_model is used to create and log model dependencies as model artifacts. The default behavior only uses dependency binaries and no source packages. (default: --only-binary=:all:).