Class Evaluation.Metrics.Builder

java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessage.Builder<Evaluation.Metrics.Builder>
com.google.cloud.documentai.v1.Evaluation.Metrics.Builder
All Implemented Interfaces:
Evaluation.MetricsOrBuilder, com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Cloneable
Enclosing class:
Evaluation.Metrics

public static final class Evaluation.Metrics.Builder extends com.google.protobuf.GeneratedMessage.Builder<Evaluation.Metrics.Builder> implements Evaluation.MetricsOrBuilder
 Evaluation metrics, either in aggregate or about a specific entity.
 
Protobuf type google.cloud.documentai.v1.Evaluation.Metrics
  • Method Details

    • getDescriptor

      public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
    • internalGetFieldAccessorTable

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
      Specified by:
      internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessage.Builder<Evaluation.Metrics.Builder>
    • clear

      Specified by:
      clear in interface com.google.protobuf.Message.Builder
      Specified by:
      clear in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      clear in class com.google.protobuf.GeneratedMessage.Builder<Evaluation.Metrics.Builder>
    • getDescriptorForType

      public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
      Specified by:
      getDescriptorForType in interface com.google.protobuf.Message.Builder
      Specified by:
      getDescriptorForType in interface com.google.protobuf.MessageOrBuilder
      Overrides:
      getDescriptorForType in class com.google.protobuf.GeneratedMessage.Builder<Evaluation.Metrics.Builder>
    • getDefaultInstanceForType

      public Evaluation.Metrics getDefaultInstanceForType()
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder
    • build

      public Evaluation.Metrics build()
      Specified by:
      build in interface com.google.protobuf.Message.Builder
      Specified by:
      build in interface com.google.protobuf.MessageLite.Builder
    • buildPartial

      public Evaluation.Metrics buildPartial()
      Specified by:
      buildPartial in interface com.google.protobuf.Message.Builder
      Specified by:
      buildPartial in interface com.google.protobuf.MessageLite.Builder
    • mergeFrom

      public Evaluation.Metrics.Builder mergeFrom(com.google.protobuf.Message other)
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<Evaluation.Metrics.Builder>
    • mergeFrom

    • isInitialized

      public final boolean isInitialized()
      Specified by:
      isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
      Overrides:
      isInitialized in class com.google.protobuf.GeneratedMessage.Builder<Evaluation.Metrics.Builder>
    • mergeFrom

      public Evaluation.Metrics.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Specified by:
      mergeFrom in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<Evaluation.Metrics.Builder>
      Throws:
      IOException
    • getPrecision

      public float getPrecision()
       The calculated precision.
       
      float precision = 1;
      Specified by:
      getPrecision in interface Evaluation.MetricsOrBuilder
      Returns:
      The precision.
    • setPrecision

      public Evaluation.Metrics.Builder setPrecision(float value)
       The calculated precision.
       
      float precision = 1;
      Parameters:
      value - The precision to set.
      Returns:
      This builder for chaining.
    • clearPrecision

      public Evaluation.Metrics.Builder clearPrecision()
       The calculated precision.
       
      float precision = 1;
      Returns:
      This builder for chaining.
    • getRecall

      public float getRecall()
       The calculated recall.
       
      float recall = 2;
      Specified by:
      getRecall in interface Evaluation.MetricsOrBuilder
      Returns:
      The recall.
    • setRecall

      public Evaluation.Metrics.Builder setRecall(float value)
       The calculated recall.
       
      float recall = 2;
      Parameters:
      value - The recall to set.
      Returns:
      This builder for chaining.
    • clearRecall

      public Evaluation.Metrics.Builder clearRecall()
       The calculated recall.
       
      float recall = 2;
      Returns:
      This builder for chaining.
    • getF1Score

      public float getF1Score()
       The calculated f1 score.
       
      float f1_score = 3;
      Specified by:
      getF1Score in interface Evaluation.MetricsOrBuilder
      Returns:
      The f1Score.
    • setF1Score

      public Evaluation.Metrics.Builder setF1Score(float value)
       The calculated f1 score.
       
      float f1_score = 3;
      Parameters:
      value - The f1Score to set.
      Returns:
      This builder for chaining.
    • clearF1Score

      public Evaluation.Metrics.Builder clearF1Score()
       The calculated f1 score.
       
      float f1_score = 3;
      Returns:
      This builder for chaining.
    • getPredictedOccurrencesCount

      public int getPredictedOccurrencesCount()
       The amount of occurrences in predicted documents.
       
      int32 predicted_occurrences_count = 4;
      Specified by:
      getPredictedOccurrencesCount in interface Evaluation.MetricsOrBuilder
      Returns:
      The predictedOccurrencesCount.
    • setPredictedOccurrencesCount

      public Evaluation.Metrics.Builder setPredictedOccurrencesCount(int value)
       The amount of occurrences in predicted documents.
       
      int32 predicted_occurrences_count = 4;
      Parameters:
      value - The predictedOccurrencesCount to set.
      Returns:
      This builder for chaining.
    • clearPredictedOccurrencesCount

      public Evaluation.Metrics.Builder clearPredictedOccurrencesCount()
       The amount of occurrences in predicted documents.
       
      int32 predicted_occurrences_count = 4;
      Returns:
      This builder for chaining.
    • getGroundTruthOccurrencesCount

      public int getGroundTruthOccurrencesCount()
       The amount of occurrences in ground truth documents.
       
      int32 ground_truth_occurrences_count = 5;
      Specified by:
      getGroundTruthOccurrencesCount in interface Evaluation.MetricsOrBuilder
      Returns:
      The groundTruthOccurrencesCount.
    • setGroundTruthOccurrencesCount

      public Evaluation.Metrics.Builder setGroundTruthOccurrencesCount(int value)
       The amount of occurrences in ground truth documents.
       
      int32 ground_truth_occurrences_count = 5;
      Parameters:
      value - The groundTruthOccurrencesCount to set.
      Returns:
      This builder for chaining.
    • clearGroundTruthOccurrencesCount

      public Evaluation.Metrics.Builder clearGroundTruthOccurrencesCount()
       The amount of occurrences in ground truth documents.
       
      int32 ground_truth_occurrences_count = 5;
      Returns:
      This builder for chaining.
    • getPredictedDocumentCount

      public int getPredictedDocumentCount()
       The amount of documents with a predicted occurrence.
       
      int32 predicted_document_count = 10;
      Specified by:
      getPredictedDocumentCount in interface Evaluation.MetricsOrBuilder
      Returns:
      The predictedDocumentCount.
    • setPredictedDocumentCount

      public Evaluation.Metrics.Builder setPredictedDocumentCount(int value)
       The amount of documents with a predicted occurrence.
       
      int32 predicted_document_count = 10;
      Parameters:
      value - The predictedDocumentCount to set.
      Returns:
      This builder for chaining.
    • clearPredictedDocumentCount

      public Evaluation.Metrics.Builder clearPredictedDocumentCount()
       The amount of documents with a predicted occurrence.
       
      int32 predicted_document_count = 10;
      Returns:
      This builder for chaining.
    • getGroundTruthDocumentCount

      public int getGroundTruthDocumentCount()
       The amount of documents with a ground truth occurrence.
       
      int32 ground_truth_document_count = 11;
      Specified by:
      getGroundTruthDocumentCount in interface Evaluation.MetricsOrBuilder
      Returns:
      The groundTruthDocumentCount.
    • setGroundTruthDocumentCount

      public Evaluation.Metrics.Builder setGroundTruthDocumentCount(int value)
       The amount of documents with a ground truth occurrence.
       
      int32 ground_truth_document_count = 11;
      Parameters:
      value - The groundTruthDocumentCount to set.
      Returns:
      This builder for chaining.
    • clearGroundTruthDocumentCount

      public Evaluation.Metrics.Builder clearGroundTruthDocumentCount()
       The amount of documents with a ground truth occurrence.
       
      int32 ground_truth_document_count = 11;
      Returns:
      This builder for chaining.
    • getTruePositivesCount

      public int getTruePositivesCount()
       The amount of true positives.
       
      int32 true_positives_count = 6;
      Specified by:
      getTruePositivesCount in interface Evaluation.MetricsOrBuilder
      Returns:
      The truePositivesCount.
    • setTruePositivesCount

      public Evaluation.Metrics.Builder setTruePositivesCount(int value)
       The amount of true positives.
       
      int32 true_positives_count = 6;
      Parameters:
      value - The truePositivesCount to set.
      Returns:
      This builder for chaining.
    • clearTruePositivesCount

      public Evaluation.Metrics.Builder clearTruePositivesCount()
       The amount of true positives.
       
      int32 true_positives_count = 6;
      Returns:
      This builder for chaining.
    • getFalsePositivesCount

      public int getFalsePositivesCount()
       The amount of false positives.
       
      int32 false_positives_count = 7;
      Specified by:
      getFalsePositivesCount in interface Evaluation.MetricsOrBuilder
      Returns:
      The falsePositivesCount.
    • setFalsePositivesCount

      public Evaluation.Metrics.Builder setFalsePositivesCount(int value)
       The amount of false positives.
       
      int32 false_positives_count = 7;
      Parameters:
      value - The falsePositivesCount to set.
      Returns:
      This builder for chaining.
    • clearFalsePositivesCount

      public Evaluation.Metrics.Builder clearFalsePositivesCount()
       The amount of false positives.
       
      int32 false_positives_count = 7;
      Returns:
      This builder for chaining.
    • getFalseNegativesCount

      public int getFalseNegativesCount()
       The amount of false negatives.
       
      int32 false_negatives_count = 8;
      Specified by:
      getFalseNegativesCount in interface Evaluation.MetricsOrBuilder
      Returns:
      The falseNegativesCount.
    • setFalseNegativesCount

      public Evaluation.Metrics.Builder setFalseNegativesCount(int value)
       The amount of false negatives.
       
      int32 false_negatives_count = 8;
      Parameters:
      value - The falseNegativesCount to set.
      Returns:
      This builder for chaining.
    • clearFalseNegativesCount

      public Evaluation.Metrics.Builder clearFalseNegativesCount()
       The amount of false negatives.
       
      int32 false_negatives_count = 8;
      Returns:
      This builder for chaining.
    • getTotalDocumentsCount

      public int getTotalDocumentsCount()
       The amount of documents that had an occurrence of this label.
       
      int32 total_documents_count = 9;
      Specified by:
      getTotalDocumentsCount in interface Evaluation.MetricsOrBuilder
      Returns:
      The totalDocumentsCount.
    • setTotalDocumentsCount

      public Evaluation.Metrics.Builder setTotalDocumentsCount(int value)
       The amount of documents that had an occurrence of this label.
       
      int32 total_documents_count = 9;
      Parameters:
      value - The totalDocumentsCount to set.
      Returns:
      This builder for chaining.
    • clearTotalDocumentsCount

      public Evaluation.Metrics.Builder clearTotalDocumentsCount()
       The amount of documents that had an occurrence of this label.
       
      int32 total_documents_count = 9;
      Returns:
      This builder for chaining.