BinaryConfusionMatrix.fromJson constructor

BinaryConfusionMatrix.fromJson(
  1. Map json_
)

Implementation

BinaryConfusionMatrix.fromJson(core.Map json_)
    : this(
        accuracy: json_.containsKey('accuracy')
            ? (json_['accuracy'] as core.num).toDouble()
            : null,
        f1Score: json_.containsKey('f1Score')
            ? (json_['f1Score'] as core.num).toDouble()
            : null,
        falseNegatives: json_.containsKey('falseNegatives')
            ? json_['falseNegatives'] as core.String
            : null,
        falsePositives: json_.containsKey('falsePositives')
            ? json_['falsePositives'] as core.String
            : null,
        positiveClassThreshold: json_.containsKey('positiveClassThreshold')
            ? (json_['positiveClassThreshold'] as core.num).toDouble()
            : null,
        precision: json_.containsKey('precision')
            ? (json_['precision'] as core.num).toDouble()
            : null,
        recall: json_.containsKey('recall')
            ? (json_['recall'] as core.num).toDouble()
            : null,
        trueNegatives: json_.containsKey('trueNegatives')
            ? json_['trueNegatives'] as core.String
            : null,
        truePositives: json_.containsKey('truePositives')
            ? json_['truePositives'] as core.String
            : null,
      );