File size: 478 Bytes
fd82a77
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
import json
import Path
from pathlib import Path

class ModelConfig:
    def __init__(self, json_file_path: str):
        self.json_file_path = json_file_path

    @classmethod
    def from_json_file(cls, json_file_path: str):
        with open(json_file_path, "r") as file:
            config_data = json.load(file)
        return cls(json_file_path)

    def get_hyperparameters(self):
        # implement your logic to retrieve hyperparameters from the JSON file
        pass