Mercurial > repos > ufz > dfpl_train
view json_predict.py @ 0:e0bb949eac45 draft default tip
planemo upload for repository https://github.com/Helmholtz-UFZ/galaxy-tools/tree/main/tools/dfpl commit 66c6acfeff5441c36fba97787ddc5ee3d6a4a6ec
author | ufz |
---|---|
date | Thu, 19 Dec 2024 12:51:21 +0000 |
parents | |
children |
line wrap: on
line source
import json from sys import stdin d = json.load(stdin) # The directory where the full model of the fnn is loaded from. d["fnnModelDir"] = "" # 'dfpl predict' looks for "model_weights.h5" in this directory del d["fnn_weights"] d["compressFeatures"] = bool(d["compressFeatures"] == "true") # The encoder file where it is loaded from, to compress the fingerprints. d["ecModelDir"] = "" d["ecWeightsFile"] = "encoder_weights.h5" # Output csv file name which will contain one prediction per input line. # Default: prefix of input file name. d["outputFile"] = "predictions.csv" d["py/object"] = "dfpl.options.Options" print(json.dumps(d))