tensorflow/core/tpu/tpu_embedding_configuration_proto_rewrite.cc
// Validates that the batch_size_per_tensor_core and
// TableDescriptor.num_features fields have been populated correctly in the TPU
// embedding configuration.
Validates that the batch_size_per_tensor_core and
TableDescriptor.num_features fields have been populated correctly in the TPU
embedding configuration.
Validates that the batch_size_per_tensor_core and TableDescriptor . num_features fields have been populated correctly in the TPU embedding configuration .
Status ValidateBatchSizeAndFeatureCounts(
    const tpu::TPUEmbeddingConfiguration& config) {
  if (config.batch_size_per_tensor_core() <= 0) {
    return errors::InvalidArgument(absl::StrFormat(
        "Invalid batch_size_per_tensor_core: %d found in the TPU embedding "
        "configuration. Valid values are >0.",
        config.batch_size_per_tensor_core()));
  }
  for (const auto& table_config : config.table_descriptor()) {
    if (table_config.num_features() <= 0) {
      return errors::InvalidArgument(absl::StrFormat(
          "Invalid num_features: %d found for table: %s in the TPU embedding "
          "configuration. Valid values are >0.",
          table_config.num_features(), table_config.name()));
    }
  }  
  return Status::OK();
}
Status ValidateBatchSizeAndFeatureCounts ( const tpu :: TPUEmbeddingConfiguration & config ) { if ( config . batch_size_per_tensor_core ( ) <= 0 ) { return errors :: InvalidArgument ( absl :: StrFormat ( " " " " , config . batch_size_per_tensor_core ( ) ) ) ; } for ( const auto & table_config : config . table_descriptor ( ) ) { if ( table_config . num_features ( ) <= 0 ) { return errors :: InvalidArgument ( absl :: StrFormat ( " " " " , table_config . num_features ( ) , table_config . name ( ) ) ) ; } } return Status :: OK ( ) ; }
Validates that the batch_size_per_tensor_core and
TableDescriptor.num_features fields have been populated correctly in the TPU
embedding configuration.
Validates that the batch_size_per_tensor_core and TableDescriptor . num_features fields have been populated correctly in the TPU embedding configuration .
// table_config