File size: 755 Bytes
6b70263
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
import yaml

def generate_nutrient_yaml(output_path="nutrients.yaml"):
    nutrients = {
        "veg": {
            "1": {"Nitrogen": 0.2, "Phosphorus": 0.1, "Potassium": 0.2},
            "2": {"Nitrogen": 0.25, "Phosphorus": 0.15, "Potassium": 0.25},
        },
        "flower": {
            "1": {"Nitrogen": 0.15, "Phosphorus": 0.25, "Potassium": 0.35},
        },
    }
    with open(output_path, "w") as file:
        yaml.dump(nutrients, file)

def generate_remedies_yaml(output_path="remedies.yaml"):
    remedies = {
        "nitrogen_deficiency": {"Nitrogen": 0.5},
    }
    with open(output_path, "w") as file:
        yaml.dump(remedies, file)

generate_nutrient_yaml("nutrients.yaml")
generate_remedies_yaml("remedies.yaml")