load_language(self.languages[lang].path) await self.session.commit() await self.session.close() async def load_language(self, lang: Path) -> None: for plugin in lang.iterdir(): if not plugin.name.endswith(".yaml"): continue async with aiofiles.open(plugin, encoding="utf-8") as f:...
2 changes: 1 addition & 1 deletion 2 docs/conda-recipe.yaml Show comments View file Edit file Delete file This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode...
model.solutions.store_to(results)#results.write(filename=currdir+'solve_with_store2.out', format='yaml') self.assertMatchesYamlBaseline(currdir+"solve_with_store2.out", currdir+"solve_with_store2.txt")## Load results with string indices#tmodel = ConcreteModel() tmodel.A = RangeSet(1,4...
# 需要导入模块: from oslo_config import cfg [as 别名]# 或者: from oslo_config.cfg importNoSuchOptError[as 别名]defset_user_creds(cls, config):# normal user creds# Fixme(eliqiao): this is quick workaround to passing tempest# legacy credentials provider is removed by tempest# I8c24cd17f...
gitlab_rails['ldap_servers'] = YAML.load <<-'EOS' main: # 'main' is the GitLab 'provider ID' of this LDAP server label: 'LDAP' host: '_your_ldap_server' port: 389 uid: 'sAMAccountName' bind_dn: '_the_full_dn_of_the_user_you_will_bind_with' ...
1️⃣ Description yamlfix does not respect the following config file, while yamllint does. Executing both like '<yamllint|yamlfix> -c .yamllint.yaml .' # .yamllint.yaml --- yaml-files: - '*.yaml' - '*.yml' # .gitignore style # chart dirs c...
fromfedtorch.nodesimportClientclient=Client(args,dist.get_rank())# Initialize the nodeclient.initialize()# Initialize the dataset if not downloadedclient.initialize_dataset()# Load the datasetclient.load_local_dataset()# Generate auxiliary models and params for trainingclient.gen_aux_models() ...
trigger_payload_schema = yaml.safe_load(fd) triggers = list(trigger_payload_schema.keys()) print('Triggers=%s'% triggers) rate = cfg.CONF.rate rate_per_trigger = int(rate / len(triggers)) duration = cfg.CONF.duration max_throughput = cfg.CONF.max_throughputifmax_throughput: ...
Hyperopt is a Python library for serial and parallel optimization over awkward search spaces, which may include real-valued, discrete, and conditional dimensions.Getting startedInstall hyperopt from PyPIpip install hyperoptto run your first example# define an objective function def objective(args): ...
7 changes: 3 additions & 4 deletions 7 .pre-commit-config.yaml Original file line numberDiff line numberDiff line change @@ -1,11 +1,10 @@ repos: - repo: https://github.com/ambv/black rev: stable - repo: https://github.com/psf/black rev: 23.1.0 hooks: - id: black args: ...