The ML.RECONSTRUCTION_LOSS function

This document describes the ML.RECONSTRUCTION_LOSS function, which you can use to compute the reconstruction losses between the input and output data of an autoencoder model.

Syntax

ML.RECONSTRUCTION_LOSS(
  MODEL `project_id.dataset.model`,
  { TABLE `project_id.dataset.table_name` | (query_statement) }
)

Arguments

ML.RECONSTRUCTION_LOSS takes the following arguments:

Output

ML.RECONSTRUCTION_LOSS returns the following columns:

Limitations

ML.RECONSTRUCTION_LOSS doesn't support imported TensorFlow models.

Example

The following query computes reconstruction losses for the model mydataset.mymodel in your default project:

SELECT *
FROM ML.RECONSTRUCTION_LOSS(
  MODEL `mydataset.mymodel`,
  (SELECT column1,
          column2,
          column3,
          column4
   FROM `mydataset.mytable`)
)

What's next