Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[IOTDB-5728] Implement config parser & model/dataset factory on MLNode #9458

Merged
merged 21 commits into from
Mar 31, 2023
Merged

[IOTDB-5728] Implement config parser & model/dataset factory on MLNode #9458

merged 21 commits into from
Mar 31, 2023

Conversation

lichenyu20
Copy link
Contributor

Implement mlnode parser

parse training request of type TCreateTrainingTaskReq
Usage:

    modelId = 'mid_etth1_dlinear_default'
    isAuto = False
    modelConfigs = {
        'task_class': 'forecast_training_task',
        'source_type': 'thrift',
        'dataset_type': 'window',
        'time_embed': 'h',
        'input_len': 96,
        'pred_len': 96,
        'model_name': 'dlinear',
        'input_vars': 7,
        'output_vars': 7,
        'task_type': 'm',
        'kernel_size': 25,
        'learning_rate': 1e-3,
        'batch_size': 32,
        'num_workers': 0,
        'epochs': 10,
        'metric_names': ['MSE', 'MAE']
    }
    queryExpressions = ['root.eg.etth1.**', 'root.eg.etth1.**', 'root.eg.etth1.**']
    queryFilter = '0,1501516800000'
    req = TCreateTrainingTaskReq(
        modelId=str(modelId),
        isAuto=isAuto,
        modelConfigs={k: str(v) for k, v in modelConfigs.items()},
        queryExpressions=[str(query) for query in queryExpressions],
        queryFilter=str(queryFilter),
    )
    data_conf, model_conf, task_conf = parse_training_request(req)

mlnode/iotdb/mlnode/parser.py Outdated Show resolved Hide resolved
mlnode/test/test_parse_training_request.py Outdated Show resolved Hide resolved
@liuminghui233 liuminghui233 changed the title [IOTDB-5728] Implement mlnode parser [IOTDB-5728] Implement config parser & model/dataset factory on MLNode Mar 31, 2023
@liuminghui233 liuminghui233 merged commit 0750fa6 into apache:master Mar 31, 2023
SteveYurongSu added a commit to MiniSho/iotdb that referenced this pull request Mar 31, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants