(yTrue, yPred)
| 42 | |
| 43 | // TODO(cais): Use tf.metrics.falsePositiveRate when available. |
| 44 | function falsePositiveRate(yTrue, yPred) { |
| 45 | return tf.tidy(() => { |
| 46 | const fp = falsePositives(yTrue, yPred); |
| 47 | const tn = trueNegatives(yTrue, yPred); |
| 48 | return fp.div(fp.add(tn)); |
| 49 | }); |
| 50 | } |
| 51 | |
| 52 | /** |
| 53 | * Draw a ROC curve. |
no test coverage detected