mirror of
https://github.com/Stone-Red-Code/dvc.git
synced 2026-11-01 23:08:43 +01:00
param: optimize fix for exponential memory allocation (#10180)
* param: simplify fix for exponential memory allocation * Apply suggestions from code review * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Remove `deepcopy` again * Restore deepcopy * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --------- Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
This commit is contained in:
co-authored by
pre-commit-ci[bot]
parent
abcd70b9cf
commit
72ab5a12df
@@ -57,8 +57,9 @@ def read_param_file(
|
||||
from copy import deepcopy
|
||||
|
||||
from dpath import merge
|
||||
from funcy import distinct
|
||||
|
||||
for key_path in key_paths:
|
||||
for key_path in distinct(key_paths):
|
||||
merge(
|
||||
ret,
|
||||
deepcopy(dpath.search(config, key_path, separator=".")),
|
||||
|
||||
Reference in New Issue
Block a user