()
| 41 | * A runner that does a basic precision test. |
| 42 | */ |
| 43 | export async function precisionTestRunner() { |
| 44 | return async () => { |
| 45 | const res = tf.tidy(() => tf.scalar(2.4).square()); |
| 46 | const data = (await res.data())[0]; |
| 47 | return JSON.stringify(data); |
| 48 | }; |
| 49 | } |
| 50 | |
| 51 | /** |
| 52 | * A runner that does a mobilenet prediction |