Hello, I want to know about the result 0.9333333333333 is good or bad in this flow node-red? You can find the flow chart in here : node-red-contrib-machine-learning (node) - Node-RED (nodered.org).
And here is my assessment python code --
import sklearn.metrics as m
import json
import sys
import numpy
from inspect import getfullargspec
#import inspect
#read configurations
config = json.loads(input())
while True:
#read request
data = json.loads(input())
get_score = getattr(m, config['score'])
kwargs = {}
if 'average' in getfullargspec(get_score).args:
kwargs['average'] = 'micro'
if 'beta' in getfullargspec(get_score).args:
kwargs['beta'] = 1
score = get_score(data['real'], data['predicted'], **kwargs)
if type(score) is numpy.ndarray:
score = json.dumps(score.tolist())
print(score)