Skip to content

Commit 2bd63c4

Browse files
committed
Update README.md
1 parent 9ba3553 commit 2bd63c4

File tree

1 file changed

+14
-1
lines changed

1 file changed

+14
-1
lines changed

README.md

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -222,7 +222,7 @@ There are three other ways to define custom settings/hyperparameters:
222222
223223
config = Config(config='path_to_a_config.yaml')
224224
```
225-
3. You can pass a nested dictionary defining configuration settings to `expfig.Config`.
225+
3. You can pass a nested or period-deliminated dictionary defining configuration settings to `expfig.Config`.
226226
For example:
227227
```python
228228
from expfig import Config
@@ -234,6 +234,19 @@ There are three other ways to define custom settings/hyperparameters:
234234
}
235235
config = Config(config_dict)
236236
```
237+
or
238+
```python
239+
from expfig import Config
240+
241+
config_dict = {
242+
'microgrid.config.scenario': 1,
243+
'algo.sampler.type': 'local',
244+
'algo.sampler.n_workers': 4,
245+
'context.verbose': True
246+
}
247+
config = Config(config_dict)
248+
```
249+
Both of the above methods result is identical `Config`s.
237250

238251
## Hyperparameter Resolution Order
239252

0 commit comments

Comments
 (0)