mirror of
https://github.com/3b1b/manim.git
synced 2025-08-05 16:49:03 +00:00
Added description of merge_config
This commit is contained in:
parent
a5d9d9e28d
commit
dde76eddb1
1 changed files with 7 additions and 0 deletions
|
@ -57,6 +57,13 @@ def digest_config(obj, kwargs, caller_locals={}):
|
|||
|
||||
|
||||
def merge_config(all_dicts):
|
||||
"""
|
||||
Creates a dict whose keyset is the union of all the
|
||||
input dictionaries. The value for each key is based
|
||||
on the first dict in the list with that key.
|
||||
|
||||
When values are dictionaries, it is applied recursively
|
||||
"""
|
||||
all_config = reduce(op.add, [list(d.items()) for d in all_dicts])
|
||||
config = dict()
|
||||
for c in all_config:
|
||||
|
|
Loading…
Add table
Reference in a new issue