YAML test
This commit is contained in:
parent
c90ee468b2
commit
9e9dbb440e
87
Notebooks/YAML Serialization.ipynb
Normal file
87
Notebooks/YAML Serialization.ipynb
Normal file
@ -0,0 +1,87 @@
|
||||
{
|
||||
"cells": [
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"import yaml"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"with open('../test.yml') as f:\n",
|
||||
" expe = yaml.safe_load(f)\n",
|
||||
"expe"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"sha1"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"import hashlib"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"hashlib.md5()"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"sorted(expe.items())"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": []
|
||||
}
|
||||
],
|
||||
"metadata": {
|
||||
"kernelspec": {
|
||||
"display_name": "Python 3",
|
||||
"language": "python",
|
||||
"name": "python3"
|
||||
},
|
||||
"language_info": {
|
||||
"codemirror_mode": {
|
||||
"name": "ipython",
|
||||
"version": 3
|
||||
},
|
||||
"file_extension": ".py",
|
||||
"mimetype": "text/x-python",
|
||||
"name": "python",
|
||||
"nbconvert_exporter": "python",
|
||||
"pygments_lexer": "ipython3"
|
||||
}
|
||||
},
|
||||
"nbformat": 4,
|
||||
"nbformat_minor": 2
|
||||
}
|
18
test.yml
Normal file
18
test.yml
Normal file
@ -0,0 +1,18 @@
|
||||
expe:
|
||||
name: Première expérience
|
||||
date: 9 juillet 2018
|
||||
rasters:
|
||||
- './Data/phase1_rasters/DEM+B_C123/UH17_GEM051_TR.tif'
|
||||
- './Data/phase1_rasters/DEM_C123_3msr/UH17_GEG051_TR.tif'
|
||||
descriptors:
|
||||
type: Attribute Profiles
|
||||
areas:
|
||||
- 10
|
||||
- 100
|
||||
- 1000
|
||||
moi: [.5, .7, .9]
|
||||
classifier:
|
||||
name: Random Forest
|
||||
cvsplit: 5
|
||||
hash: 000
|
||||
|
Loading…
Reference in New Issue
Block a user