<commit_before># ---------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# ---------------------------------------------------------

"""
Metadata to interact with different Azure clouds
"""

from azure.ai.ml.constants import AZUREML_CLOUD_ENV_NAME
import os
import logging

module_logger = logging.getLogger(__name__)


class AZURE_ENVIRONMENTS:
    ENV_DEFAULT = "AzureCloud"
    ENV_US_GOVERNMENT = "AzureUSGovernment"
    ENV_CHINA = "AzureChinaCloud"
    ENV_GERMAN = "AzureGermanCloud"
    ENV_USNAT = "USNat"
    ENV_USSEC = "USSec"


class ENDPOINT_URLS:  # pylint: disable=too-few-public-methods,old-style-class,no-init
    AZURE_PORTAL_ENDPOINT = "azure_portal"
    RESOURCE_MANAGER_ENDPOINT = "resource_manager"
    ACTIVE_DIRECTORY_ENDPOINT = "active_directory"
    AML_RESOURCE_ID = "aml_resource_id"
    STORAGE_ENDPOINT = "storage_endpoint"


_environments = {
    AZURE_ENVIRONMENTS.ENV_DEFAULT: {
        ENDPOINT_URLS.AZURE_PORTAL_ENDPOINT: "https://portal.azure.com/",
        ENDPOINT_URLS.RESOURCE_MANAGER_ENDPOINT: "https://management.azure.com/",
        ENDPOINT_URLS.ACTIVE_DIRECTORY_ENDPOINT: "https://login.microsoftonline.com/",
        ENDPOINT_URLS.AML_RESOURCE_ID: "https://ml.azure.com/",
        ENDPOINT_URLS.STORAGE_ENDPOINT: "core.windows.net",
    },
    AZURE_ENVIRONMENTS.ENV_CHINA: {
        ENDPOINT_URLS.AZURE_PORTAL_ENDPOINT: "https://portal.azure.cn/",
        ENDPOINT_URLS.RESOURCE_MANAGER_ENDPOINT: "https://management.chinacloudapi.cn/",
        ENDPOINT_URLS.ACTIVE_DIRECTORY_ENDPOINT: "https://login.chinacloudapi.cn/",
        ENDPOINT_URLS.AML_RESOURCE_ID: "https://ml.azure.cn/",
        ENDPOINT_URLS.STORAGE_ENDPOINT: ".core.chinacloudapi.cn",
    },
    AZURE_ENVIRONMENTS.ENV_US_GOVERNMENT: {
        ENDPOINT_URLS.AZURE_PORTAL_ENDPOINT: "https://portal.azure.us/",
        ENDPOINT_URLS.RESOURCE_MANAGER_ENDPOINT: "https://management.usgovcloudapi.net/",
        ENDPOINT_URLS.ACTIVE_DIRECTORY_ENDPOINT: "https://login.microsoftonline.us/",
        ENDPOINT_URLS.AML_RESOURCE_ID: "https://ml.azure.us/",
        ENDPOINT_URLS.STORAGE_ENDPOINT: "core.usgovcloudapi.net",
    },
    AZURE_ENVIRONMENTS.ENV_GERMAN: {
        ENDPOINT_URLS.AZURE_PORTAL_ENDPOINT: "https://portal.azure.de/",
        ENDPOINT_URLS.RESOURCE_MANAGER_ENDPOINT: "https://management.microsoftazure.de/",
        ENDPOINT_URLS.ACTIVE_DIRECTORY_ENDPOINT: "https://login.microsoftonline.de/",
        ENDPOINT_URLS.AML_RESOURCE_ID: "https://ml.azure.de",
        ENDPOINT_URLS.STORAGE_ENDPOINT: "core.cloudapi.de",<commit_msg>{machine learning} || Fix a bug in the code (#24922)<commit_after># ---------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# ---------------------------------------------------------

"""
Metadata to interact with different Azure clouds
"""

from azure.ai.ml.constants import AZUREML_CLOUD_ENV_NAME
import os
import logging

module_logger = logging.getLogger(__name__)


class AZURE_ENVIRONMENTS:
    ENV_DEFAULT = "AzureCloud"
    ENV_US_GOVERNMENT = "AzureUSGovernment"
    ENV_CHINA = "AzureChinaCloud"
    ENV_GERMAN = "AzureGermanCloud"
    ENV_USNAT = "USNat"
    ENV_USSEC = "USSec"


class ENDPOINT_URLS:  # pylint: disable=too-few-public-methods,old-style-class,no-init
    AZURE_PORTAL_ENDPOINT = "azure_portal"
    RESOURCE_MANAGER_ENDPOINT = "resource_manager"
    ACTIVE_DIRECTORY_ENDPOINT = "active_directory"
    AML_RESOURCE_ID = "aml_resource_id"
    STORAGE_ENDPOINT = "storage_endpoint"


_environments = {
    AZURE_ENVIRONMENTS.ENV_DEFAULT: {
        ENDPOINT_URLS.AZURE_PORTAL_ENDPOINT: "https://portal.azure.com/",
        ENDPOINT_URLS.RESOURCE_MANAGER_ENDPOINT: "https://management.azure.com/",
        ENDPOINT_URLS.ACTIVE_DIRECTORY_ENDPOINT: "https://login.microsoftonline.com/",
        ENDPOINT_URLS.AML_RESOURCE_ID: "https://ml.azure.com/",
        ENDPOINT_URLS.STORAGE_ENDPOINT: "core.windows.net",
    },
    AZURE_ENVIRONMENTS.ENV_CHINA: {
        ENDPOINT_URLS.AZURE_PORTAL_ENDPOINT: "https://portal.azure.cn/",
        ENDPOINT_URLS.RESOURCE_MANAGER_ENDPOINT: "https://management.chinacloudapi.cn/",
        ENDPOINT_URLS.ACTIVE_DIRECTORY_ENDPOINT: "https://login.chinacloudapi.cn/",
        ENDPOINT_URLS.AML_RESOURCE_ID: "https://ml.azure.cn/",
        ENDPOINT_URLS.STORAGE_ENDPOINT: "core.chinacloudapi.cn",
    },
    AZURE_ENVIRONMENTS.ENV_US_GOVERNMENT: {
        ENDPOINT_URLS.AZURE_PORTAL_ENDPOINT: "https://portal.azure.us/",
        ENDPOINT_URLS.RESOURCE_MANAGER_ENDPOINT: "https://management.usgovcloudapi.net/",
        ENDPOINT_URLS.ACTIVE_DIRECTORY_ENDPOINT: "https://login.microsoftonline.us/",
        ENDPOINT_URLS.AML_RESOURCE_ID: "https://ml.azure.us/",
        ENDPOINT_URLS.STORAGE_ENDPOINT: "core.usgovcloudapi.net",
    },
    AZURE_ENVIRONMENTS.ENV_GERMAN: {
        ENDPOINT_URLS.AZURE_PORTAL_ENDPOINT: "https://portal.azure.de/",
        ENDPOINT_URLS.RESOURCE_MANAGER_ENDPOINT: "https://management.microsoftazure.de/",
        ENDPOINT_URLS.ACTIVE_DIRECTORY_ENDPOINT: "https://login.microsoftonline.de/",
        ENDPOINT_URLS.AML_RESOURCE_ID: "https://ml.azure.de",
        ENDPOINT_URLS.STORAGE_ENDPOINT: "core.cloudapi.de",
{'fraction_non_alphanumeric': 0.1555977229601518, 'fraction_numerical': 0.0009487666034155598, 'mean_word_length': 3.324036095159967, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 32, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2763634', 'n_tokens_mistral': 1894, 'n_tokens_neox': 1812, 'n_words': 203}