// Generated by the protocol buffer compiler.  DO NOT EDIT!

#define INTERNAL_SUPPRESS_PROTOBUF_FIELD_DEPRECATION
#include "distributions/io/schema.pb.h"

#include <algorithm>

#include <google/protobuf/stubs/once.h>
#include <google/protobuf/io/coded_stream.h>
#include <google/protobuf/wire_format_lite_inl.h>
#include <google/protobuf/descriptor.h>
#include <google/protobuf/reflection_ops.h>
#include <google/protobuf/wire_format.h>
// @@protoc_insertion_point(includes)

namespace protobuf {
namespace distributions {

namespace {

const ::google::protobuf::Descriptor* Clustering_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
  Clustering_reflection_ = NULL;
const ::google::protobuf::Descriptor* Clustering_PitmanYor_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
  Clustering_PitmanYor_reflection_ = NULL;
const ::google::protobuf::Descriptor* Clustering_LowEntropy_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
  Clustering_LowEntropy_reflection_ = NULL;
const ::google::protobuf::Descriptor* BetaBernoulli_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
  BetaBernoulli_reflection_ = NULL;
const ::google::protobuf::Descriptor* BetaBernoulli_Shared_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
  BetaBernoulli_Shared_reflection_ = NULL;
const ::google::protobuf::Descriptor* BetaBernoulli_GridPrior_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
  BetaBernoulli_GridPrior_reflection_ = NULL;
const ::google::protobuf::Descriptor* BetaBernoulli_Group_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
  BetaBernoulli_Group_reflection_ = NULL;
const ::google::protobuf::Descriptor* DirichletDiscrete_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
  DirichletDiscrete_reflection_ = NULL;
const ::google::protobuf::Descriptor* DirichletDiscrete_Shared_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
  DirichletDiscrete_Shared_reflection_ = NULL;
const ::google::protobuf::Descriptor* DirichletDiscrete_GridPrior_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
  DirichletDiscrete_GridPrior_reflection_ = NULL;
const ::google::protobuf::Descriptor* DirichletDiscrete_Group_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
  DirichletDiscrete_Group_reflection_ = NULL;
const ::google::protobuf::Descriptor* DirichletProcessDiscrete_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
  DirichletProcessDiscrete_reflection_ = NULL;
const ::google::protobuf::Descriptor* DirichletProcessDiscrete_Shared_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
  DirichletProcessDiscrete_Shared_reflection_ = NULL;
const ::google::protobuf::Descriptor* DirichletProcessDiscrete_GridPrior_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
  DirichletProcessDiscrete_GridPrior_reflection_ = NULL;
const ::google::protobuf::Descriptor* DirichletProcessDiscrete_Group_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
  DirichletProcessDiscrete_Group_reflection_ = NULL;
const ::google::protobuf::Descriptor* PitmanYorProcessDiscrete_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
  PitmanYorProcessDiscrete_reflection_ = NULL;
const ::google::protobuf::Descriptor* PitmanYorProcessDiscrete_Shared_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
  PitmanYorProcessDiscrete_Shared_reflection_ = NULL;
const ::google::protobuf::Descriptor* PitmanYorProcessDiscrete_GridPrior_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
  PitmanYorProcessDiscrete_GridPrior_reflection_ = NULL;
const ::google::protobuf::Descriptor* PitmanYorProcessDiscrete_Group_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
  PitmanYorProcessDiscrete_Group_reflection_ = NULL;
const ::google::protobuf::Descriptor* GammaPoisson_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
  GammaPoisson_reflection_ = NULL;
const ::google::protobuf::Descriptor* GammaPoisson_Shared_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
  GammaPoisson_Shared_reflection_ = NULL;
const ::google::protobuf::Descriptor* GammaPoisson_GridPrior_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
  GammaPoisson_GridPrior_reflection_ = NULL;
const ::google::protobuf::Descriptor* GammaPoisson_Group_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
  GammaPoisson_Group_reflection_ = NULL;
const ::google::protobuf::Descriptor* BetaNegativeBinomial_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
  BetaNegativeBinomial_reflection_ = NULL;
const ::google::protobuf::Descriptor* BetaNegativeBinomial_Shared_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
  BetaNegativeBinomial_Shared_reflection_ = NULL;
const ::google::protobuf::Descriptor* BetaNegativeBinomial_GridPrior_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
  BetaNegativeBinomial_GridPrior_reflection_ = NULL;
const ::google::protobuf::Descriptor* BetaNegativeBinomial_Group_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
  BetaNegativeBinomial_Group_reflection_ = NULL;
const ::google::protobuf::Descriptor* NormalInverseChiSq_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
  NormalInverseChiSq_reflection_ = NULL;
const ::google::protobuf::Descriptor* NormalInverseChiSq_Shared_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
  NormalInverseChiSq_Shared_reflection_ = NULL;
const ::google::protobuf::Descriptor* NormalInverseChiSq_GridPrior_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
  NormalInverseChiSq_GridPrior_reflection_ = NULL;
const ::google::protobuf::Descriptor* NormalInverseChiSq_Group_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
  NormalInverseChiSq_Group_reflection_ = NULL;

}  // namespace


void protobuf_AssignDesc_distributions_2fio_2fschema_2eproto() {
  protobuf_AddDesc_distributions_2fio_2fschema_2eproto();
  const ::google::protobuf::FileDescriptor* file =
    ::google::protobuf::DescriptorPool::generated_pool()->FindFileByName(
      "distributions/io/schema.proto");
  GOOGLE_CHECK(file != NULL);
  Clustering_descriptor_ = file->message_type(0);
  static const int Clustering_offsets_[2] = {
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(Clustering, pitman_yor_),
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(Clustering, low_entropy_),
  };
  Clustering_reflection_ =
    new ::google::protobuf::internal::GeneratedMessageReflection(
      Clustering_descriptor_,
      Clustering::default_instance_,
      Clustering_offsets_,
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(Clustering, _has_bits_[0]),
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(Clustering, _unknown_fields_),
      -1,
      ::google::protobuf::DescriptorPool::generated_pool(),
      ::google::protobuf::MessageFactory::generated_factory(),
      sizeof(Clustering));
  Clustering_PitmanYor_descriptor_ = Clustering_descriptor_->nested_type(0);
  static const int Clustering_PitmanYor_offsets_[2] = {
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(Clustering_PitmanYor, alpha_),
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(Clustering_PitmanYor, d_),
  };
  Clustering_PitmanYor_reflection_ =
    new ::google::protobuf::internal::GeneratedMessageReflection(
      Clustering_PitmanYor_descriptor_,
      Clustering_PitmanYor::default_instance_,
      Clustering_PitmanYor_offsets_,
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(Clustering_PitmanYor, _has_bits_[0]),
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(Clustering_PitmanYor, _unknown_fields_),
      -1,
      ::google::protobuf::DescriptorPool::generated_pool(),
      ::google::protobuf::MessageFactory::generated_factory(),
      sizeof(Clustering_PitmanYor));
  Clustering_LowEntropy_descriptor_ = Clustering_descriptor_->nested_type(1);
  static const int Clustering_LowEntropy_offsets_[1] = {
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(Clustering_LowEntropy, dataset_size_),
  };
  Clustering_LowEntropy_reflection_ =
    new ::google::protobuf::internal::GeneratedMessageReflection(
      Clustering_LowEntropy_descriptor_,
      Clustering_LowEntropy::default_instance_,
      Clustering_LowEntropy_offsets_,
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(Clustering_LowEntropy, _has_bits_[0]),
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(Clustering_LowEntropy, _unknown_fields_),
      -1,
      ::google::protobuf::DescriptorPool::generated_pool(),
      ::google::protobuf::MessageFactory::generated_factory(),
      sizeof(Clustering_LowEntropy));
  BetaBernoulli_descriptor_ = file->message_type(1);
  static const int BetaBernoulli_offsets_[1] = {
  };
  BetaBernoulli_reflection_ =
    new ::google::protobuf::internal::GeneratedMessageReflection(
      BetaBernoulli_descriptor_,
      BetaBernoulli::default_instance_,
      BetaBernoulli_offsets_,
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BetaBernoulli, _has_bits_[0]),
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BetaBernoulli, _unknown_fields_),
      -1,
      ::google::protobuf::DescriptorPool::generated_pool(),
      ::google::protobuf::MessageFactory::generated_factory(),
      sizeof(BetaBernoulli));
  BetaBernoulli_Shared_descriptor_ = BetaBernoulli_descriptor_->nested_type(0);
  static const int BetaBernoulli_Shared_offsets_[2] = {
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BetaBernoulli_Shared, alpha_),
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BetaBernoulli_Shared, beta_),
  };
  BetaBernoulli_Shared_reflection_ =
    new ::google::protobuf::internal::GeneratedMessageReflection(
      BetaBernoulli_Shared_descriptor_,
      BetaBernoulli_Shared::default_instance_,
      BetaBernoulli_Shared_offsets_,
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BetaBernoulli_Shared, _has_bits_[0]),
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BetaBernoulli_Shared, _unknown_fields_),
      -1,
      ::google::protobuf::DescriptorPool::generated_pool(),
      ::google::protobuf::MessageFactory::generated_factory(),
      sizeof(BetaBernoulli_Shared));
  BetaBernoulli_GridPrior_descriptor_ = BetaBernoulli_descriptor_->nested_type(1);
  static const int BetaBernoulli_GridPrior_offsets_[2] = {
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BetaBernoulli_GridPrior, alpha_),
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BetaBernoulli_GridPrior, beta_),
  };
  BetaBernoulli_GridPrior_reflection_ =
    new ::google::protobuf::internal::GeneratedMessageReflection(
      BetaBernoulli_GridPrior_descriptor_,
      BetaBernoulli_GridPrior::default_instance_,
      BetaBernoulli_GridPrior_offsets_,
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BetaBernoulli_GridPrior, _has_bits_[0]),
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BetaBernoulli_GridPrior, _unknown_fields_),
      -1,
      ::google::protobuf::DescriptorPool::generated_pool(),
      ::google::protobuf::MessageFactory::generated_factory(),
      sizeof(BetaBernoulli_GridPrior));
  BetaBernoulli_Group_descriptor_ = BetaBernoulli_descriptor_->nested_type(2);
  static const int BetaBernoulli_Group_offsets_[2] = {
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BetaBernoulli_Group, heads_),
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BetaBernoulli_Group, tails_),
  };
  BetaBernoulli_Group_reflection_ =
    new ::google::protobuf::internal::GeneratedMessageReflection(
      BetaBernoulli_Group_descriptor_,
      BetaBernoulli_Group::default_instance_,
      BetaBernoulli_Group_offsets_,
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BetaBernoulli_Group, _has_bits_[0]),
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BetaBernoulli_Group, _unknown_fields_),
      -1,
      ::google::protobuf::DescriptorPool::generated_pool(),
      ::google::protobuf::MessageFactory::generated_factory(),
      sizeof(BetaBernoulli_Group));
  DirichletDiscrete_descriptor_ = file->message_type(2);
  static const int DirichletDiscrete_offsets_[1] = {
  };
  DirichletDiscrete_reflection_ =
    new ::google::protobuf::internal::GeneratedMessageReflection(
      DirichletDiscrete_descriptor_,
      DirichletDiscrete::default_instance_,
      DirichletDiscrete_offsets_,
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DirichletDiscrete, _has_bits_[0]),
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DirichletDiscrete, _unknown_fields_),
      -1,
      ::google::protobuf::DescriptorPool::generated_pool(),
      ::google::protobuf::MessageFactory::generated_factory(),
      sizeof(DirichletDiscrete));
  DirichletDiscrete_Shared_descriptor_ = DirichletDiscrete_descriptor_->nested_type(0);
  static const int DirichletDiscrete_Shared_offsets_[1] = {
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DirichletDiscrete_Shared, alphas_),
  };
  DirichletDiscrete_Shared_reflection_ =
    new ::google::protobuf::internal::GeneratedMessageReflection(
      DirichletDiscrete_Shared_descriptor_,
      DirichletDiscrete_Shared::default_instance_,
      DirichletDiscrete_Shared_offsets_,
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DirichletDiscrete_Shared, _has_bits_[0]),
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DirichletDiscrete_Shared, _unknown_fields_),
      -1,
      ::google::protobuf::DescriptorPool::generated_pool(),
      ::google::protobuf::MessageFactory::generated_factory(),
      sizeof(DirichletDiscrete_Shared));
  DirichletDiscrete_GridPrior_descriptor_ = DirichletDiscrete_descriptor_->nested_type(1);
  static const int DirichletDiscrete_GridPrior_offsets_[1] = {
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DirichletDiscrete_GridPrior, alpha_),
  };
  DirichletDiscrete_GridPrior_reflection_ =
    new ::google::protobuf::internal::GeneratedMessageReflection(
      DirichletDiscrete_GridPrior_descriptor_,
      DirichletDiscrete_GridPrior::default_instance_,
      DirichletDiscrete_GridPrior_offsets_,
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DirichletDiscrete_GridPrior, _has_bits_[0]),
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DirichletDiscrete_GridPrior, _unknown_fields_),
      -1,
      ::google::protobuf::DescriptorPool::generated_pool(),
      ::google::protobuf::MessageFactory::generated_factory(),
      sizeof(DirichletDiscrete_GridPrior));
  DirichletDiscrete_Group_descriptor_ = DirichletDiscrete_descriptor_->nested_type(2);
  static const int DirichletDiscrete_Group_offsets_[1] = {
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DirichletDiscrete_Group, counts_),
  };
  DirichletDiscrete_Group_reflection_ =
    new ::google::protobuf::internal::GeneratedMessageReflection(
      DirichletDiscrete_Group_descriptor_,
      DirichletDiscrete_Group::default_instance_,
      DirichletDiscrete_Group_offsets_,
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DirichletDiscrete_Group, _has_bits_[0]),
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DirichletDiscrete_Group, _unknown_fields_),
      -1,
      ::google::protobuf::DescriptorPool::generated_pool(),
      ::google::protobuf::MessageFactory::generated_factory(),
      sizeof(DirichletDiscrete_Group));
  DirichletProcessDiscrete_descriptor_ = file->message_type(3);
  static const int DirichletProcessDiscrete_offsets_[1] = {
  };
  DirichletProcessDiscrete_reflection_ =
    new ::google::protobuf::internal::GeneratedMessageReflection(
      DirichletProcessDiscrete_descriptor_,
      DirichletProcessDiscrete::default_instance_,
      DirichletProcessDiscrete_offsets_,
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DirichletProcessDiscrete, _has_bits_[0]),
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DirichletProcessDiscrete, _unknown_fields_),
      -1,
      ::google::protobuf::DescriptorPool::generated_pool(),
      ::google::protobuf::MessageFactory::generated_factory(),
      sizeof(DirichletProcessDiscrete));
  DirichletProcessDiscrete_Shared_descriptor_ = DirichletProcessDiscrete_descriptor_->nested_type(0);
  static const int DirichletProcessDiscrete_Shared_offsets_[5] = {
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DirichletProcessDiscrete_Shared, gamma_),
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DirichletProcessDiscrete_Shared, alpha_),
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DirichletProcessDiscrete_Shared, values_),
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DirichletProcessDiscrete_Shared, betas_),
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DirichletProcessDiscrete_Shared, counts_),
  };
  DirichletProcessDiscrete_Shared_reflection_ =
    new ::google::protobuf::internal::GeneratedMessageReflection(
      DirichletProcessDiscrete_Shared_descriptor_,
      DirichletProcessDiscrete_Shared::default_instance_,
      DirichletProcessDiscrete_Shared_offsets_,
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DirichletProcessDiscrete_Shared, _has_bits_[0]),
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DirichletProcessDiscrete_Shared, _unknown_fields_),
      -1,
      ::google::protobuf::DescriptorPool::generated_pool(),
      ::google::protobuf::MessageFactory::generated_factory(),
      sizeof(DirichletProcessDiscrete_Shared));
  DirichletProcessDiscrete_GridPrior_descriptor_ = DirichletProcessDiscrete_descriptor_->nested_type(1);
  static const int DirichletProcessDiscrete_GridPrior_offsets_[2] = {
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DirichletProcessDiscrete_GridPrior, gamma_),
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DirichletProcessDiscrete_GridPrior, alpha_),
  };
  DirichletProcessDiscrete_GridPrior_reflection_ =
    new ::google::protobuf::internal::GeneratedMessageReflection(
      DirichletProcessDiscrete_GridPrior_descriptor_,
      DirichletProcessDiscrete_GridPrior::default_instance_,
      DirichletProcessDiscrete_GridPrior_offsets_,
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DirichletProcessDiscrete_GridPrior, _has_bits_[0]),
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DirichletProcessDiscrete_GridPrior, _unknown_fields_),
      -1,
      ::google::protobuf::DescriptorPool::generated_pool(),
      ::google::protobuf::MessageFactory::generated_factory(),
      sizeof(DirichletProcessDiscrete_GridPrior));
  DirichletProcessDiscrete_Group_descriptor_ = DirichletProcessDiscrete_descriptor_->nested_type(2);
  static const int DirichletProcessDiscrete_Group_offsets_[2] = {
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DirichletProcessDiscrete_Group, keys_),
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DirichletProcessDiscrete_Group, values_),
  };
  DirichletProcessDiscrete_Group_reflection_ =
    new ::google::protobuf::internal::GeneratedMessageReflection(
      DirichletProcessDiscrete_Group_descriptor_,
      DirichletProcessDiscrete_Group::default_instance_,
      DirichletProcessDiscrete_Group_offsets_,
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DirichletProcessDiscrete_Group, _has_bits_[0]),
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DirichletProcessDiscrete_Group, _unknown_fields_),
      -1,
      ::google::protobuf::DescriptorPool::generated_pool(),
      ::google::protobuf::MessageFactory::generated_factory(),
      sizeof(DirichletProcessDiscrete_Group));
  PitmanYorProcessDiscrete_descriptor_ = file->message_type(4);
  static const int PitmanYorProcessDiscrete_offsets_[1] = {
  };
  PitmanYorProcessDiscrete_reflection_ =
    new ::google::protobuf::internal::GeneratedMessageReflection(
      PitmanYorProcessDiscrete_descriptor_,
      PitmanYorProcessDiscrete::default_instance_,
      PitmanYorProcessDiscrete_offsets_,
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PitmanYorProcessDiscrete, _has_bits_[0]),
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PitmanYorProcessDiscrete, _unknown_fields_),
      -1,
      ::google::protobuf::DescriptorPool::generated_pool(),
      ::google::protobuf::MessageFactory::generated_factory(),
      sizeof(PitmanYorProcessDiscrete));
  PitmanYorProcessDiscrete_Shared_descriptor_ = PitmanYorProcessDiscrete_descriptor_->nested_type(0);
  static const int PitmanYorProcessDiscrete_Shared_offsets_[3] = {
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PitmanYorProcessDiscrete_Shared, alpha_),
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PitmanYorProcessDiscrete_Shared, d_),
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PitmanYorProcessDiscrete_Shared, counts_),
  };
  PitmanYorProcessDiscrete_Shared_reflection_ =
    new ::google::protobuf::internal::GeneratedMessageReflection(
      PitmanYorProcessDiscrete_Shared_descriptor_,
      PitmanYorProcessDiscrete_Shared::default_instance_,
      PitmanYorProcessDiscrete_Shared_offsets_,
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PitmanYorProcessDiscrete_Shared, _has_bits_[0]),
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PitmanYorProcessDiscrete_Shared, _unknown_fields_),
      -1,
      ::google::protobuf::DescriptorPool::generated_pool(),
      ::google::protobuf::MessageFactory::generated_factory(),
      sizeof(PitmanYorProcessDiscrete_Shared));
  PitmanYorProcessDiscrete_GridPrior_descriptor_ = PitmanYorProcessDiscrete_descriptor_->nested_type(1);
  static const int PitmanYorProcessDiscrete_GridPrior_offsets_[1] = {
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PitmanYorProcessDiscrete_GridPrior, alpha_d_),
  };
  PitmanYorProcessDiscrete_GridPrior_reflection_ =
    new ::google::protobuf::internal::GeneratedMessageReflection(
      PitmanYorProcessDiscrete_GridPrior_descriptor_,
      PitmanYorProcessDiscrete_GridPrior::default_instance_,
      PitmanYorProcessDiscrete_GridPrior_offsets_,
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PitmanYorProcessDiscrete_GridPrior, _has_bits_[0]),
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PitmanYorProcessDiscrete_GridPrior, _unknown_fields_),
      -1,
      ::google::protobuf::DescriptorPool::generated_pool(),
      ::google::protobuf::MessageFactory::generated_factory(),
      sizeof(PitmanYorProcessDiscrete_GridPrior));
  PitmanYorProcessDiscrete_Group_descriptor_ = PitmanYorProcessDiscrete_descriptor_->nested_type(2);
  static const int PitmanYorProcessDiscrete_Group_offsets_[2] = {
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PitmanYorProcessDiscrete_Group, keys_),
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PitmanYorProcessDiscrete_Group, values_),
  };
  PitmanYorProcessDiscrete_Group_reflection_ =
    new ::google::protobuf::internal::GeneratedMessageReflection(
      PitmanYorProcessDiscrete_Group_descriptor_,
      PitmanYorProcessDiscrete_Group::default_instance_,
      PitmanYorProcessDiscrete_Group_offsets_,
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PitmanYorProcessDiscrete_Group, _has_bits_[0]),
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PitmanYorProcessDiscrete_Group, _unknown_fields_),
      -1,
      ::google::protobuf::DescriptorPool::generated_pool(),
      ::google::protobuf::MessageFactory::generated_factory(),
      sizeof(PitmanYorProcessDiscrete_Group));
  GammaPoisson_descriptor_ = file->message_type(5);
  static const int GammaPoisson_offsets_[1] = {
  };
  GammaPoisson_reflection_ =
    new ::google::protobuf::internal::GeneratedMessageReflection(
      GammaPoisson_descriptor_,
      GammaPoisson::default_instance_,
      GammaPoisson_offsets_,
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(GammaPoisson, _has_bits_[0]),
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(GammaPoisson, _unknown_fields_),
      -1,
      ::google::protobuf::DescriptorPool::generated_pool(),
      ::google::protobuf::MessageFactory::generated_factory(),
      sizeof(GammaPoisson));
  GammaPoisson_Shared_descriptor_ = GammaPoisson_descriptor_->nested_type(0);
  static const int GammaPoisson_Shared_offsets_[2] = {
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(GammaPoisson_Shared, alpha_),
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(GammaPoisson_Shared, inv_beta_),
  };
  GammaPoisson_Shared_reflection_ =
    new ::google::protobuf::internal::GeneratedMessageReflection(
      GammaPoisson_Shared_descriptor_,
      GammaPoisson_Shared::default_instance_,
      GammaPoisson_Shared_offsets_,
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(GammaPoisson_Shared, _has_bits_[0]),
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(GammaPoisson_Shared, _unknown_fields_),
      -1,
      ::google::protobuf::DescriptorPool::generated_pool(),
      ::google::protobuf::MessageFactory::generated_factory(),
      sizeof(GammaPoisson_Shared));
  GammaPoisson_GridPrior_descriptor_ = GammaPoisson_descriptor_->nested_type(1);
  static const int GammaPoisson_GridPrior_offsets_[2] = {
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(GammaPoisson_GridPrior, alpha_),
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(GammaPoisson_GridPrior, inv_beta_),
  };
  GammaPoisson_GridPrior_reflection_ =
    new ::google::protobuf::internal::GeneratedMessageReflection(
      GammaPoisson_GridPrior_descriptor_,
      GammaPoisson_GridPrior::default_instance_,
      GammaPoisson_GridPrior_offsets_,
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(GammaPoisson_GridPrior, _has_bits_[0]),
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(GammaPoisson_GridPrior, _unknown_fields_),
      -1,
      ::google::protobuf::DescriptorPool::generated_pool(),
      ::google::protobuf::MessageFactory::generated_factory(),
      sizeof(GammaPoisson_GridPrior));
  GammaPoisson_Group_descriptor_ = GammaPoisson_descriptor_->nested_type(2);
  static const int GammaPoisson_Group_offsets_[3] = {
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(GammaPoisson_Group, count_),
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(GammaPoisson_Group, sum_),
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(GammaPoisson_Group, log_prod_),
  };
  GammaPoisson_Group_reflection_ =
    new ::google::protobuf::internal::GeneratedMessageReflection(
      GammaPoisson_Group_descriptor_,
      GammaPoisson_Group::default_instance_,
      GammaPoisson_Group_offsets_,
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(GammaPoisson_Group, _has_bits_[0]),
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(GammaPoisson_Group, _unknown_fields_),
      -1,
      ::google::protobuf::DescriptorPool::generated_pool(),
      ::google::protobuf::MessageFactory::generated_factory(),
      sizeof(GammaPoisson_Group));
  BetaNegativeBinomial_descriptor_ = file->message_type(6);
  static const int BetaNegativeBinomial_offsets_[1] = {
  };
  BetaNegativeBinomial_reflection_ =
    new ::google::protobuf::internal::GeneratedMessageReflection(
      BetaNegativeBinomial_descriptor_,
      BetaNegativeBinomial::default_instance_,
      BetaNegativeBinomial_offsets_,
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BetaNegativeBinomial, _has_bits_[0]),
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BetaNegativeBinomial, _unknown_fields_),
      -1,
      ::google::protobuf::DescriptorPool::generated_pool(),
      ::google::protobuf::MessageFactory::generated_factory(),
      sizeof(BetaNegativeBinomial));
  BetaNegativeBinomial_Shared_descriptor_ = BetaNegativeBinomial_descriptor_->nested_type(0);
  static const int BetaNegativeBinomial_Shared_offsets_[3] = {
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BetaNegativeBinomial_Shared, alpha_),
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BetaNegativeBinomial_Shared, beta_),
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BetaNegativeBinomial_Shared, r_),
  };
  BetaNegativeBinomial_Shared_reflection_ =
    new ::google::protobuf::internal::GeneratedMessageReflection(
      BetaNegativeBinomial_Shared_descriptor_,
      BetaNegativeBinomial_Shared::default_instance_,
      BetaNegativeBinomial_Shared_offsets_,
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BetaNegativeBinomial_Shared, _has_bits_[0]),
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BetaNegativeBinomial_Shared, _unknown_fields_),
      -1,
      ::google::protobuf::DescriptorPool::generated_pool(),
      ::google::protobuf::MessageFactory::generated_factory(),
      sizeof(BetaNegativeBinomial_Shared));
  BetaNegativeBinomial_GridPrior_descriptor_ = BetaNegativeBinomial_descriptor_->nested_type(1);
  static const int BetaNegativeBinomial_GridPrior_offsets_[3] = {
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BetaNegativeBinomial_GridPrior, alpha_),
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BetaNegativeBinomial_GridPrior, beta_),
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BetaNegativeBinomial_GridPrior, r_),
  };
  BetaNegativeBinomial_GridPrior_reflection_ =
    new ::google::protobuf::internal::GeneratedMessageReflection(
      BetaNegativeBinomial_GridPrior_descriptor_,
      BetaNegativeBinomial_GridPrior::default_instance_,
      BetaNegativeBinomial_GridPrior_offsets_,
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BetaNegativeBinomial_GridPrior, _has_bits_[0]),
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BetaNegativeBinomial_GridPrior, _unknown_fields_),
      -1,
      ::google::protobuf::DescriptorPool::generated_pool(),
      ::google::protobuf::MessageFactory::generated_factory(),
      sizeof(BetaNegativeBinomial_GridPrior));
  BetaNegativeBinomial_Group_descriptor_ = BetaNegativeBinomial_descriptor_->nested_type(2);
  static const int BetaNegativeBinomial_Group_offsets_[2] = {
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BetaNegativeBinomial_Group, count_),
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BetaNegativeBinomial_Group, sum_),
  };
  BetaNegativeBinomial_Group_reflection_ =
    new ::google::protobuf::internal::GeneratedMessageReflection(
      BetaNegativeBinomial_Group_descriptor_,
      BetaNegativeBinomial_Group::default_instance_,
      BetaNegativeBinomial_Group_offsets_,
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BetaNegativeBinomial_Group, _has_bits_[0]),
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BetaNegativeBinomial_Group, _unknown_fields_),
      -1,
      ::google::protobuf::DescriptorPool::generated_pool(),
      ::google::protobuf::MessageFactory::generated_factory(),
      sizeof(BetaNegativeBinomial_Group));
  NormalInverseChiSq_descriptor_ = file->message_type(7);
  static const int NormalInverseChiSq_offsets_[1] = {
  };
  NormalInverseChiSq_reflection_ =
    new ::google::protobuf::internal::GeneratedMessageReflection(
      NormalInverseChiSq_descriptor_,
      NormalInverseChiSq::default_instance_,
      NormalInverseChiSq_offsets_,
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NormalInverseChiSq, _has_bits_[0]),
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NormalInverseChiSq, _unknown_fields_),
      -1,
      ::google::protobuf::DescriptorPool::generated_pool(),
      ::google::protobuf::MessageFactory::generated_factory(),
      sizeof(NormalInverseChiSq));
  NormalInverseChiSq_Shared_descriptor_ = NormalInverseChiSq_descriptor_->nested_type(0);
  static const int NormalInverseChiSq_Shared_offsets_[4] = {
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NormalInverseChiSq_Shared, mu_),
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NormalInverseChiSq_Shared, kappa_),
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NormalInverseChiSq_Shared, sigmasq_),
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NormalInverseChiSq_Shared, nu_),
  };
  NormalInverseChiSq_Shared_reflection_ =
    new ::google::protobuf::internal::GeneratedMessageReflection(
      NormalInverseChiSq_Shared_descriptor_,
      NormalInverseChiSq_Shared::default_instance_,
      NormalInverseChiSq_Shared_offsets_,
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NormalInverseChiSq_Shared, _has_bits_[0]),
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NormalInverseChiSq_Shared, _unknown_fields_),
      -1,
      ::google::protobuf::DescriptorPool::generated_pool(),
      ::google::protobuf::MessageFactory::generated_factory(),
      sizeof(NormalInverseChiSq_Shared));
  NormalInverseChiSq_GridPrior_descriptor_ = NormalInverseChiSq_descriptor_->nested_type(1);
  static const int NormalInverseChiSq_GridPrior_offsets_[4] = {
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NormalInverseChiSq_GridPrior, mu_),
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NormalInverseChiSq_GridPrior, kappa_),
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NormalInverseChiSq_GridPrior, sigmasq_),
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NormalInverseChiSq_GridPrior, nu_),
  };
  NormalInverseChiSq_GridPrior_reflection_ =
    new ::google::protobuf::internal::GeneratedMessageReflection(
      NormalInverseChiSq_GridPrior_descriptor_,
      NormalInverseChiSq_GridPrior::default_instance_,
      NormalInverseChiSq_GridPrior_offsets_,
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NormalInverseChiSq_GridPrior, _has_bits_[0]),
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NormalInverseChiSq_GridPrior, _unknown_fields_),
      -1,
      ::google::protobuf::DescriptorPool::generated_pool(),
      ::google::protobuf::MessageFactory::generated_factory(),
      sizeof(NormalInverseChiSq_GridPrior));
  NormalInverseChiSq_Group_descriptor_ = NormalInverseChiSq_descriptor_->nested_type(2);
  static const int NormalInverseChiSq_Group_offsets_[3] = {
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NormalInverseChiSq_Group, count_),
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NormalInverseChiSq_Group, mean_),
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NormalInverseChiSq_Group, count_times_variance_),
  };
  NormalInverseChiSq_Group_reflection_ =
    new ::google::protobuf::internal::GeneratedMessageReflection(
      NormalInverseChiSq_Group_descriptor_,
      NormalInverseChiSq_Group::default_instance_,
      NormalInverseChiSq_Group_offsets_,
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NormalInverseChiSq_Group, _has_bits_[0]),
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NormalInverseChiSq_Group, _unknown_fields_),
      -1,
      ::google::protobuf::DescriptorPool::generated_pool(),
      ::google::protobuf::MessageFactory::generated_factory(),
      sizeof(NormalInverseChiSq_Group));
}

namespace {

GOOGLE_PROTOBUF_DECLARE_ONCE(protobuf_AssignDescriptors_once_);
inline void protobuf_AssignDescriptorsOnce() {
  ::google::protobuf::GoogleOnceInit(&protobuf_AssignDescriptors_once_,
                 &protobuf_AssignDesc_distributions_2fio_2fschema_2eproto);
}

void protobuf_RegisterTypes(const ::std::string&) {
  protobuf_AssignDescriptorsOnce();
  ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
    Clustering_descriptor_, &Clustering::default_instance());
  ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
    Clustering_PitmanYor_descriptor_, &Clustering_PitmanYor::default_instance());
  ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
    Clustering_LowEntropy_descriptor_, &Clustering_LowEntropy::default_instance());
  ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
    BetaBernoulli_descriptor_, &BetaBernoulli::default_instance());
  ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
    BetaBernoulli_Shared_descriptor_, &BetaBernoulli_Shared::default_instance());
  ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
    BetaBernoulli_GridPrior_descriptor_, &BetaBernoulli_GridPrior::default_instance());
  ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
    BetaBernoulli_Group_descriptor_, &BetaBernoulli_Group::default_instance());
  ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
    DirichletDiscrete_descriptor_, &DirichletDiscrete::default_instance());
  ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
    DirichletDiscrete_Shared_descriptor_, &DirichletDiscrete_Shared::default_instance());
  ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
    DirichletDiscrete_GridPrior_descriptor_, &DirichletDiscrete_GridPrior::default_instance());
  ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
    DirichletDiscrete_Group_descriptor_, &DirichletDiscrete_Group::default_instance());
  ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
    DirichletProcessDiscrete_descriptor_, &DirichletProcessDiscrete::default_instance());
  ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
    DirichletProcessDiscrete_Shared_descriptor_, &DirichletProcessDiscrete_Shared::default_instance());
  ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
    DirichletProcessDiscrete_GridPrior_descriptor_, &DirichletProcessDiscrete_GridPrior::default_instance());
  ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
    DirichletProcessDiscrete_Group_descriptor_, &DirichletProcessDiscrete_Group::default_instance());
  ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
    PitmanYorProcessDiscrete_descriptor_, &PitmanYorProcessDiscrete::default_instance());
  ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
    PitmanYorProcessDiscrete_Shared_descriptor_, &PitmanYorProcessDiscrete_Shared::default_instance());
  ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
    PitmanYorProcessDiscrete_GridPrior_descriptor_, &PitmanYorProcessDiscrete_GridPrior::default_instance());
  ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
    PitmanYorProcessDiscrete_Group_descriptor_, &PitmanYorProcessDiscrete_Group::default_instance());
  ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
    GammaPoisson_descriptor_, &GammaPoisson::default_instance());
  ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
    GammaPoisson_Shared_descriptor_, &GammaPoisson_Shared::default_instance());
  ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
    GammaPoisson_GridPrior_descriptor_, &GammaPoisson_GridPrior::default_instance());
  ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
    GammaPoisson_Group_descriptor_, &GammaPoisson_Group::default_instance());
  ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
    BetaNegativeBinomial_descriptor_, &BetaNegativeBinomial::default_instance());
  ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
    BetaNegativeBinomial_Shared_descriptor_, &BetaNegativeBinomial_Shared::default_instance());
  ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
    BetaNegativeBinomial_GridPrior_descriptor_, &BetaNegativeBinomial_GridPrior::default_instance());
  ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
    BetaNegativeBinomial_Group_descriptor_, &BetaNegativeBinomial_Group::default_instance());
  ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
    NormalInverseChiSq_descriptor_, &NormalInverseChiSq::default_instance());
  ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
    NormalInverseChiSq_Shared_descriptor_, &NormalInverseChiSq_Shared::default_instance());
  ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
    NormalInverseChiSq_GridPrior_descriptor_, &NormalInverseChiSq_GridPrior::default_instance());
  ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
    NormalInverseChiSq_Group_descriptor_, &NormalInverseChiSq_Group::default_instance());
}

}  // namespace

void protobuf_ShutdownFile_distributions_2fio_2fschema_2eproto() {
  delete Clustering::default_instance_;
  delete Clustering_reflection_;
  delete Clustering_PitmanYor::default_instance_;
  delete Clustering_PitmanYor_reflection_;
  delete Clustering_LowEntropy::default_instance_;
  delete Clustering_LowEntropy_reflection_;
  delete BetaBernoulli::default_instance_;
  delete BetaBernoulli_reflection_;
  delete BetaBernoulli_Shared::default_instance_;
  delete BetaBernoulli_Shared_reflection_;
  delete BetaBernoulli_GridPrior::default_instance_;
  delete BetaBernoulli_GridPrior_reflection_;
  delete BetaBernoulli_Group::default_instance_;
  delete BetaBernoulli_Group_reflection_;
  delete DirichletDiscrete::default_instance_;
  delete DirichletDiscrete_reflection_;
  delete DirichletDiscrete_Shared::default_instance_;
  delete DirichletDiscrete_Shared_reflection_;
  delete DirichletDiscrete_GridPrior::default_instance_;
  delete DirichletDiscrete_GridPrior_reflection_;
  delete DirichletDiscrete_Group::default_instance_;
  delete DirichletDiscrete_Group_reflection_;
  delete DirichletProcessDiscrete::default_instance_;
  delete DirichletProcessDiscrete_reflection_;
  delete DirichletProcessDiscrete_Shared::default_instance_;
  delete DirichletProcessDiscrete_Shared_reflection_;
  delete DirichletProcessDiscrete_GridPrior::default_instance_;
  delete DirichletProcessDiscrete_GridPrior_reflection_;
  delete DirichletProcessDiscrete_Group::default_instance_;
  delete DirichletProcessDiscrete_Group_reflection_;
  delete PitmanYorProcessDiscrete::default_instance_;
  delete PitmanYorProcessDiscrete_reflection_;
  delete PitmanYorProcessDiscrete_Shared::default_instance_;
  delete PitmanYorProcessDiscrete_Shared_reflection_;
  delete PitmanYorProcessDiscrete_GridPrior::default_instance_;
  delete PitmanYorProcessDiscrete_GridPrior_reflection_;
  delete PitmanYorProcessDiscrete_Group::default_instance_;
  delete PitmanYorProcessDiscrete_Group_reflection_;
  delete GammaPoisson::default_instance_;
  delete GammaPoisson_reflection_;
  delete GammaPoisson_Shared::default_instance_;
  delete GammaPoisson_Shared_reflection_;
  delete GammaPoisson_GridPrior::default_instance_;
  delete GammaPoisson_GridPrior_reflection_;
  delete GammaPoisson_Group::default_instance_;
  delete GammaPoisson_Group_reflection_;
  delete BetaNegativeBinomial::default_instance_;
  delete BetaNegativeBinomial_reflection_;
  delete BetaNegativeBinomial_Shared::default_instance_;
  delete BetaNegativeBinomial_Shared_reflection_;
  delete BetaNegativeBinomial_GridPrior::default_instance_;
  delete BetaNegativeBinomial_GridPrior_reflection_;
  delete BetaNegativeBinomial_Group::default_instance_;
  delete BetaNegativeBinomial_Group_reflection_;
  delete NormalInverseChiSq::default_instance_;
  delete NormalInverseChiSq_reflection_;
  delete NormalInverseChiSq_Shared::default_instance_;
  delete NormalInverseChiSq_Shared_reflection_;
  delete NormalInverseChiSq_GridPrior::default_instance_;
  delete NormalInverseChiSq_GridPrior_reflection_;
  delete NormalInverseChiSq_Group::default_instance_;
  delete NormalInverseChiSq_Group_reflection_;
}

void protobuf_AddDesc_distributions_2fio_2fschema_2eproto() {
  static bool already_here = false;
  if (already_here) return;
  already_here = true;
  GOOGLE_PROTOBUF_VERIFY_VERSION;

  ::google::protobuf::DescriptorPool::InternalAddGeneratedFile(
    "\n\035distributions/io/schema.proto\022\026protobu"
    "f.distributions\"\335\001\n\nClustering\022@\n\npitman"
    "_yor\030\001 \001(\0132,.protobuf.distributions.Clus"
    "tering.PitmanYor\022B\n\013low_entropy\030\002 \001(\0132-."
    "protobuf.distributions.Clustering.LowEnt"
    "ropy\032%\n\tPitmanYor\022\r\n\005alpha\030\001 \002(\002\022\t\n\001d\030\002 "
    "\002(\002\032\"\n\nLowEntropy\022\024\n\014dataset_size\030\001 \002(\004\""
    "\207\001\n\rBetaBernoulli\032%\n\006Shared\022\r\n\005alpha\030\001 \002"
    "(\002\022\014\n\004beta\030\002 \002(\002\032(\n\tGridPrior\022\r\n\005alpha\030\001"
    " \003(\002\022\014\n\004beta\030\002 \003(\002\032%\n\005Group\022\r\n\005heads\030\001 \002"
    "(\004\022\r\n\005tails\030\002 \002(\004\"b\n\021DirichletDiscrete\032\030"
    "\n\006Shared\022\016\n\006alphas\030\001 \003(\002\032\032\n\tGridPrior\022\r\n"
    "\005alpha\030\001 \003(\002\032\027\n\005Group\022\016\n\006counts\030\001 \003(\004\"\303\001"
    "\n\030DirichletProcessDiscrete\032U\n\006Shared\022\r\n\005"
    "gamma\030\001 \002(\002\022\r\n\005alpha\030\002 \002(\002\022\016\n\006values\030\003 \003"
    "(\r\022\r\n\005betas\030\004 \003(\002\022\016\n\006counts\030\005 \003(\004\032)\n\tGri"
    "dPrior\022\r\n\005gamma\030\001 \003(\002\022\r\n\005alpha\030\002 \003(\002\032%\n\005"
    "Group\022\014\n\004keys\030\001 \003(\r\022\016\n\006values\030\002 \003(\004\"\301\001\n\030"
    "PitmanYorProcessDiscrete\0322\n\006Shared\022\r\n\005al"
    "pha\030\001 \002(\002\022\t\n\001d\030\002 \003(\002\022\016\n\006counts\030\003 \003(\004\032J\n\t"
    "GridPrior\022=\n\007alpha_d\030\001 \003(\0132,.protobuf.di"
    "stributions.Clustering.PitmanYor\032%\n\005Grou"
    "p\022\014\n\004keys\030\001 \003(\r\022\016\n\006values\030\002 \003(\004\"\236\001\n\014Gamm"
    "aPoisson\032)\n\006Shared\022\r\n\005alpha\030\001 \002(\002\022\020\n\010inv"
    "_beta\030\002 \002(\002\032,\n\tGridPrior\022\r\n\005alpha\030\001 \003(\002\022"
    "\020\n\010inv_beta\030\002 \003(\002\0325\n\005Group\022\r\n\005count\030\001 \002("
    "\004\022\013\n\003sum\030\002 \002(\004\022\020\n\010log_prod\030\003 \002(\002\"\242\001\n\024Bet"
    "aNegativeBinomial\0320\n\006Shared\022\r\n\005alpha\030\001 \002"
    "(\002\022\014\n\004beta\030\002 \002(\002\022\t\n\001r\030\003 \002(\004\0323\n\tGridPrior"
    "\022\r\n\005alpha\030\001 \003(\002\022\014\n\004beta\030\002 \003(\002\022\t\n\001r\030\003 \003(\004"
    "\032#\n\005Group\022\r\n\005count\030\001 \002(\004\022\013\n\003sum\030\002 \002(\004\"\337\001"
    "\n\022NormalInverseChiSq\032@\n\006Shared\022\n\n\002mu\030\001 \002"
    "(\002\022\r\n\005kappa\030\002 \002(\002\022\017\n\007sigmasq\030\003 \002(\002\022\n\n\002nu"
    "\030\004 \002(\002\032C\n\tGridPrior\022\n\n\002mu\030\001 \003(\002\022\r\n\005kappa"
    "\030\002 \003(\002\022\017\n\007sigmasq\030\003 \003(\002\022\n\n\002nu\030\004 \003(\002\032B\n\005G"
    "roup\022\r\n\005count\030\001 \002(\004\022\014\n\004mean\030\002 \002(\002\022\034\n\024cou"
    "nt_times_variance\030\003 \002(\002", 1463);
  ::google::protobuf::MessageFactory::InternalRegisterGeneratedFile(
    "distributions/io/schema.proto", &protobuf_RegisterTypes);
  Clustering::default_instance_ = new Clustering();
  Clustering_PitmanYor::default_instance_ = new Clustering_PitmanYor();
  Clustering_LowEntropy::default_instance_ = new Clustering_LowEntropy();
  BetaBernoulli::default_instance_ = new BetaBernoulli();
  BetaBernoulli_Shared::default_instance_ = new BetaBernoulli_Shared();
  BetaBernoulli_GridPrior::default_instance_ = new BetaBernoulli_GridPrior();
  BetaBernoulli_Group::default_instance_ = new BetaBernoulli_Group();
  DirichletDiscrete::default_instance_ = new DirichletDiscrete();
  DirichletDiscrete_Shared::default_instance_ = new DirichletDiscrete_Shared();
  DirichletDiscrete_GridPrior::default_instance_ = new DirichletDiscrete_GridPrior();
  DirichletDiscrete_Group::default_instance_ = new DirichletDiscrete_Group();
  DirichletProcessDiscrete::default_instance_ = new DirichletProcessDiscrete();
  DirichletProcessDiscrete_Shared::default_instance_ = new DirichletProcessDiscrete_Shared();
  DirichletProcessDiscrete_GridPrior::default_instance_ = new DirichletProcessDiscrete_GridPrior();
  DirichletProcessDiscrete_Group::default_instance_ = new DirichletProcessDiscrete_Group();
  PitmanYorProcessDiscrete::default_instance_ = new PitmanYorProcessDiscrete();
  PitmanYorProcessDiscrete_Shared::default_instance_ = new PitmanYorProcessDiscrete_Shared();
  PitmanYorProcessDiscrete_GridPrior::default_instance_ = new PitmanYorProcessDiscrete_GridPrior();
  PitmanYorProcessDiscrete_Group::default_instance_ = new PitmanYorProcessDiscrete_Group();
  GammaPoisson::default_instance_ = new GammaPoisson();
  GammaPoisson_Shared::default_instance_ = new GammaPoisson_Shared();
  GammaPoisson_GridPrior::default_instance_ = new GammaPoisson_GridPrior();
  GammaPoisson_Group::default_instance_ = new GammaPoisson_Group();
  BetaNegativeBinomial::default_instance_ = new BetaNegativeBinomial();
  BetaNegativeBinomial_Shared::default_instance_ = new BetaNegativeBinomial_Shared();
  BetaNegativeBinomial_GridPrior::default_instance_ = new BetaNegativeBinomial_GridPrior();
  BetaNegativeBinomial_Group::default_instance_ = new BetaNegativeBinomial_Group();
  NormalInverseChiSq::default_instance_ = new NormalInverseChiSq();
  NormalInverseChiSq_Shared::default_instance_ = new NormalInverseChiSq_Shared();
  NormalInverseChiSq_GridPrior::default_instance_ = new NormalInverseChiSq_GridPrior();
  NormalInverseChiSq_Group::default_instance_ = new NormalInverseChiSq_Group();
  Clustering::default_instance_->InitAsDefaultInstance();
  Clustering_PitmanYor::default_instance_->InitAsDefaultInstance();
  Clustering_LowEntropy::default_instance_->InitAsDefaultInstance();
  BetaBernoulli::default_instance_->InitAsDefaultInstance();
  BetaBernoulli_Shared::default_instance_->InitAsDefaultInstance();
  BetaBernoulli_GridPrior::default_instance_->InitAsDefaultInstance();
  BetaBernoulli_Group::default_instance_->InitAsDefaultInstance();
  DirichletDiscrete::default_instance_->InitAsDefaultInstance();
  DirichletDiscrete_Shared::default_instance_->InitAsDefaultInstance();
  DirichletDiscrete_GridPrior::default_instance_->InitAsDefaultInstance();
  DirichletDiscrete_Group::default_instance_->InitAsDefaultInstance();
  DirichletProcessDiscrete::default_instance_->InitAsDefaultInstance();
  DirichletProcessDiscrete_Shared::default_instance_->InitAsDefaultInstance();
  DirichletProcessDiscrete_GridPrior::default_instance_->InitAsDefaultInstance();
  DirichletProcessDiscrete_Group::default_instance_->InitAsDefaultInstance();
  PitmanYorProcessDiscrete::default_instance_->InitAsDefaultInstance();
  PitmanYorProcessDiscrete_Shared::default_instance_->InitAsDefaultInstance();
  PitmanYorProcessDiscrete_GridPrior::default_instance_->InitAsDefaultInstance();
  PitmanYorProcessDiscrete_Group::default_instance_->InitAsDefaultInstance();
  GammaPoisson::default_instance_->InitAsDefaultInstance();
  GammaPoisson_Shared::default_instance_->InitAsDefaultInstance();
  GammaPoisson_GridPrior::default_instance_->InitAsDefaultInstance();
  GammaPoisson_Group::default_instance_->InitAsDefaultInstance();
  BetaNegativeBinomial::default_instance_->InitAsDefaultInstance();
  BetaNegativeBinomial_Shared::default_instance_->InitAsDefaultInstance();
  BetaNegativeBinomial_GridPrior::default_instance_->InitAsDefaultInstance();
  BetaNegativeBinomial_Group::default_instance_->InitAsDefaultInstance();
  NormalInverseChiSq::default_instance_->InitAsDefaultInstance();
  NormalInverseChiSq_Shared::default_instance_->InitAsDefaultInstance();
  NormalInverseChiSq_GridPrior::default_instance_->InitAsDefaultInstance();
  NormalInverseChiSq_Group::default_instance_->InitAsDefaultInstance();
  ::google::protobuf::internal::OnShutdown(&protobuf_ShutdownFile_distributions_2fio_2fschema_2eproto);
}

// Force AddDescriptors() to be called at static initialization time.
struct StaticDescriptorInitializer_distributions_2fio_2fschema_2eproto {
  StaticDescriptorInitializer_distributions_2fio_2fschema_2eproto() {
    protobuf_AddDesc_distributions_2fio_2fschema_2eproto();
  }
} static_descriptor_initializer_distributions_2fio_2fschema_2eproto_;


// ===================================================================

#ifndef _MSC_VER
const int Clustering_PitmanYor::kAlphaFieldNumber;
const int Clustering_PitmanYor::kDFieldNumber;
#endif  // !_MSC_VER

Clustering_PitmanYor::Clustering_PitmanYor()
  : ::google::protobuf::Message() {
  SharedCtor();
}

void Clustering_PitmanYor::InitAsDefaultInstance() {
}

Clustering_PitmanYor::Clustering_PitmanYor(const Clustering_PitmanYor& from)
  : ::google::protobuf::Message() {
  SharedCtor();
  MergeFrom(from);
}

void Clustering_PitmanYor::SharedCtor() {
  _cached_size_ = 0;
  alpha_ = 0;
  d_ = 0;
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}

Clustering_PitmanYor::~Clustering_PitmanYor() {
  SharedDtor();
}

void Clustering_PitmanYor::SharedDtor() {
  if (this != default_instance_) {
  }
}

void Clustering_PitmanYor::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* Clustering_PitmanYor::descriptor() {
  protobuf_AssignDescriptorsOnce();
  return Clustering_PitmanYor_descriptor_;
}

const Clustering_PitmanYor& Clustering_PitmanYor::default_instance() {
  if (default_instance_ == NULL) protobuf_AddDesc_distributions_2fio_2fschema_2eproto();  return *default_instance_;
}

Clustering_PitmanYor* Clustering_PitmanYor::default_instance_ = NULL;

Clustering_PitmanYor* Clustering_PitmanYor::New() const {
  return new Clustering_PitmanYor;
}

void Clustering_PitmanYor::Clear() {
  if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    alpha_ = 0;
    d_ = 0;
  }
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
  mutable_unknown_fields()->Clear();
}

bool Clustering_PitmanYor::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!(EXPRESSION)) return false
  ::google::protobuf::uint32 tag;
  while ((tag = input->ReadTag()) != 0) {
    switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
      // required float alpha = 1;
      case 1: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_FIXED32) {
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 input, &alpha_)));
          set_has_alpha();
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(21)) goto parse_d;
        break;
      }
      
      // required float d = 2;
      case 2: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_FIXED32) {
         parse_d:
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 input, &d_)));
          set_has_d();
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectAtEnd()) return true;
        break;
      }
      
      default: {
      handle_uninterpreted:
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
          return true;
        }
        DO_(::google::protobuf::internal::WireFormat::SkipField(
              input, tag, mutable_unknown_fields()));
        break;
      }
    }
  }
  return true;
#undef DO_
}

void Clustering_PitmanYor::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  // required float alpha = 1;
  if (has_alpha()) {
    ::google::protobuf::internal::WireFormatLite::WriteFloat(1, this->alpha(), output);
  }
  
  // required float d = 2;
  if (has_d()) {
    ::google::protobuf::internal::WireFormatLite::WriteFloat(2, this->d(), output);
  }
  
  if (!unknown_fields().empty()) {
    ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
        unknown_fields(), output);
  }
}

::google::protobuf::uint8* Clustering_PitmanYor::SerializeWithCachedSizesToArray(
    ::google::protobuf::uint8* target) const {
  // required float alpha = 1;
  if (has_alpha()) {
    target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(1, this->alpha(), target);
  }
  
  // required float d = 2;
  if (has_d()) {
    target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(2, this->d(), target);
  }
  
  if (!unknown_fields().empty()) {
    target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
        unknown_fields(), target);
  }
  return target;
}

int Clustering_PitmanYor::ByteSize() const {
  int total_size = 0;
  
  if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    // required float alpha = 1;
    if (has_alpha()) {
      total_size += 1 + 4;
    }
    
    // required float d = 2;
    if (has_d()) {
      total_size += 1 + 4;
    }
    
  }
  if (!unknown_fields().empty()) {
    total_size +=
      ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
        unknown_fields());
  }
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = total_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void Clustering_PitmanYor::MergeFrom(const ::google::protobuf::Message& from) {
  GOOGLE_CHECK_NE(&from, this);
  const Clustering_PitmanYor* source =
    ::google::protobuf::internal::dynamic_cast_if_available<const Clustering_PitmanYor*>(
      &from);
  if (source == NULL) {
    ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  } else {
    MergeFrom(*source);
  }
}

void Clustering_PitmanYor::MergeFrom(const Clustering_PitmanYor& from) {
  GOOGLE_CHECK_NE(&from, this);
  if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    if (from.has_alpha()) {
      set_alpha(from.alpha());
    }
    if (from.has_d()) {
      set_d(from.d());
    }
  }
  mutable_unknown_fields()->MergeFrom(from.unknown_fields());
}

void Clustering_PitmanYor::CopyFrom(const ::google::protobuf::Message& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

void Clustering_PitmanYor::CopyFrom(const Clustering_PitmanYor& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool Clustering_PitmanYor::IsInitialized() const {
  if ((_has_bits_[0] & 0x00000003) != 0x00000003) return false;
  
  return true;
}

void Clustering_PitmanYor::Swap(Clustering_PitmanYor* other) {
  if (other != this) {
    std::swap(alpha_, other->alpha_);
    std::swap(d_, other->d_);
    std::swap(_has_bits_[0], other->_has_bits_[0]);
    _unknown_fields_.Swap(&other->_unknown_fields_);
    std::swap(_cached_size_, other->_cached_size_);
  }
}

::google::protobuf::Metadata Clustering_PitmanYor::GetMetadata() const {
  protobuf_AssignDescriptorsOnce();
  ::google::protobuf::Metadata metadata;
  metadata.descriptor = Clustering_PitmanYor_descriptor_;
  metadata.reflection = Clustering_PitmanYor_reflection_;
  return metadata;
}


// -------------------------------------------------------------------

#ifndef _MSC_VER
const int Clustering_LowEntropy::kDatasetSizeFieldNumber;
#endif  // !_MSC_VER

Clustering_LowEntropy::Clustering_LowEntropy()
  : ::google::protobuf::Message() {
  SharedCtor();
}

void Clustering_LowEntropy::InitAsDefaultInstance() {
}

Clustering_LowEntropy::Clustering_LowEntropy(const Clustering_LowEntropy& from)
  : ::google::protobuf::Message() {
  SharedCtor();
  MergeFrom(from);
}

void Clustering_LowEntropy::SharedCtor() {
  _cached_size_ = 0;
  dataset_size_ = GOOGLE_ULONGLONG(0);
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}

Clustering_LowEntropy::~Clustering_LowEntropy() {
  SharedDtor();
}

void Clustering_LowEntropy::SharedDtor() {
  if (this != default_instance_) {
  }
}

void Clustering_LowEntropy::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* Clustering_LowEntropy::descriptor() {
  protobuf_AssignDescriptorsOnce();
  return Clustering_LowEntropy_descriptor_;
}

const Clustering_LowEntropy& Clustering_LowEntropy::default_instance() {
  if (default_instance_ == NULL) protobuf_AddDesc_distributions_2fio_2fschema_2eproto();  return *default_instance_;
}

Clustering_LowEntropy* Clustering_LowEntropy::default_instance_ = NULL;

Clustering_LowEntropy* Clustering_LowEntropy::New() const {
  return new Clustering_LowEntropy;
}

void Clustering_LowEntropy::Clear() {
  if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    dataset_size_ = GOOGLE_ULONGLONG(0);
  }
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
  mutable_unknown_fields()->Clear();
}

bool Clustering_LowEntropy::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!(EXPRESSION)) return false
  ::google::protobuf::uint32 tag;
  while ((tag = input->ReadTag()) != 0) {
    switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
      // required uint64 dataset_size = 1;
      case 1: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
                 input, &dataset_size_)));
          set_has_dataset_size();
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectAtEnd()) return true;
        break;
      }
      
      default: {
      handle_uninterpreted:
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
          return true;
        }
        DO_(::google::protobuf::internal::WireFormat::SkipField(
              input, tag, mutable_unknown_fields()));
        break;
      }
    }
  }
  return true;
#undef DO_
}

void Clustering_LowEntropy::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  // required uint64 dataset_size = 1;
  if (has_dataset_size()) {
    ::google::protobuf::internal::WireFormatLite::WriteUInt64(1, this->dataset_size(), output);
  }
  
  if (!unknown_fields().empty()) {
    ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
        unknown_fields(), output);
  }
}

::google::protobuf::uint8* Clustering_LowEntropy::SerializeWithCachedSizesToArray(
    ::google::protobuf::uint8* target) const {
  // required uint64 dataset_size = 1;
  if (has_dataset_size()) {
    target = ::google::protobuf::internal::WireFormatLite::WriteUInt64ToArray(1, this->dataset_size(), target);
  }
  
  if (!unknown_fields().empty()) {
    target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
        unknown_fields(), target);
  }
  return target;
}

int Clustering_LowEntropy::ByteSize() const {
  int total_size = 0;
  
  if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    // required uint64 dataset_size = 1;
    if (has_dataset_size()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::UInt64Size(
          this->dataset_size());
    }
    
  }
  if (!unknown_fields().empty()) {
    total_size +=
      ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
        unknown_fields());
  }
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = total_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void Clustering_LowEntropy::MergeFrom(const ::google::protobuf::Message& from) {
  GOOGLE_CHECK_NE(&from, this);
  const Clustering_LowEntropy* source =
    ::google::protobuf::internal::dynamic_cast_if_available<const Clustering_LowEntropy*>(
      &from);
  if (source == NULL) {
    ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  } else {
    MergeFrom(*source);
  }
}

void Clustering_LowEntropy::MergeFrom(const Clustering_LowEntropy& from) {
  GOOGLE_CHECK_NE(&from, this);
  if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    if (from.has_dataset_size()) {
      set_dataset_size(from.dataset_size());
    }
  }
  mutable_unknown_fields()->MergeFrom(from.unknown_fields());
}

void Clustering_LowEntropy::CopyFrom(const ::google::protobuf::Message& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

void Clustering_LowEntropy::CopyFrom(const Clustering_LowEntropy& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool Clustering_LowEntropy::IsInitialized() const {
  if ((_has_bits_[0] & 0x00000001) != 0x00000001) return false;
  
  return true;
}

void Clustering_LowEntropy::Swap(Clustering_LowEntropy* other) {
  if (other != this) {
    std::swap(dataset_size_, other->dataset_size_);
    std::swap(_has_bits_[0], other->_has_bits_[0]);
    _unknown_fields_.Swap(&other->_unknown_fields_);
    std::swap(_cached_size_, other->_cached_size_);
  }
}

::google::protobuf::Metadata Clustering_LowEntropy::GetMetadata() const {
  protobuf_AssignDescriptorsOnce();
  ::google::protobuf::Metadata metadata;
  metadata.descriptor = Clustering_LowEntropy_descriptor_;
  metadata.reflection = Clustering_LowEntropy_reflection_;
  return metadata;
}


// -------------------------------------------------------------------

#ifndef _MSC_VER
const int Clustering::kPitmanYorFieldNumber;
const int Clustering::kLowEntropyFieldNumber;
#endif  // !_MSC_VER

Clustering::Clustering()
  : ::google::protobuf::Message() {
  SharedCtor();
}

void Clustering::InitAsDefaultInstance() {
  pitman_yor_ = const_cast< ::protobuf::distributions::Clustering_PitmanYor*>(&::protobuf::distributions::Clustering_PitmanYor::default_instance());
  low_entropy_ = const_cast< ::protobuf::distributions::Clustering_LowEntropy*>(&::protobuf::distributions::Clustering_LowEntropy::default_instance());
}

Clustering::Clustering(const Clustering& from)
  : ::google::protobuf::Message() {
  SharedCtor();
  MergeFrom(from);
}

void Clustering::SharedCtor() {
  _cached_size_ = 0;
  pitman_yor_ = NULL;
  low_entropy_ = NULL;
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}

Clustering::~Clustering() {
  SharedDtor();
}

void Clustering::SharedDtor() {
  if (this != default_instance_) {
    delete pitman_yor_;
    delete low_entropy_;
  }
}

void Clustering::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* Clustering::descriptor() {
  protobuf_AssignDescriptorsOnce();
  return Clustering_descriptor_;
}

const Clustering& Clustering::default_instance() {
  if (default_instance_ == NULL) protobuf_AddDesc_distributions_2fio_2fschema_2eproto();  return *default_instance_;
}

Clustering* Clustering::default_instance_ = NULL;

Clustering* Clustering::New() const {
  return new Clustering;
}

void Clustering::Clear() {
  if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    if (has_pitman_yor()) {
      if (pitman_yor_ != NULL) pitman_yor_->::protobuf::distributions::Clustering_PitmanYor::Clear();
    }
    if (has_low_entropy()) {
      if (low_entropy_ != NULL) low_entropy_->::protobuf::distributions::Clustering_LowEntropy::Clear();
    }
  }
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
  mutable_unknown_fields()->Clear();
}

bool Clustering::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!(EXPRESSION)) return false
  ::google::protobuf::uint32 tag;
  while ((tag = input->ReadTag()) != 0) {
    switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
      // optional .protobuf.distributions.Clustering.PitmanYor pitman_yor = 1;
      case 1: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED) {
          DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
               input, mutable_pitman_yor()));
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(18)) goto parse_low_entropy;
        break;
      }
      
      // optional .protobuf.distributions.Clustering.LowEntropy low_entropy = 2;
      case 2: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED) {
         parse_low_entropy:
          DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
               input, mutable_low_entropy()));
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectAtEnd()) return true;
        break;
      }
      
      default: {
      handle_uninterpreted:
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
          return true;
        }
        DO_(::google::protobuf::internal::WireFormat::SkipField(
              input, tag, mutable_unknown_fields()));
        break;
      }
    }
  }
  return true;
#undef DO_
}

void Clustering::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  // optional .protobuf.distributions.Clustering.PitmanYor pitman_yor = 1;
  if (has_pitman_yor()) {
    ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
      1, this->pitman_yor(), output);
  }
  
  // optional .protobuf.distributions.Clustering.LowEntropy low_entropy = 2;
  if (has_low_entropy()) {
    ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
      2, this->low_entropy(), output);
  }
  
  if (!unknown_fields().empty()) {
    ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
        unknown_fields(), output);
  }
}

::google::protobuf::uint8* Clustering::SerializeWithCachedSizesToArray(
    ::google::protobuf::uint8* target) const {
  // optional .protobuf.distributions.Clustering.PitmanYor pitman_yor = 1;
  if (has_pitman_yor()) {
    target = ::google::protobuf::internal::WireFormatLite::
      WriteMessageNoVirtualToArray(
        1, this->pitman_yor(), target);
  }
  
  // optional .protobuf.distributions.Clustering.LowEntropy low_entropy = 2;
  if (has_low_entropy()) {
    target = ::google::protobuf::internal::WireFormatLite::
      WriteMessageNoVirtualToArray(
        2, this->low_entropy(), target);
  }
  
  if (!unknown_fields().empty()) {
    target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
        unknown_fields(), target);
  }
  return target;
}

int Clustering::ByteSize() const {
  int total_size = 0;
  
  if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    // optional .protobuf.distributions.Clustering.PitmanYor pitman_yor = 1;
    if (has_pitman_yor()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
          this->pitman_yor());
    }
    
    // optional .protobuf.distributions.Clustering.LowEntropy low_entropy = 2;
    if (has_low_entropy()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
          this->low_entropy());
    }
    
  }
  if (!unknown_fields().empty()) {
    total_size +=
      ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
        unknown_fields());
  }
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = total_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void Clustering::MergeFrom(const ::google::protobuf::Message& from) {
  GOOGLE_CHECK_NE(&from, this);
  const Clustering* source =
    ::google::protobuf::internal::dynamic_cast_if_available<const Clustering*>(
      &from);
  if (source == NULL) {
    ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  } else {
    MergeFrom(*source);
  }
}

void Clustering::MergeFrom(const Clustering& from) {
  GOOGLE_CHECK_NE(&from, this);
  if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    if (from.has_pitman_yor()) {
      mutable_pitman_yor()->::protobuf::distributions::Clustering_PitmanYor::MergeFrom(from.pitman_yor());
    }
    if (from.has_low_entropy()) {
      mutable_low_entropy()->::protobuf::distributions::Clustering_LowEntropy::MergeFrom(from.low_entropy());
    }
  }
  mutable_unknown_fields()->MergeFrom(from.unknown_fields());
}

void Clustering::CopyFrom(const ::google::protobuf::Message& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

void Clustering::CopyFrom(const Clustering& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool Clustering::IsInitialized() const {
  
  if (has_pitman_yor()) {
    if (!this->pitman_yor().IsInitialized()) return false;
  }
  if (has_low_entropy()) {
    if (!this->low_entropy().IsInitialized()) return false;
  }
  return true;
}

void Clustering::Swap(Clustering* other) {
  if (other != this) {
    std::swap(pitman_yor_, other->pitman_yor_);
    std::swap(low_entropy_, other->low_entropy_);
    std::swap(_has_bits_[0], other->_has_bits_[0]);
    _unknown_fields_.Swap(&other->_unknown_fields_);
    std::swap(_cached_size_, other->_cached_size_);
  }
}

::google::protobuf::Metadata Clustering::GetMetadata() const {
  protobuf_AssignDescriptorsOnce();
  ::google::protobuf::Metadata metadata;
  metadata.descriptor = Clustering_descriptor_;
  metadata.reflection = Clustering_reflection_;
  return metadata;
}


// ===================================================================

#ifndef _MSC_VER
const int BetaBernoulli_Shared::kAlphaFieldNumber;
const int BetaBernoulli_Shared::kBetaFieldNumber;
#endif  // !_MSC_VER

BetaBernoulli_Shared::BetaBernoulli_Shared()
  : ::google::protobuf::Message() {
  SharedCtor();
}

void BetaBernoulli_Shared::InitAsDefaultInstance() {
}

BetaBernoulli_Shared::BetaBernoulli_Shared(const BetaBernoulli_Shared& from)
  : ::google::protobuf::Message() {
  SharedCtor();
  MergeFrom(from);
}

void BetaBernoulli_Shared::SharedCtor() {
  _cached_size_ = 0;
  alpha_ = 0;
  beta_ = 0;
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}

BetaBernoulli_Shared::~BetaBernoulli_Shared() {
  SharedDtor();
}

void BetaBernoulli_Shared::SharedDtor() {
  if (this != default_instance_) {
  }
}

void BetaBernoulli_Shared::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* BetaBernoulli_Shared::descriptor() {
  protobuf_AssignDescriptorsOnce();
  return BetaBernoulli_Shared_descriptor_;
}

const BetaBernoulli_Shared& BetaBernoulli_Shared::default_instance() {
  if (default_instance_ == NULL) protobuf_AddDesc_distributions_2fio_2fschema_2eproto();  return *default_instance_;
}

BetaBernoulli_Shared* BetaBernoulli_Shared::default_instance_ = NULL;

BetaBernoulli_Shared* BetaBernoulli_Shared::New() const {
  return new BetaBernoulli_Shared;
}

void BetaBernoulli_Shared::Clear() {
  if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    alpha_ = 0;
    beta_ = 0;
  }
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
  mutable_unknown_fields()->Clear();
}

bool BetaBernoulli_Shared::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!(EXPRESSION)) return false
  ::google::protobuf::uint32 tag;
  while ((tag = input->ReadTag()) != 0) {
    switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
      // required float alpha = 1;
      case 1: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_FIXED32) {
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 input, &alpha_)));
          set_has_alpha();
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(21)) goto parse_beta;
        break;
      }
      
      // required float beta = 2;
      case 2: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_FIXED32) {
         parse_beta:
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 input, &beta_)));
          set_has_beta();
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectAtEnd()) return true;
        break;
      }
      
      default: {
      handle_uninterpreted:
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
          return true;
        }
        DO_(::google::protobuf::internal::WireFormat::SkipField(
              input, tag, mutable_unknown_fields()));
        break;
      }
    }
  }
  return true;
#undef DO_
}

void BetaBernoulli_Shared::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  // required float alpha = 1;
  if (has_alpha()) {
    ::google::protobuf::internal::WireFormatLite::WriteFloat(1, this->alpha(), output);
  }
  
  // required float beta = 2;
  if (has_beta()) {
    ::google::protobuf::internal::WireFormatLite::WriteFloat(2, this->beta(), output);
  }
  
  if (!unknown_fields().empty()) {
    ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
        unknown_fields(), output);
  }
}

::google::protobuf::uint8* BetaBernoulli_Shared::SerializeWithCachedSizesToArray(
    ::google::protobuf::uint8* target) const {
  // required float alpha = 1;
  if (has_alpha()) {
    target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(1, this->alpha(), target);
  }
  
  // required float beta = 2;
  if (has_beta()) {
    target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(2, this->beta(), target);
  }
  
  if (!unknown_fields().empty()) {
    target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
        unknown_fields(), target);
  }
  return target;
}

int BetaBernoulli_Shared::ByteSize() const {
  int total_size = 0;
  
  if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    // required float alpha = 1;
    if (has_alpha()) {
      total_size += 1 + 4;
    }
    
    // required float beta = 2;
    if (has_beta()) {
      total_size += 1 + 4;
    }
    
  }
  if (!unknown_fields().empty()) {
    total_size +=
      ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
        unknown_fields());
  }
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = total_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void BetaBernoulli_Shared::MergeFrom(const ::google::protobuf::Message& from) {
  GOOGLE_CHECK_NE(&from, this);
  const BetaBernoulli_Shared* source =
    ::google::protobuf::internal::dynamic_cast_if_available<const BetaBernoulli_Shared*>(
      &from);
  if (source == NULL) {
    ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  } else {
    MergeFrom(*source);
  }
}

void BetaBernoulli_Shared::MergeFrom(const BetaBernoulli_Shared& from) {
  GOOGLE_CHECK_NE(&from, this);
  if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    if (from.has_alpha()) {
      set_alpha(from.alpha());
    }
    if (from.has_beta()) {
      set_beta(from.beta());
    }
  }
  mutable_unknown_fields()->MergeFrom(from.unknown_fields());
}

void BetaBernoulli_Shared::CopyFrom(const ::google::protobuf::Message& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

void BetaBernoulli_Shared::CopyFrom(const BetaBernoulli_Shared& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool BetaBernoulli_Shared::IsInitialized() const {
  if ((_has_bits_[0] & 0x00000003) != 0x00000003) return false;
  
  return true;
}

void BetaBernoulli_Shared::Swap(BetaBernoulli_Shared* other) {
  if (other != this) {
    std::swap(alpha_, other->alpha_);
    std::swap(beta_, other->beta_);
    std::swap(_has_bits_[0], other->_has_bits_[0]);
    _unknown_fields_.Swap(&other->_unknown_fields_);
    std::swap(_cached_size_, other->_cached_size_);
  }
}

::google::protobuf::Metadata BetaBernoulli_Shared::GetMetadata() const {
  protobuf_AssignDescriptorsOnce();
  ::google::protobuf::Metadata metadata;
  metadata.descriptor = BetaBernoulli_Shared_descriptor_;
  metadata.reflection = BetaBernoulli_Shared_reflection_;
  return metadata;
}


// -------------------------------------------------------------------

#ifndef _MSC_VER
const int BetaBernoulli_GridPrior::kAlphaFieldNumber;
const int BetaBernoulli_GridPrior::kBetaFieldNumber;
#endif  // !_MSC_VER

BetaBernoulli_GridPrior::BetaBernoulli_GridPrior()
  : ::google::protobuf::Message() {
  SharedCtor();
}

void BetaBernoulli_GridPrior::InitAsDefaultInstance() {
}

BetaBernoulli_GridPrior::BetaBernoulli_GridPrior(const BetaBernoulli_GridPrior& from)
  : ::google::protobuf::Message() {
  SharedCtor();
  MergeFrom(from);
}

void BetaBernoulli_GridPrior::SharedCtor() {
  _cached_size_ = 0;
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}

BetaBernoulli_GridPrior::~BetaBernoulli_GridPrior() {
  SharedDtor();
}

void BetaBernoulli_GridPrior::SharedDtor() {
  if (this != default_instance_) {
  }
}

void BetaBernoulli_GridPrior::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* BetaBernoulli_GridPrior::descriptor() {
  protobuf_AssignDescriptorsOnce();
  return BetaBernoulli_GridPrior_descriptor_;
}

const BetaBernoulli_GridPrior& BetaBernoulli_GridPrior::default_instance() {
  if (default_instance_ == NULL) protobuf_AddDesc_distributions_2fio_2fschema_2eproto();  return *default_instance_;
}

BetaBernoulli_GridPrior* BetaBernoulli_GridPrior::default_instance_ = NULL;

BetaBernoulli_GridPrior* BetaBernoulli_GridPrior::New() const {
  return new BetaBernoulli_GridPrior;
}

void BetaBernoulli_GridPrior::Clear() {
  alpha_.Clear();
  beta_.Clear();
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
  mutable_unknown_fields()->Clear();
}

bool BetaBernoulli_GridPrior::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!(EXPRESSION)) return false
  ::google::protobuf::uint32 tag;
  while ((tag = input->ReadTag()) != 0) {
    switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
      // repeated float alpha = 1;
      case 1: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_FIXED32) {
         parse_alpha:
          DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 1, 13, input, this->mutable_alpha())));
        } else if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag)
                   == ::google::protobuf::internal::WireFormatLite::
                      WIRETYPE_LENGTH_DELIMITED) {
          DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 input, this->mutable_alpha())));
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(13)) goto parse_alpha;
        if (input->ExpectTag(21)) goto parse_beta;
        break;
      }
      
      // repeated float beta = 2;
      case 2: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_FIXED32) {
         parse_beta:
          DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 1, 21, input, this->mutable_beta())));
        } else if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag)
                   == ::google::protobuf::internal::WireFormatLite::
                      WIRETYPE_LENGTH_DELIMITED) {
          DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 input, this->mutable_beta())));
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(21)) goto parse_beta;
        if (input->ExpectAtEnd()) return true;
        break;
      }
      
      default: {
      handle_uninterpreted:
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
          return true;
        }
        DO_(::google::protobuf::internal::WireFormat::SkipField(
              input, tag, mutable_unknown_fields()));
        break;
      }
    }
  }
  return true;
#undef DO_
}

void BetaBernoulli_GridPrior::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  // repeated float alpha = 1;
  for (int i = 0; i < this->alpha_size(); i++) {
    ::google::protobuf::internal::WireFormatLite::WriteFloat(
      1, this->alpha(i), output);
  }
  
  // repeated float beta = 2;
  for (int i = 0; i < this->beta_size(); i++) {
    ::google::protobuf::internal::WireFormatLite::WriteFloat(
      2, this->beta(i), output);
  }
  
  if (!unknown_fields().empty()) {
    ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
        unknown_fields(), output);
  }
}

::google::protobuf::uint8* BetaBernoulli_GridPrior::SerializeWithCachedSizesToArray(
    ::google::protobuf::uint8* target) const {
  // repeated float alpha = 1;
  for (int i = 0; i < this->alpha_size(); i++) {
    target = ::google::protobuf::internal::WireFormatLite::
      WriteFloatToArray(1, this->alpha(i), target);
  }
  
  // repeated float beta = 2;
  for (int i = 0; i < this->beta_size(); i++) {
    target = ::google::protobuf::internal::WireFormatLite::
      WriteFloatToArray(2, this->beta(i), target);
  }
  
  if (!unknown_fields().empty()) {
    target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
        unknown_fields(), target);
  }
  return target;
}

int BetaBernoulli_GridPrior::ByteSize() const {
  int total_size = 0;
  
  // repeated float alpha = 1;
  {
    int data_size = 0;
    data_size = 4 * this->alpha_size();
    total_size += 1 * this->alpha_size() + data_size;
  }
  
  // repeated float beta = 2;
  {
    int data_size = 0;
    data_size = 4 * this->beta_size();
    total_size += 1 * this->beta_size() + data_size;
  }
  
  if (!unknown_fields().empty()) {
    total_size +=
      ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
        unknown_fields());
  }
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = total_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void BetaBernoulli_GridPrior::MergeFrom(const ::google::protobuf::Message& from) {
  GOOGLE_CHECK_NE(&from, this);
  const BetaBernoulli_GridPrior* source =
    ::google::protobuf::internal::dynamic_cast_if_available<const BetaBernoulli_GridPrior*>(
      &from);
  if (source == NULL) {
    ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  } else {
    MergeFrom(*source);
  }
}

void BetaBernoulli_GridPrior::MergeFrom(const BetaBernoulli_GridPrior& from) {
  GOOGLE_CHECK_NE(&from, this);
  alpha_.MergeFrom(from.alpha_);
  beta_.MergeFrom(from.beta_);
  mutable_unknown_fields()->MergeFrom(from.unknown_fields());
}

void BetaBernoulli_GridPrior::CopyFrom(const ::google::protobuf::Message& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

void BetaBernoulli_GridPrior::CopyFrom(const BetaBernoulli_GridPrior& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool BetaBernoulli_GridPrior::IsInitialized() const {
  
  return true;
}

void BetaBernoulli_GridPrior::Swap(BetaBernoulli_GridPrior* other) {
  if (other != this) {
    alpha_.Swap(&other->alpha_);
    beta_.Swap(&other->beta_);
    std::swap(_has_bits_[0], other->_has_bits_[0]);
    _unknown_fields_.Swap(&other->_unknown_fields_);
    std::swap(_cached_size_, other->_cached_size_);
  }
}

::google::protobuf::Metadata BetaBernoulli_GridPrior::GetMetadata() const {
  protobuf_AssignDescriptorsOnce();
  ::google::protobuf::Metadata metadata;
  metadata.descriptor = BetaBernoulli_GridPrior_descriptor_;
  metadata.reflection = BetaBernoulli_GridPrior_reflection_;
  return metadata;
}


// -------------------------------------------------------------------

#ifndef _MSC_VER
const int BetaBernoulli_Group::kHeadsFieldNumber;
const int BetaBernoulli_Group::kTailsFieldNumber;
#endif  // !_MSC_VER

BetaBernoulli_Group::BetaBernoulli_Group()
  : ::google::protobuf::Message() {
  SharedCtor();
}

void BetaBernoulli_Group::InitAsDefaultInstance() {
}

BetaBernoulli_Group::BetaBernoulli_Group(const BetaBernoulli_Group& from)
  : ::google::protobuf::Message() {
  SharedCtor();
  MergeFrom(from);
}

void BetaBernoulli_Group::SharedCtor() {
  _cached_size_ = 0;
  heads_ = GOOGLE_ULONGLONG(0);
  tails_ = GOOGLE_ULONGLONG(0);
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}

BetaBernoulli_Group::~BetaBernoulli_Group() {
  SharedDtor();
}

void BetaBernoulli_Group::SharedDtor() {
  if (this != default_instance_) {
  }
}

void BetaBernoulli_Group::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* BetaBernoulli_Group::descriptor() {
  protobuf_AssignDescriptorsOnce();
  return BetaBernoulli_Group_descriptor_;
}

const BetaBernoulli_Group& BetaBernoulli_Group::default_instance() {
  if (default_instance_ == NULL) protobuf_AddDesc_distributions_2fio_2fschema_2eproto();  return *default_instance_;
}

BetaBernoulli_Group* BetaBernoulli_Group::default_instance_ = NULL;

BetaBernoulli_Group* BetaBernoulli_Group::New() const {
  return new BetaBernoulli_Group;
}

void BetaBernoulli_Group::Clear() {
  if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    heads_ = GOOGLE_ULONGLONG(0);
    tails_ = GOOGLE_ULONGLONG(0);
  }
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
  mutable_unknown_fields()->Clear();
}

bool BetaBernoulli_Group::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!(EXPRESSION)) return false
  ::google::protobuf::uint32 tag;
  while ((tag = input->ReadTag()) != 0) {
    switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
      // required uint64 heads = 1;
      case 1: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
                 input, &heads_)));
          set_has_heads();
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(16)) goto parse_tails;
        break;
      }
      
      // required uint64 tails = 2;
      case 2: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
         parse_tails:
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
                 input, &tails_)));
          set_has_tails();
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectAtEnd()) return true;
        break;
      }
      
      default: {
      handle_uninterpreted:
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
          return true;
        }
        DO_(::google::protobuf::internal::WireFormat::SkipField(
              input, tag, mutable_unknown_fields()));
        break;
      }
    }
  }
  return true;
#undef DO_
}

void BetaBernoulli_Group::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  // required uint64 heads = 1;
  if (has_heads()) {
    ::google::protobuf::internal::WireFormatLite::WriteUInt64(1, this->heads(), output);
  }
  
  // required uint64 tails = 2;
  if (has_tails()) {
    ::google::protobuf::internal::WireFormatLite::WriteUInt64(2, this->tails(), output);
  }
  
  if (!unknown_fields().empty()) {
    ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
        unknown_fields(), output);
  }
}

::google::protobuf::uint8* BetaBernoulli_Group::SerializeWithCachedSizesToArray(
    ::google::protobuf::uint8* target) const {
  // required uint64 heads = 1;
  if (has_heads()) {
    target = ::google::protobuf::internal::WireFormatLite::WriteUInt64ToArray(1, this->heads(), target);
  }
  
  // required uint64 tails = 2;
  if (has_tails()) {
    target = ::google::protobuf::internal::WireFormatLite::WriteUInt64ToArray(2, this->tails(), target);
  }
  
  if (!unknown_fields().empty()) {
    target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
        unknown_fields(), target);
  }
  return target;
}

int BetaBernoulli_Group::ByteSize() const {
  int total_size = 0;
  
  if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    // required uint64 heads = 1;
    if (has_heads()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::UInt64Size(
          this->heads());
    }
    
    // required uint64 tails = 2;
    if (has_tails()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::UInt64Size(
          this->tails());
    }
    
  }
  if (!unknown_fields().empty()) {
    total_size +=
      ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
        unknown_fields());
  }
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = total_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void BetaBernoulli_Group::MergeFrom(const ::google::protobuf::Message& from) {
  GOOGLE_CHECK_NE(&from, this);
  const BetaBernoulli_Group* source =
    ::google::protobuf::internal::dynamic_cast_if_available<const BetaBernoulli_Group*>(
      &from);
  if (source == NULL) {
    ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  } else {
    MergeFrom(*source);
  }
}

void BetaBernoulli_Group::MergeFrom(const BetaBernoulli_Group& from) {
  GOOGLE_CHECK_NE(&from, this);
  if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    if (from.has_heads()) {
      set_heads(from.heads());
    }
    if (from.has_tails()) {
      set_tails(from.tails());
    }
  }
  mutable_unknown_fields()->MergeFrom(from.unknown_fields());
}

void BetaBernoulli_Group::CopyFrom(const ::google::protobuf::Message& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

void BetaBernoulli_Group::CopyFrom(const BetaBernoulli_Group& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool BetaBernoulli_Group::IsInitialized() const {
  if ((_has_bits_[0] & 0x00000003) != 0x00000003) return false;
  
  return true;
}

void BetaBernoulli_Group::Swap(BetaBernoulli_Group* other) {
  if (other != this) {
    std::swap(heads_, other->heads_);
    std::swap(tails_, other->tails_);
    std::swap(_has_bits_[0], other->_has_bits_[0]);
    _unknown_fields_.Swap(&other->_unknown_fields_);
    std::swap(_cached_size_, other->_cached_size_);
  }
}

::google::protobuf::Metadata BetaBernoulli_Group::GetMetadata() const {
  protobuf_AssignDescriptorsOnce();
  ::google::protobuf::Metadata metadata;
  metadata.descriptor = BetaBernoulli_Group_descriptor_;
  metadata.reflection = BetaBernoulli_Group_reflection_;
  return metadata;
}


// -------------------------------------------------------------------

#ifndef _MSC_VER
#endif  // !_MSC_VER

BetaBernoulli::BetaBernoulli()
  : ::google::protobuf::Message() {
  SharedCtor();
}

void BetaBernoulli::InitAsDefaultInstance() {
}

BetaBernoulli::BetaBernoulli(const BetaBernoulli& from)
  : ::google::protobuf::Message() {
  SharedCtor();
  MergeFrom(from);
}

void BetaBernoulli::SharedCtor() {
  _cached_size_ = 0;
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}

BetaBernoulli::~BetaBernoulli() {
  SharedDtor();
}

void BetaBernoulli::SharedDtor() {
  if (this != default_instance_) {
  }
}

void BetaBernoulli::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* BetaBernoulli::descriptor() {
  protobuf_AssignDescriptorsOnce();
  return BetaBernoulli_descriptor_;
}

const BetaBernoulli& BetaBernoulli::default_instance() {
  if (default_instance_ == NULL) protobuf_AddDesc_distributions_2fio_2fschema_2eproto();  return *default_instance_;
}

BetaBernoulli* BetaBernoulli::default_instance_ = NULL;

BetaBernoulli* BetaBernoulli::New() const {
  return new BetaBernoulli;
}

void BetaBernoulli::Clear() {
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
  mutable_unknown_fields()->Clear();
}

bool BetaBernoulli::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!(EXPRESSION)) return false
  ::google::protobuf::uint32 tag;
  while ((tag = input->ReadTag()) != 0) {
    if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
        ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
      return true;
    }
    DO_(::google::protobuf::internal::WireFormat::SkipField(
          input, tag, mutable_unknown_fields()));
  }
  return true;
#undef DO_
}

void BetaBernoulli::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  if (!unknown_fields().empty()) {
    ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
        unknown_fields(), output);
  }
}

::google::protobuf::uint8* BetaBernoulli::SerializeWithCachedSizesToArray(
    ::google::protobuf::uint8* target) const {
  if (!unknown_fields().empty()) {
    target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
        unknown_fields(), target);
  }
  return target;
}

int BetaBernoulli::ByteSize() const {
  int total_size = 0;
  
  if (!unknown_fields().empty()) {
    total_size +=
      ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
        unknown_fields());
  }
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = total_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void BetaBernoulli::MergeFrom(const ::google::protobuf::Message& from) {
  GOOGLE_CHECK_NE(&from, this);
  const BetaBernoulli* source =
    ::google::protobuf::internal::dynamic_cast_if_available<const BetaBernoulli*>(
      &from);
  if (source == NULL) {
    ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  } else {
    MergeFrom(*source);
  }
}

void BetaBernoulli::MergeFrom(const BetaBernoulli& from) {
  GOOGLE_CHECK_NE(&from, this);
  mutable_unknown_fields()->MergeFrom(from.unknown_fields());
}

void BetaBernoulli::CopyFrom(const ::google::protobuf::Message& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

void BetaBernoulli::CopyFrom(const BetaBernoulli& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool BetaBernoulli::IsInitialized() const {
  
  return true;
}

void BetaBernoulli::Swap(BetaBernoulli* other) {
  if (other != this) {
    _unknown_fields_.Swap(&other->_unknown_fields_);
    std::swap(_cached_size_, other->_cached_size_);
  }
}

::google::protobuf::Metadata BetaBernoulli::GetMetadata() const {
  protobuf_AssignDescriptorsOnce();
  ::google::protobuf::Metadata metadata;
  metadata.descriptor = BetaBernoulli_descriptor_;
  metadata.reflection = BetaBernoulli_reflection_;
  return metadata;
}


// ===================================================================

#ifndef _MSC_VER
const int DirichletDiscrete_Shared::kAlphasFieldNumber;
#endif  // !_MSC_VER

DirichletDiscrete_Shared::DirichletDiscrete_Shared()
  : ::google::protobuf::Message() {
  SharedCtor();
}

void DirichletDiscrete_Shared::InitAsDefaultInstance() {
}

DirichletDiscrete_Shared::DirichletDiscrete_Shared(const DirichletDiscrete_Shared& from)
  : ::google::protobuf::Message() {
  SharedCtor();
  MergeFrom(from);
}

void DirichletDiscrete_Shared::SharedCtor() {
  _cached_size_ = 0;
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}

DirichletDiscrete_Shared::~DirichletDiscrete_Shared() {
  SharedDtor();
}

void DirichletDiscrete_Shared::SharedDtor() {
  if (this != default_instance_) {
  }
}

void DirichletDiscrete_Shared::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* DirichletDiscrete_Shared::descriptor() {
  protobuf_AssignDescriptorsOnce();
  return DirichletDiscrete_Shared_descriptor_;
}

const DirichletDiscrete_Shared& DirichletDiscrete_Shared::default_instance() {
  if (default_instance_ == NULL) protobuf_AddDesc_distributions_2fio_2fschema_2eproto();  return *default_instance_;
}

DirichletDiscrete_Shared* DirichletDiscrete_Shared::default_instance_ = NULL;

DirichletDiscrete_Shared* DirichletDiscrete_Shared::New() const {
  return new DirichletDiscrete_Shared;
}

void DirichletDiscrete_Shared::Clear() {
  alphas_.Clear();
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
  mutable_unknown_fields()->Clear();
}

bool DirichletDiscrete_Shared::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!(EXPRESSION)) return false
  ::google::protobuf::uint32 tag;
  while ((tag = input->ReadTag()) != 0) {
    switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
      // repeated float alphas = 1;
      case 1: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_FIXED32) {
         parse_alphas:
          DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 1, 13, input, this->mutable_alphas())));
        } else if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag)
                   == ::google::protobuf::internal::WireFormatLite::
                      WIRETYPE_LENGTH_DELIMITED) {
          DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 input, this->mutable_alphas())));
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(13)) goto parse_alphas;
        if (input->ExpectAtEnd()) return true;
        break;
      }
      
      default: {
      handle_uninterpreted:
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
          return true;
        }
        DO_(::google::protobuf::internal::WireFormat::SkipField(
              input, tag, mutable_unknown_fields()));
        break;
      }
    }
  }
  return true;
#undef DO_
}

void DirichletDiscrete_Shared::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  // repeated float alphas = 1;
  for (int i = 0; i < this->alphas_size(); i++) {
    ::google::protobuf::internal::WireFormatLite::WriteFloat(
      1, this->alphas(i), output);
  }
  
  if (!unknown_fields().empty()) {
    ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
        unknown_fields(), output);
  }
}

::google::protobuf::uint8* DirichletDiscrete_Shared::SerializeWithCachedSizesToArray(
    ::google::protobuf::uint8* target) const {
  // repeated float alphas = 1;
  for (int i = 0; i < this->alphas_size(); i++) {
    target = ::google::protobuf::internal::WireFormatLite::
      WriteFloatToArray(1, this->alphas(i), target);
  }
  
  if (!unknown_fields().empty()) {
    target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
        unknown_fields(), target);
  }
  return target;
}

int DirichletDiscrete_Shared::ByteSize() const {
  int total_size = 0;
  
  // repeated float alphas = 1;
  {
    int data_size = 0;
    data_size = 4 * this->alphas_size();
    total_size += 1 * this->alphas_size() + data_size;
  }
  
  if (!unknown_fields().empty()) {
    total_size +=
      ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
        unknown_fields());
  }
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = total_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void DirichletDiscrete_Shared::MergeFrom(const ::google::protobuf::Message& from) {
  GOOGLE_CHECK_NE(&from, this);
  const DirichletDiscrete_Shared* source =
    ::google::protobuf::internal::dynamic_cast_if_available<const DirichletDiscrete_Shared*>(
      &from);
  if (source == NULL) {
    ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  } else {
    MergeFrom(*source);
  }
}

void DirichletDiscrete_Shared::MergeFrom(const DirichletDiscrete_Shared& from) {
  GOOGLE_CHECK_NE(&from, this);
  alphas_.MergeFrom(from.alphas_);
  mutable_unknown_fields()->MergeFrom(from.unknown_fields());
}

void DirichletDiscrete_Shared::CopyFrom(const ::google::protobuf::Message& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

void DirichletDiscrete_Shared::CopyFrom(const DirichletDiscrete_Shared& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool DirichletDiscrete_Shared::IsInitialized() const {
  
  return true;
}

void DirichletDiscrete_Shared::Swap(DirichletDiscrete_Shared* other) {
  if (other != this) {
    alphas_.Swap(&other->alphas_);
    std::swap(_has_bits_[0], other->_has_bits_[0]);
    _unknown_fields_.Swap(&other->_unknown_fields_);
    std::swap(_cached_size_, other->_cached_size_);
  }
}

::google::protobuf::Metadata DirichletDiscrete_Shared::GetMetadata() const {
  protobuf_AssignDescriptorsOnce();
  ::google::protobuf::Metadata metadata;
  metadata.descriptor = DirichletDiscrete_Shared_descriptor_;
  metadata.reflection = DirichletDiscrete_Shared_reflection_;
  return metadata;
}


// -------------------------------------------------------------------

#ifndef _MSC_VER
const int DirichletDiscrete_GridPrior::kAlphaFieldNumber;
#endif  // !_MSC_VER

DirichletDiscrete_GridPrior::DirichletDiscrete_GridPrior()
  : ::google::protobuf::Message() {
  SharedCtor();
}

void DirichletDiscrete_GridPrior::InitAsDefaultInstance() {
}

DirichletDiscrete_GridPrior::DirichletDiscrete_GridPrior(const DirichletDiscrete_GridPrior& from)
  : ::google::protobuf::Message() {
  SharedCtor();
  MergeFrom(from);
}

void DirichletDiscrete_GridPrior::SharedCtor() {
  _cached_size_ = 0;
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}

DirichletDiscrete_GridPrior::~DirichletDiscrete_GridPrior() {
  SharedDtor();
}

void DirichletDiscrete_GridPrior::SharedDtor() {
  if (this != default_instance_) {
  }
}

void DirichletDiscrete_GridPrior::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* DirichletDiscrete_GridPrior::descriptor() {
  protobuf_AssignDescriptorsOnce();
  return DirichletDiscrete_GridPrior_descriptor_;
}

const DirichletDiscrete_GridPrior& DirichletDiscrete_GridPrior::default_instance() {
  if (default_instance_ == NULL) protobuf_AddDesc_distributions_2fio_2fschema_2eproto();  return *default_instance_;
}

DirichletDiscrete_GridPrior* DirichletDiscrete_GridPrior::default_instance_ = NULL;

DirichletDiscrete_GridPrior* DirichletDiscrete_GridPrior::New() const {
  return new DirichletDiscrete_GridPrior;
}

void DirichletDiscrete_GridPrior::Clear() {
  alpha_.Clear();
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
  mutable_unknown_fields()->Clear();
}

bool DirichletDiscrete_GridPrior::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!(EXPRESSION)) return false
  ::google::protobuf::uint32 tag;
  while ((tag = input->ReadTag()) != 0) {
    switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
      // repeated float alpha = 1;
      case 1: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_FIXED32) {
         parse_alpha:
          DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 1, 13, input, this->mutable_alpha())));
        } else if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag)
                   == ::google::protobuf::internal::WireFormatLite::
                      WIRETYPE_LENGTH_DELIMITED) {
          DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 input, this->mutable_alpha())));
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(13)) goto parse_alpha;
        if (input->ExpectAtEnd()) return true;
        break;
      }
      
      default: {
      handle_uninterpreted:
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
          return true;
        }
        DO_(::google::protobuf::internal::WireFormat::SkipField(
              input, tag, mutable_unknown_fields()));
        break;
      }
    }
  }
  return true;
#undef DO_
}

void DirichletDiscrete_GridPrior::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  // repeated float alpha = 1;
  for (int i = 0; i < this->alpha_size(); i++) {
    ::google::protobuf::internal::WireFormatLite::WriteFloat(
      1, this->alpha(i), output);
  }
  
  if (!unknown_fields().empty()) {
    ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
        unknown_fields(), output);
  }
}

::google::protobuf::uint8* DirichletDiscrete_GridPrior::SerializeWithCachedSizesToArray(
    ::google::protobuf::uint8* target) const {
  // repeated float alpha = 1;
  for (int i = 0; i < this->alpha_size(); i++) {
    target = ::google::protobuf::internal::WireFormatLite::
      WriteFloatToArray(1, this->alpha(i), target);
  }
  
  if (!unknown_fields().empty()) {
    target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
        unknown_fields(), target);
  }
  return target;
}

int DirichletDiscrete_GridPrior::ByteSize() const {
  int total_size = 0;
  
  // repeated float alpha = 1;
  {
    int data_size = 0;
    data_size = 4 * this->alpha_size();
    total_size += 1 * this->alpha_size() + data_size;
  }
  
  if (!unknown_fields().empty()) {
    total_size +=
      ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
        unknown_fields());
  }
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = total_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void DirichletDiscrete_GridPrior::MergeFrom(const ::google::protobuf::Message& from) {
  GOOGLE_CHECK_NE(&from, this);
  const DirichletDiscrete_GridPrior* source =
    ::google::protobuf::internal::dynamic_cast_if_available<const DirichletDiscrete_GridPrior*>(
      &from);
  if (source == NULL) {
    ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  } else {
    MergeFrom(*source);
  }
}

void DirichletDiscrete_GridPrior::MergeFrom(const DirichletDiscrete_GridPrior& from) {
  GOOGLE_CHECK_NE(&from, this);
  alpha_.MergeFrom(from.alpha_);
  mutable_unknown_fields()->MergeFrom(from.unknown_fields());
}

void DirichletDiscrete_GridPrior::CopyFrom(const ::google::protobuf::Message& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

void DirichletDiscrete_GridPrior::CopyFrom(const DirichletDiscrete_GridPrior& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool DirichletDiscrete_GridPrior::IsInitialized() const {
  
  return true;
}

void DirichletDiscrete_GridPrior::Swap(DirichletDiscrete_GridPrior* other) {
  if (other != this) {
    alpha_.Swap(&other->alpha_);
    std::swap(_has_bits_[0], other->_has_bits_[0]);
    _unknown_fields_.Swap(&other->_unknown_fields_);
    std::swap(_cached_size_, other->_cached_size_);
  }
}

::google::protobuf::Metadata DirichletDiscrete_GridPrior::GetMetadata() const {
  protobuf_AssignDescriptorsOnce();
  ::google::protobuf::Metadata metadata;
  metadata.descriptor = DirichletDiscrete_GridPrior_descriptor_;
  metadata.reflection = DirichletDiscrete_GridPrior_reflection_;
  return metadata;
}


// -------------------------------------------------------------------

#ifndef _MSC_VER
const int DirichletDiscrete_Group::kCountsFieldNumber;
#endif  // !_MSC_VER

DirichletDiscrete_Group::DirichletDiscrete_Group()
  : ::google::protobuf::Message() {
  SharedCtor();
}

void DirichletDiscrete_Group::InitAsDefaultInstance() {
}

DirichletDiscrete_Group::DirichletDiscrete_Group(const DirichletDiscrete_Group& from)
  : ::google::protobuf::Message() {
  SharedCtor();
  MergeFrom(from);
}

void DirichletDiscrete_Group::SharedCtor() {
  _cached_size_ = 0;
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}

DirichletDiscrete_Group::~DirichletDiscrete_Group() {
  SharedDtor();
}

void DirichletDiscrete_Group::SharedDtor() {
  if (this != default_instance_) {
  }
}

void DirichletDiscrete_Group::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* DirichletDiscrete_Group::descriptor() {
  protobuf_AssignDescriptorsOnce();
  return DirichletDiscrete_Group_descriptor_;
}

const DirichletDiscrete_Group& DirichletDiscrete_Group::default_instance() {
  if (default_instance_ == NULL) protobuf_AddDesc_distributions_2fio_2fschema_2eproto();  return *default_instance_;
}

DirichletDiscrete_Group* DirichletDiscrete_Group::default_instance_ = NULL;

DirichletDiscrete_Group* DirichletDiscrete_Group::New() const {
  return new DirichletDiscrete_Group;
}

void DirichletDiscrete_Group::Clear() {
  counts_.Clear();
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
  mutable_unknown_fields()->Clear();
}

bool DirichletDiscrete_Group::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!(EXPRESSION)) return false
  ::google::protobuf::uint32 tag;
  while ((tag = input->ReadTag()) != 0) {
    switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
      // repeated uint64 counts = 1;
      case 1: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
         parse_counts:
          DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
                   ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
                 1, 8, input, this->mutable_counts())));
        } else if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag)
                   == ::google::protobuf::internal::WireFormatLite::
                      WIRETYPE_LENGTH_DELIMITED) {
          DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
                   ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
                 input, this->mutable_counts())));
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(8)) goto parse_counts;
        if (input->ExpectAtEnd()) return true;
        break;
      }
      
      default: {
      handle_uninterpreted:
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
          return true;
        }
        DO_(::google::protobuf::internal::WireFormat::SkipField(
              input, tag, mutable_unknown_fields()));
        break;
      }
    }
  }
  return true;
#undef DO_
}

void DirichletDiscrete_Group::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  // repeated uint64 counts = 1;
  for (int i = 0; i < this->counts_size(); i++) {
    ::google::protobuf::internal::WireFormatLite::WriteUInt64(
      1, this->counts(i), output);
  }
  
  if (!unknown_fields().empty()) {
    ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
        unknown_fields(), output);
  }
}

::google::protobuf::uint8* DirichletDiscrete_Group::SerializeWithCachedSizesToArray(
    ::google::protobuf::uint8* target) const {
  // repeated uint64 counts = 1;
  for (int i = 0; i < this->counts_size(); i++) {
    target = ::google::protobuf::internal::WireFormatLite::
      WriteUInt64ToArray(1, this->counts(i), target);
  }
  
  if (!unknown_fields().empty()) {
    target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
        unknown_fields(), target);
  }
  return target;
}

int DirichletDiscrete_Group::ByteSize() const {
  int total_size = 0;
  
  // repeated uint64 counts = 1;
  {
    int data_size = 0;
    for (int i = 0; i < this->counts_size(); i++) {
      data_size += ::google::protobuf::internal::WireFormatLite::
        UInt64Size(this->counts(i));
    }
    total_size += 1 * this->counts_size() + data_size;
  }
  
  if (!unknown_fields().empty()) {
    total_size +=
      ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
        unknown_fields());
  }
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = total_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void DirichletDiscrete_Group::MergeFrom(const ::google::protobuf::Message& from) {
  GOOGLE_CHECK_NE(&from, this);
  const DirichletDiscrete_Group* source =
    ::google::protobuf::internal::dynamic_cast_if_available<const DirichletDiscrete_Group*>(
      &from);
  if (source == NULL) {
    ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  } else {
    MergeFrom(*source);
  }
}

void DirichletDiscrete_Group::MergeFrom(const DirichletDiscrete_Group& from) {
  GOOGLE_CHECK_NE(&from, this);
  counts_.MergeFrom(from.counts_);
  mutable_unknown_fields()->MergeFrom(from.unknown_fields());
}

void DirichletDiscrete_Group::CopyFrom(const ::google::protobuf::Message& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

void DirichletDiscrete_Group::CopyFrom(const DirichletDiscrete_Group& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool DirichletDiscrete_Group::IsInitialized() const {
  
  return true;
}

void DirichletDiscrete_Group::Swap(DirichletDiscrete_Group* other) {
  if (other != this) {
    counts_.Swap(&other->counts_);
    std::swap(_has_bits_[0], other->_has_bits_[0]);
    _unknown_fields_.Swap(&other->_unknown_fields_);
    std::swap(_cached_size_, other->_cached_size_);
  }
}

::google::protobuf::Metadata DirichletDiscrete_Group::GetMetadata() const {
  protobuf_AssignDescriptorsOnce();
  ::google::protobuf::Metadata metadata;
  metadata.descriptor = DirichletDiscrete_Group_descriptor_;
  metadata.reflection = DirichletDiscrete_Group_reflection_;
  return metadata;
}


// -------------------------------------------------------------------

#ifndef _MSC_VER
#endif  // !_MSC_VER

DirichletDiscrete::DirichletDiscrete()
  : ::google::protobuf::Message() {
  SharedCtor();
}

void DirichletDiscrete::InitAsDefaultInstance() {
}

DirichletDiscrete::DirichletDiscrete(const DirichletDiscrete& from)
  : ::google::protobuf::Message() {
  SharedCtor();
  MergeFrom(from);
}

void DirichletDiscrete::SharedCtor() {
  _cached_size_ = 0;
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}

DirichletDiscrete::~DirichletDiscrete() {
  SharedDtor();
}

void DirichletDiscrete::SharedDtor() {
  if (this != default_instance_) {
  }
}

void DirichletDiscrete::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* DirichletDiscrete::descriptor() {
  protobuf_AssignDescriptorsOnce();
  return DirichletDiscrete_descriptor_;
}

const DirichletDiscrete& DirichletDiscrete::default_instance() {
  if (default_instance_ == NULL) protobuf_AddDesc_distributions_2fio_2fschema_2eproto();  return *default_instance_;
}

DirichletDiscrete* DirichletDiscrete::default_instance_ = NULL;

DirichletDiscrete* DirichletDiscrete::New() const {
  return new DirichletDiscrete;
}

void DirichletDiscrete::Clear() {
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
  mutable_unknown_fields()->Clear();
}

bool DirichletDiscrete::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!(EXPRESSION)) return false
  ::google::protobuf::uint32 tag;
  while ((tag = input->ReadTag()) != 0) {
    if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
        ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
      return true;
    }
    DO_(::google::protobuf::internal::WireFormat::SkipField(
          input, tag, mutable_unknown_fields()));
  }
  return true;
#undef DO_
}

void DirichletDiscrete::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  if (!unknown_fields().empty()) {
    ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
        unknown_fields(), output);
  }
}

::google::protobuf::uint8* DirichletDiscrete::SerializeWithCachedSizesToArray(
    ::google::protobuf::uint8* target) const {
  if (!unknown_fields().empty()) {
    target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
        unknown_fields(), target);
  }
  return target;
}

int DirichletDiscrete::ByteSize() const {
  int total_size = 0;
  
  if (!unknown_fields().empty()) {
    total_size +=
      ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
        unknown_fields());
  }
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = total_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void DirichletDiscrete::MergeFrom(const ::google::protobuf::Message& from) {
  GOOGLE_CHECK_NE(&from, this);
  const DirichletDiscrete* source =
    ::google::protobuf::internal::dynamic_cast_if_available<const DirichletDiscrete*>(
      &from);
  if (source == NULL) {
    ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  } else {
    MergeFrom(*source);
  }
}

void DirichletDiscrete::MergeFrom(const DirichletDiscrete& from) {
  GOOGLE_CHECK_NE(&from, this);
  mutable_unknown_fields()->MergeFrom(from.unknown_fields());
}

void DirichletDiscrete::CopyFrom(const ::google::protobuf::Message& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

void DirichletDiscrete::CopyFrom(const DirichletDiscrete& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool DirichletDiscrete::IsInitialized() const {
  
  return true;
}

void DirichletDiscrete::Swap(DirichletDiscrete* other) {
  if (other != this) {
    _unknown_fields_.Swap(&other->_unknown_fields_);
    std::swap(_cached_size_, other->_cached_size_);
  }
}

::google::protobuf::Metadata DirichletDiscrete::GetMetadata() const {
  protobuf_AssignDescriptorsOnce();
  ::google::protobuf::Metadata metadata;
  metadata.descriptor = DirichletDiscrete_descriptor_;
  metadata.reflection = DirichletDiscrete_reflection_;
  return metadata;
}


// ===================================================================

#ifndef _MSC_VER
const int DirichletProcessDiscrete_Shared::kGammaFieldNumber;
const int DirichletProcessDiscrete_Shared::kAlphaFieldNumber;
const int DirichletProcessDiscrete_Shared::kValuesFieldNumber;
const int DirichletProcessDiscrete_Shared::kBetasFieldNumber;
const int DirichletProcessDiscrete_Shared::kCountsFieldNumber;
#endif  // !_MSC_VER

DirichletProcessDiscrete_Shared::DirichletProcessDiscrete_Shared()
  : ::google::protobuf::Message() {
  SharedCtor();
}

void DirichletProcessDiscrete_Shared::InitAsDefaultInstance() {
}

DirichletProcessDiscrete_Shared::DirichletProcessDiscrete_Shared(const DirichletProcessDiscrete_Shared& from)
  : ::google::protobuf::Message() {
  SharedCtor();
  MergeFrom(from);
}

void DirichletProcessDiscrete_Shared::SharedCtor() {
  _cached_size_ = 0;
  gamma_ = 0;
  alpha_ = 0;
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}

DirichletProcessDiscrete_Shared::~DirichletProcessDiscrete_Shared() {
  SharedDtor();
}

void DirichletProcessDiscrete_Shared::SharedDtor() {
  if (this != default_instance_) {
  }
}

void DirichletProcessDiscrete_Shared::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* DirichletProcessDiscrete_Shared::descriptor() {
  protobuf_AssignDescriptorsOnce();
  return DirichletProcessDiscrete_Shared_descriptor_;
}

const DirichletProcessDiscrete_Shared& DirichletProcessDiscrete_Shared::default_instance() {
  if (default_instance_ == NULL) protobuf_AddDesc_distributions_2fio_2fschema_2eproto();  return *default_instance_;
}

DirichletProcessDiscrete_Shared* DirichletProcessDiscrete_Shared::default_instance_ = NULL;

DirichletProcessDiscrete_Shared* DirichletProcessDiscrete_Shared::New() const {
  return new DirichletProcessDiscrete_Shared;
}

void DirichletProcessDiscrete_Shared::Clear() {
  if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    gamma_ = 0;
    alpha_ = 0;
  }
  values_.Clear();
  betas_.Clear();
  counts_.Clear();
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
  mutable_unknown_fields()->Clear();
}

bool DirichletProcessDiscrete_Shared::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!(EXPRESSION)) return false
  ::google::protobuf::uint32 tag;
  while ((tag = input->ReadTag()) != 0) {
    switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
      // required float gamma = 1;
      case 1: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_FIXED32) {
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 input, &gamma_)));
          set_has_gamma();
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(21)) goto parse_alpha;
        break;
      }
      
      // required float alpha = 2;
      case 2: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_FIXED32) {
         parse_alpha:
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 input, &alpha_)));
          set_has_alpha();
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(24)) goto parse_values;
        break;
      }
      
      // repeated uint32 values = 3;
      case 3: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
         parse_values:
          DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
                   ::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
                 1, 24, input, this->mutable_values())));
        } else if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag)
                   == ::google::protobuf::internal::WireFormatLite::
                      WIRETYPE_LENGTH_DELIMITED) {
          DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
                   ::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
                 input, this->mutable_values())));
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(24)) goto parse_values;
        if (input->ExpectTag(37)) goto parse_betas;
        break;
      }
      
      // repeated float betas = 4;
      case 4: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_FIXED32) {
         parse_betas:
          DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 1, 37, input, this->mutable_betas())));
        } else if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag)
                   == ::google::protobuf::internal::WireFormatLite::
                      WIRETYPE_LENGTH_DELIMITED) {
          DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 input, this->mutable_betas())));
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(37)) goto parse_betas;
        if (input->ExpectTag(40)) goto parse_counts;
        break;
      }
      
      // repeated uint64 counts = 5;
      case 5: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
         parse_counts:
          DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
                   ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
                 1, 40, input, this->mutable_counts())));
        } else if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag)
                   == ::google::protobuf::internal::WireFormatLite::
                      WIRETYPE_LENGTH_DELIMITED) {
          DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
                   ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
                 input, this->mutable_counts())));
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(40)) goto parse_counts;
        if (input->ExpectAtEnd()) return true;
        break;
      }
      
      default: {
      handle_uninterpreted:
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
          return true;
        }
        DO_(::google::protobuf::internal::WireFormat::SkipField(
              input, tag, mutable_unknown_fields()));
        break;
      }
    }
  }
  return true;
#undef DO_
}

void DirichletProcessDiscrete_Shared::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  // required float gamma = 1;
  if (has_gamma()) {
    ::google::protobuf::internal::WireFormatLite::WriteFloat(1, this->gamma(), output);
  }
  
  // required float alpha = 2;
  if (has_alpha()) {
    ::google::protobuf::internal::WireFormatLite::WriteFloat(2, this->alpha(), output);
  }
  
  // repeated uint32 values = 3;
  for (int i = 0; i < this->values_size(); i++) {
    ::google::protobuf::internal::WireFormatLite::WriteUInt32(
      3, this->values(i), output);
  }
  
  // repeated float betas = 4;
  for (int i = 0; i < this->betas_size(); i++) {
    ::google::protobuf::internal::WireFormatLite::WriteFloat(
      4, this->betas(i), output);
  }
  
  // repeated uint64 counts = 5;
  for (int i = 0; i < this->counts_size(); i++) {
    ::google::protobuf::internal::WireFormatLite::WriteUInt64(
      5, this->counts(i), output);
  }
  
  if (!unknown_fields().empty()) {
    ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
        unknown_fields(), output);
  }
}

::google::protobuf::uint8* DirichletProcessDiscrete_Shared::SerializeWithCachedSizesToArray(
    ::google::protobuf::uint8* target) const {
  // required float gamma = 1;
  if (has_gamma()) {
    target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(1, this->gamma(), target);
  }
  
  // required float alpha = 2;
  if (has_alpha()) {
    target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(2, this->alpha(), target);
  }
  
  // repeated uint32 values = 3;
  for (int i = 0; i < this->values_size(); i++) {
    target = ::google::protobuf::internal::WireFormatLite::
      WriteUInt32ToArray(3, this->values(i), target);
  }
  
  // repeated float betas = 4;
  for (int i = 0; i < this->betas_size(); i++) {
    target = ::google::protobuf::internal::WireFormatLite::
      WriteFloatToArray(4, this->betas(i), target);
  }
  
  // repeated uint64 counts = 5;
  for (int i = 0; i < this->counts_size(); i++) {
    target = ::google::protobuf::internal::WireFormatLite::
      WriteUInt64ToArray(5, this->counts(i), target);
  }
  
  if (!unknown_fields().empty()) {
    target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
        unknown_fields(), target);
  }
  return target;
}

int DirichletProcessDiscrete_Shared::ByteSize() const {
  int total_size = 0;
  
  if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    // required float gamma = 1;
    if (has_gamma()) {
      total_size += 1 + 4;
    }
    
    // required float alpha = 2;
    if (has_alpha()) {
      total_size += 1 + 4;
    }
    
  }
  // repeated uint32 values = 3;
  {
    int data_size = 0;
    for (int i = 0; i < this->values_size(); i++) {
      data_size += ::google::protobuf::internal::WireFormatLite::
        UInt32Size(this->values(i));
    }
    total_size += 1 * this->values_size() + data_size;
  }
  
  // repeated float betas = 4;
  {
    int data_size = 0;
    data_size = 4 * this->betas_size();
    total_size += 1 * this->betas_size() + data_size;
  }
  
  // repeated uint64 counts = 5;
  {
    int data_size = 0;
    for (int i = 0; i < this->counts_size(); i++) {
      data_size += ::google::protobuf::internal::WireFormatLite::
        UInt64Size(this->counts(i));
    }
    total_size += 1 * this->counts_size() + data_size;
  }
  
  if (!unknown_fields().empty()) {
    total_size +=
      ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
        unknown_fields());
  }
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = total_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void DirichletProcessDiscrete_Shared::MergeFrom(const ::google::protobuf::Message& from) {
  GOOGLE_CHECK_NE(&from, this);
  const DirichletProcessDiscrete_Shared* source =
    ::google::protobuf::internal::dynamic_cast_if_available<const DirichletProcessDiscrete_Shared*>(
      &from);
  if (source == NULL) {
    ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  } else {
    MergeFrom(*source);
  }
}

void DirichletProcessDiscrete_Shared::MergeFrom(const DirichletProcessDiscrete_Shared& from) {
  GOOGLE_CHECK_NE(&from, this);
  values_.MergeFrom(from.values_);
  betas_.MergeFrom(from.betas_);
  counts_.MergeFrom(from.counts_);
  if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    if (from.has_gamma()) {
      set_gamma(from.gamma());
    }
    if (from.has_alpha()) {
      set_alpha(from.alpha());
    }
  }
  mutable_unknown_fields()->MergeFrom(from.unknown_fields());
}

void DirichletProcessDiscrete_Shared::CopyFrom(const ::google::protobuf::Message& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

void DirichletProcessDiscrete_Shared::CopyFrom(const DirichletProcessDiscrete_Shared& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool DirichletProcessDiscrete_Shared::IsInitialized() const {
  if ((_has_bits_[0] & 0x00000003) != 0x00000003) return false;
  
  return true;
}

void DirichletProcessDiscrete_Shared::Swap(DirichletProcessDiscrete_Shared* other) {
  if (other != this) {
    std::swap(gamma_, other->gamma_);
    std::swap(alpha_, other->alpha_);
    values_.Swap(&other->values_);
    betas_.Swap(&other->betas_);
    counts_.Swap(&other->counts_);
    std::swap(_has_bits_[0], other->_has_bits_[0]);
    _unknown_fields_.Swap(&other->_unknown_fields_);
    std::swap(_cached_size_, other->_cached_size_);
  }
}

::google::protobuf::Metadata DirichletProcessDiscrete_Shared::GetMetadata() const {
  protobuf_AssignDescriptorsOnce();
  ::google::protobuf::Metadata metadata;
  metadata.descriptor = DirichletProcessDiscrete_Shared_descriptor_;
  metadata.reflection = DirichletProcessDiscrete_Shared_reflection_;
  return metadata;
}


// -------------------------------------------------------------------

#ifndef _MSC_VER
const int DirichletProcessDiscrete_GridPrior::kGammaFieldNumber;
const int DirichletProcessDiscrete_GridPrior::kAlphaFieldNumber;
#endif  // !_MSC_VER

DirichletProcessDiscrete_GridPrior::DirichletProcessDiscrete_GridPrior()
  : ::google::protobuf::Message() {
  SharedCtor();
}

void DirichletProcessDiscrete_GridPrior::InitAsDefaultInstance() {
}

DirichletProcessDiscrete_GridPrior::DirichletProcessDiscrete_GridPrior(const DirichletProcessDiscrete_GridPrior& from)
  : ::google::protobuf::Message() {
  SharedCtor();
  MergeFrom(from);
}

void DirichletProcessDiscrete_GridPrior::SharedCtor() {
  _cached_size_ = 0;
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}

DirichletProcessDiscrete_GridPrior::~DirichletProcessDiscrete_GridPrior() {
  SharedDtor();
}

void DirichletProcessDiscrete_GridPrior::SharedDtor() {
  if (this != default_instance_) {
  }
}

void DirichletProcessDiscrete_GridPrior::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* DirichletProcessDiscrete_GridPrior::descriptor() {
  protobuf_AssignDescriptorsOnce();
  return DirichletProcessDiscrete_GridPrior_descriptor_;
}

const DirichletProcessDiscrete_GridPrior& DirichletProcessDiscrete_GridPrior::default_instance() {
  if (default_instance_ == NULL) protobuf_AddDesc_distributions_2fio_2fschema_2eproto();  return *default_instance_;
}

DirichletProcessDiscrete_GridPrior* DirichletProcessDiscrete_GridPrior::default_instance_ = NULL;

DirichletProcessDiscrete_GridPrior* DirichletProcessDiscrete_GridPrior::New() const {
  return new DirichletProcessDiscrete_GridPrior;
}

void DirichletProcessDiscrete_GridPrior::Clear() {
  gamma_.Clear();
  alpha_.Clear();
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
  mutable_unknown_fields()->Clear();
}

bool DirichletProcessDiscrete_GridPrior::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!(EXPRESSION)) return false
  ::google::protobuf::uint32 tag;
  while ((tag = input->ReadTag()) != 0) {
    switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
      // repeated float gamma = 1;
      case 1: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_FIXED32) {
         parse_gamma:
          DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 1, 13, input, this->mutable_gamma())));
        } else if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag)
                   == ::google::protobuf::internal::WireFormatLite::
                      WIRETYPE_LENGTH_DELIMITED) {
          DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 input, this->mutable_gamma())));
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(13)) goto parse_gamma;
        if (input->ExpectTag(21)) goto parse_alpha;
        break;
      }
      
      // repeated float alpha = 2;
      case 2: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_FIXED32) {
         parse_alpha:
          DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 1, 21, input, this->mutable_alpha())));
        } else if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag)
                   == ::google::protobuf::internal::WireFormatLite::
                      WIRETYPE_LENGTH_DELIMITED) {
          DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 input, this->mutable_alpha())));
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(21)) goto parse_alpha;
        if (input->ExpectAtEnd()) return true;
        break;
      }
      
      default: {
      handle_uninterpreted:
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
          return true;
        }
        DO_(::google::protobuf::internal::WireFormat::SkipField(
              input, tag, mutable_unknown_fields()));
        break;
      }
    }
  }
  return true;
#undef DO_
}

void DirichletProcessDiscrete_GridPrior::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  // repeated float gamma = 1;
  for (int i = 0; i < this->gamma_size(); i++) {
    ::google::protobuf::internal::WireFormatLite::WriteFloat(
      1, this->gamma(i), output);
  }
  
  // repeated float alpha = 2;
  for (int i = 0; i < this->alpha_size(); i++) {
    ::google::protobuf::internal::WireFormatLite::WriteFloat(
      2, this->alpha(i), output);
  }
  
  if (!unknown_fields().empty()) {
    ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
        unknown_fields(), output);
  }
}

::google::protobuf::uint8* DirichletProcessDiscrete_GridPrior::SerializeWithCachedSizesToArray(
    ::google::protobuf::uint8* target) const {
  // repeated float gamma = 1;
  for (int i = 0; i < this->gamma_size(); i++) {
    target = ::google::protobuf::internal::WireFormatLite::
      WriteFloatToArray(1, this->gamma(i), target);
  }
  
  // repeated float alpha = 2;
  for (int i = 0; i < this->alpha_size(); i++) {
    target = ::google::protobuf::internal::WireFormatLite::
      WriteFloatToArray(2, this->alpha(i), target);
  }
  
  if (!unknown_fields().empty()) {
    target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
        unknown_fields(), target);
  }
  return target;
}

int DirichletProcessDiscrete_GridPrior::ByteSize() const {
  int total_size = 0;
  
  // repeated float gamma = 1;
  {
    int data_size = 0;
    data_size = 4 * this->gamma_size();
    total_size += 1 * this->gamma_size() + data_size;
  }
  
  // repeated float alpha = 2;
  {
    int data_size = 0;
    data_size = 4 * this->alpha_size();
    total_size += 1 * this->alpha_size() + data_size;
  }
  
  if (!unknown_fields().empty()) {
    total_size +=
      ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
        unknown_fields());
  }
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = total_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void DirichletProcessDiscrete_GridPrior::MergeFrom(const ::google::protobuf::Message& from) {
  GOOGLE_CHECK_NE(&from, this);
  const DirichletProcessDiscrete_GridPrior* source =
    ::google::protobuf::internal::dynamic_cast_if_available<const DirichletProcessDiscrete_GridPrior*>(
      &from);
  if (source == NULL) {
    ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  } else {
    MergeFrom(*source);
  }
}

void DirichletProcessDiscrete_GridPrior::MergeFrom(const DirichletProcessDiscrete_GridPrior& from) {
  GOOGLE_CHECK_NE(&from, this);
  gamma_.MergeFrom(from.gamma_);
  alpha_.MergeFrom(from.alpha_);
  mutable_unknown_fields()->MergeFrom(from.unknown_fields());
}

void DirichletProcessDiscrete_GridPrior::CopyFrom(const ::google::protobuf::Message& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

void DirichletProcessDiscrete_GridPrior::CopyFrom(const DirichletProcessDiscrete_GridPrior& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool DirichletProcessDiscrete_GridPrior::IsInitialized() const {
  
  return true;
}

void DirichletProcessDiscrete_GridPrior::Swap(DirichletProcessDiscrete_GridPrior* other) {
  if (other != this) {
    gamma_.Swap(&other->gamma_);
    alpha_.Swap(&other->alpha_);
    std::swap(_has_bits_[0], other->_has_bits_[0]);
    _unknown_fields_.Swap(&other->_unknown_fields_);
    std::swap(_cached_size_, other->_cached_size_);
  }
}

::google::protobuf::Metadata DirichletProcessDiscrete_GridPrior::GetMetadata() const {
  protobuf_AssignDescriptorsOnce();
  ::google::protobuf::Metadata metadata;
  metadata.descriptor = DirichletProcessDiscrete_GridPrior_descriptor_;
  metadata.reflection = DirichletProcessDiscrete_GridPrior_reflection_;
  return metadata;
}


// -------------------------------------------------------------------

#ifndef _MSC_VER
const int DirichletProcessDiscrete_Group::kKeysFieldNumber;
const int DirichletProcessDiscrete_Group::kValuesFieldNumber;
#endif  // !_MSC_VER

DirichletProcessDiscrete_Group::DirichletProcessDiscrete_Group()
  : ::google::protobuf::Message() {
  SharedCtor();
}

void DirichletProcessDiscrete_Group::InitAsDefaultInstance() {
}

DirichletProcessDiscrete_Group::DirichletProcessDiscrete_Group(const DirichletProcessDiscrete_Group& from)
  : ::google::protobuf::Message() {
  SharedCtor();
  MergeFrom(from);
}

void DirichletProcessDiscrete_Group::SharedCtor() {
  _cached_size_ = 0;
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}

DirichletProcessDiscrete_Group::~DirichletProcessDiscrete_Group() {
  SharedDtor();
}

void DirichletProcessDiscrete_Group::SharedDtor() {
  if (this != default_instance_) {
  }
}

void DirichletProcessDiscrete_Group::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* DirichletProcessDiscrete_Group::descriptor() {
  protobuf_AssignDescriptorsOnce();
  return DirichletProcessDiscrete_Group_descriptor_;
}

const DirichletProcessDiscrete_Group& DirichletProcessDiscrete_Group::default_instance() {
  if (default_instance_ == NULL) protobuf_AddDesc_distributions_2fio_2fschema_2eproto();  return *default_instance_;
}

DirichletProcessDiscrete_Group* DirichletProcessDiscrete_Group::default_instance_ = NULL;

DirichletProcessDiscrete_Group* DirichletProcessDiscrete_Group::New() const {
  return new DirichletProcessDiscrete_Group;
}

void DirichletProcessDiscrete_Group::Clear() {
  keys_.Clear();
  values_.Clear();
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
  mutable_unknown_fields()->Clear();
}

bool DirichletProcessDiscrete_Group::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!(EXPRESSION)) return false
  ::google::protobuf::uint32 tag;
  while ((tag = input->ReadTag()) != 0) {
    switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
      // repeated uint32 keys = 1;
      case 1: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
         parse_keys:
          DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
                   ::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
                 1, 8, input, this->mutable_keys())));
        } else if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag)
                   == ::google::protobuf::internal::WireFormatLite::
                      WIRETYPE_LENGTH_DELIMITED) {
          DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
                   ::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
                 input, this->mutable_keys())));
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(8)) goto parse_keys;
        if (input->ExpectTag(16)) goto parse_values;
        break;
      }
      
      // repeated uint64 values = 2;
      case 2: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
         parse_values:
          DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
                   ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
                 1, 16, input, this->mutable_values())));
        } else if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag)
                   == ::google::protobuf::internal::WireFormatLite::
                      WIRETYPE_LENGTH_DELIMITED) {
          DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
                   ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
                 input, this->mutable_values())));
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(16)) goto parse_values;
        if (input->ExpectAtEnd()) return true;
        break;
      }
      
      default: {
      handle_uninterpreted:
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
          return true;
        }
        DO_(::google::protobuf::internal::WireFormat::SkipField(
              input, tag, mutable_unknown_fields()));
        break;
      }
    }
  }
  return true;
#undef DO_
}

void DirichletProcessDiscrete_Group::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  // repeated uint32 keys = 1;
  for (int i = 0; i < this->keys_size(); i++) {
    ::google::protobuf::internal::WireFormatLite::WriteUInt32(
      1, this->keys(i), output);
  }
  
  // repeated uint64 values = 2;
  for (int i = 0; i < this->values_size(); i++) {
    ::google::protobuf::internal::WireFormatLite::WriteUInt64(
      2, this->values(i), output);
  }
  
  if (!unknown_fields().empty()) {
    ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
        unknown_fields(), output);
  }
}

::google::protobuf::uint8* DirichletProcessDiscrete_Group::SerializeWithCachedSizesToArray(
    ::google::protobuf::uint8* target) const {
  // repeated uint32 keys = 1;
  for (int i = 0; i < this->keys_size(); i++) {
    target = ::google::protobuf::internal::WireFormatLite::
      WriteUInt32ToArray(1, this->keys(i), target);
  }
  
  // repeated uint64 values = 2;
  for (int i = 0; i < this->values_size(); i++) {
    target = ::google::protobuf::internal::WireFormatLite::
      WriteUInt64ToArray(2, this->values(i), target);
  }
  
  if (!unknown_fields().empty()) {
    target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
        unknown_fields(), target);
  }
  return target;
}

int DirichletProcessDiscrete_Group::ByteSize() const {
  int total_size = 0;
  
  // repeated uint32 keys = 1;
  {
    int data_size = 0;
    for (int i = 0; i < this->keys_size(); i++) {
      data_size += ::google::protobuf::internal::WireFormatLite::
        UInt32Size(this->keys(i));
    }
    total_size += 1 * this->keys_size() + data_size;
  }
  
  // repeated uint64 values = 2;
  {
    int data_size = 0;
    for (int i = 0; i < this->values_size(); i++) {
      data_size += ::google::protobuf::internal::WireFormatLite::
        UInt64Size(this->values(i));
    }
    total_size += 1 * this->values_size() + data_size;
  }
  
  if (!unknown_fields().empty()) {
    total_size +=
      ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
        unknown_fields());
  }
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = total_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void DirichletProcessDiscrete_Group::MergeFrom(const ::google::protobuf::Message& from) {
  GOOGLE_CHECK_NE(&from, this);
  const DirichletProcessDiscrete_Group* source =
    ::google::protobuf::internal::dynamic_cast_if_available<const DirichletProcessDiscrete_Group*>(
      &from);
  if (source == NULL) {
    ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  } else {
    MergeFrom(*source);
  }
}

void DirichletProcessDiscrete_Group::MergeFrom(const DirichletProcessDiscrete_Group& from) {
  GOOGLE_CHECK_NE(&from, this);
  keys_.MergeFrom(from.keys_);
  values_.MergeFrom(from.values_);
  mutable_unknown_fields()->MergeFrom(from.unknown_fields());
}

void DirichletProcessDiscrete_Group::CopyFrom(const ::google::protobuf::Message& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

void DirichletProcessDiscrete_Group::CopyFrom(const DirichletProcessDiscrete_Group& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool DirichletProcessDiscrete_Group::IsInitialized() const {
  
  return true;
}

void DirichletProcessDiscrete_Group::Swap(DirichletProcessDiscrete_Group* other) {
  if (other != this) {
    keys_.Swap(&other->keys_);
    values_.Swap(&other->values_);
    std::swap(_has_bits_[0], other->_has_bits_[0]);
    _unknown_fields_.Swap(&other->_unknown_fields_);
    std::swap(_cached_size_, other->_cached_size_);
  }
}

::google::protobuf::Metadata DirichletProcessDiscrete_Group::GetMetadata() const {
  protobuf_AssignDescriptorsOnce();
  ::google::protobuf::Metadata metadata;
  metadata.descriptor = DirichletProcessDiscrete_Group_descriptor_;
  metadata.reflection = DirichletProcessDiscrete_Group_reflection_;
  return metadata;
}


// -------------------------------------------------------------------

#ifndef _MSC_VER
#endif  // !_MSC_VER

DirichletProcessDiscrete::DirichletProcessDiscrete()
  : ::google::protobuf::Message() {
  SharedCtor();
}

void DirichletProcessDiscrete::InitAsDefaultInstance() {
}

DirichletProcessDiscrete::DirichletProcessDiscrete(const DirichletProcessDiscrete& from)
  : ::google::protobuf::Message() {
  SharedCtor();
  MergeFrom(from);
}

void DirichletProcessDiscrete::SharedCtor() {
  _cached_size_ = 0;
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}

DirichletProcessDiscrete::~DirichletProcessDiscrete() {
  SharedDtor();
}

void DirichletProcessDiscrete::SharedDtor() {
  if (this != default_instance_) {
  }
}

void DirichletProcessDiscrete::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* DirichletProcessDiscrete::descriptor() {
  protobuf_AssignDescriptorsOnce();
  return DirichletProcessDiscrete_descriptor_;
}

const DirichletProcessDiscrete& DirichletProcessDiscrete::default_instance() {
  if (default_instance_ == NULL) protobuf_AddDesc_distributions_2fio_2fschema_2eproto();  return *default_instance_;
}

DirichletProcessDiscrete* DirichletProcessDiscrete::default_instance_ = NULL;

DirichletProcessDiscrete* DirichletProcessDiscrete::New() const {
  return new DirichletProcessDiscrete;
}

void DirichletProcessDiscrete::Clear() {
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
  mutable_unknown_fields()->Clear();
}

bool DirichletProcessDiscrete::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!(EXPRESSION)) return false
  ::google::protobuf::uint32 tag;
  while ((tag = input->ReadTag()) != 0) {
    if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
        ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
      return true;
    }
    DO_(::google::protobuf::internal::WireFormat::SkipField(
          input, tag, mutable_unknown_fields()));
  }
  return true;
#undef DO_
}

void DirichletProcessDiscrete::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  if (!unknown_fields().empty()) {
    ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
        unknown_fields(), output);
  }
}

::google::protobuf::uint8* DirichletProcessDiscrete::SerializeWithCachedSizesToArray(
    ::google::protobuf::uint8* target) const {
  if (!unknown_fields().empty()) {
    target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
        unknown_fields(), target);
  }
  return target;
}

int DirichletProcessDiscrete::ByteSize() const {
  int total_size = 0;
  
  if (!unknown_fields().empty()) {
    total_size +=
      ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
        unknown_fields());
  }
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = total_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void DirichletProcessDiscrete::MergeFrom(const ::google::protobuf::Message& from) {
  GOOGLE_CHECK_NE(&from, this);
  const DirichletProcessDiscrete* source =
    ::google::protobuf::internal::dynamic_cast_if_available<const DirichletProcessDiscrete*>(
      &from);
  if (source == NULL) {
    ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  } else {
    MergeFrom(*source);
  }
}

void DirichletProcessDiscrete::MergeFrom(const DirichletProcessDiscrete& from) {
  GOOGLE_CHECK_NE(&from, this);
  mutable_unknown_fields()->MergeFrom(from.unknown_fields());
}

void DirichletProcessDiscrete::CopyFrom(const ::google::protobuf::Message& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

void DirichletProcessDiscrete::CopyFrom(const DirichletProcessDiscrete& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool DirichletProcessDiscrete::IsInitialized() const {
  
  return true;
}

void DirichletProcessDiscrete::Swap(DirichletProcessDiscrete* other) {
  if (other != this) {
    _unknown_fields_.Swap(&other->_unknown_fields_);
    std::swap(_cached_size_, other->_cached_size_);
  }
}

::google::protobuf::Metadata DirichletProcessDiscrete::GetMetadata() const {
  protobuf_AssignDescriptorsOnce();
  ::google::protobuf::Metadata metadata;
  metadata.descriptor = DirichletProcessDiscrete_descriptor_;
  metadata.reflection = DirichletProcessDiscrete_reflection_;
  return metadata;
}


// ===================================================================

#ifndef _MSC_VER
const int PitmanYorProcessDiscrete_Shared::kAlphaFieldNumber;
const int PitmanYorProcessDiscrete_Shared::kDFieldNumber;
const int PitmanYorProcessDiscrete_Shared::kCountsFieldNumber;
#endif  // !_MSC_VER

PitmanYorProcessDiscrete_Shared::PitmanYorProcessDiscrete_Shared()
  : ::google::protobuf::Message() {
  SharedCtor();
}

void PitmanYorProcessDiscrete_Shared::InitAsDefaultInstance() {
}

PitmanYorProcessDiscrete_Shared::PitmanYorProcessDiscrete_Shared(const PitmanYorProcessDiscrete_Shared& from)
  : ::google::protobuf::Message() {
  SharedCtor();
  MergeFrom(from);
}

void PitmanYorProcessDiscrete_Shared::SharedCtor() {
  _cached_size_ = 0;
  alpha_ = 0;
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}

PitmanYorProcessDiscrete_Shared::~PitmanYorProcessDiscrete_Shared() {
  SharedDtor();
}

void PitmanYorProcessDiscrete_Shared::SharedDtor() {
  if (this != default_instance_) {
  }
}

void PitmanYorProcessDiscrete_Shared::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* PitmanYorProcessDiscrete_Shared::descriptor() {
  protobuf_AssignDescriptorsOnce();
  return PitmanYorProcessDiscrete_Shared_descriptor_;
}

const PitmanYorProcessDiscrete_Shared& PitmanYorProcessDiscrete_Shared::default_instance() {
  if (default_instance_ == NULL) protobuf_AddDesc_distributions_2fio_2fschema_2eproto();  return *default_instance_;
}

PitmanYorProcessDiscrete_Shared* PitmanYorProcessDiscrete_Shared::default_instance_ = NULL;

PitmanYorProcessDiscrete_Shared* PitmanYorProcessDiscrete_Shared::New() const {
  return new PitmanYorProcessDiscrete_Shared;
}

void PitmanYorProcessDiscrete_Shared::Clear() {
  if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    alpha_ = 0;
  }
  d_.Clear();
  counts_.Clear();
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
  mutable_unknown_fields()->Clear();
}

bool PitmanYorProcessDiscrete_Shared::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!(EXPRESSION)) return false
  ::google::protobuf::uint32 tag;
  while ((tag = input->ReadTag()) != 0) {
    switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
      // required float alpha = 1;
      case 1: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_FIXED32) {
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 input, &alpha_)));
          set_has_alpha();
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(21)) goto parse_d;
        break;
      }
      
      // repeated float d = 2;
      case 2: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_FIXED32) {
         parse_d:
          DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 1, 21, input, this->mutable_d())));
        } else if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag)
                   == ::google::protobuf::internal::WireFormatLite::
                      WIRETYPE_LENGTH_DELIMITED) {
          DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 input, this->mutable_d())));
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(21)) goto parse_d;
        if (input->ExpectTag(24)) goto parse_counts;
        break;
      }
      
      // repeated uint64 counts = 3;
      case 3: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
         parse_counts:
          DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
                   ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
                 1, 24, input, this->mutable_counts())));
        } else if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag)
                   == ::google::protobuf::internal::WireFormatLite::
                      WIRETYPE_LENGTH_DELIMITED) {
          DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
                   ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
                 input, this->mutable_counts())));
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(24)) goto parse_counts;
        if (input->ExpectAtEnd()) return true;
        break;
      }
      
      default: {
      handle_uninterpreted:
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
          return true;
        }
        DO_(::google::protobuf::internal::WireFormat::SkipField(
              input, tag, mutable_unknown_fields()));
        break;
      }
    }
  }
  return true;
#undef DO_
}

void PitmanYorProcessDiscrete_Shared::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  // required float alpha = 1;
  if (has_alpha()) {
    ::google::protobuf::internal::WireFormatLite::WriteFloat(1, this->alpha(), output);
  }
  
  // repeated float d = 2;
  for (int i = 0; i < this->d_size(); i++) {
    ::google::protobuf::internal::WireFormatLite::WriteFloat(
      2, this->d(i), output);
  }
  
  // repeated uint64 counts = 3;
  for (int i = 0; i < this->counts_size(); i++) {
    ::google::protobuf::internal::WireFormatLite::WriteUInt64(
      3, this->counts(i), output);
  }
  
  if (!unknown_fields().empty()) {
    ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
        unknown_fields(), output);
  }
}

::google::protobuf::uint8* PitmanYorProcessDiscrete_Shared::SerializeWithCachedSizesToArray(
    ::google::protobuf::uint8* target) const {
  // required float alpha = 1;
  if (has_alpha()) {
    target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(1, this->alpha(), target);
  }
  
  // repeated float d = 2;
  for (int i = 0; i < this->d_size(); i++) {
    target = ::google::protobuf::internal::WireFormatLite::
      WriteFloatToArray(2, this->d(i), target);
  }
  
  // repeated uint64 counts = 3;
  for (int i = 0; i < this->counts_size(); i++) {
    target = ::google::protobuf::internal::WireFormatLite::
      WriteUInt64ToArray(3, this->counts(i), target);
  }
  
  if (!unknown_fields().empty()) {
    target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
        unknown_fields(), target);
  }
  return target;
}

int PitmanYorProcessDiscrete_Shared::ByteSize() const {
  int total_size = 0;
  
  if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    // required float alpha = 1;
    if (has_alpha()) {
      total_size += 1 + 4;
    }
    
  }
  // repeated float d = 2;
  {
    int data_size = 0;
    data_size = 4 * this->d_size();
    total_size += 1 * this->d_size() + data_size;
  }
  
  // repeated uint64 counts = 3;
  {
    int data_size = 0;
    for (int i = 0; i < this->counts_size(); i++) {
      data_size += ::google::protobuf::internal::WireFormatLite::
        UInt64Size(this->counts(i));
    }
    total_size += 1 * this->counts_size() + data_size;
  }
  
  if (!unknown_fields().empty()) {
    total_size +=
      ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
        unknown_fields());
  }
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = total_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void PitmanYorProcessDiscrete_Shared::MergeFrom(const ::google::protobuf::Message& from) {
  GOOGLE_CHECK_NE(&from, this);
  const PitmanYorProcessDiscrete_Shared* source =
    ::google::protobuf::internal::dynamic_cast_if_available<const PitmanYorProcessDiscrete_Shared*>(
      &from);
  if (source == NULL) {
    ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  } else {
    MergeFrom(*source);
  }
}

void PitmanYorProcessDiscrete_Shared::MergeFrom(const PitmanYorProcessDiscrete_Shared& from) {
  GOOGLE_CHECK_NE(&from, this);
  d_.MergeFrom(from.d_);
  counts_.MergeFrom(from.counts_);
  if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    if (from.has_alpha()) {
      set_alpha(from.alpha());
    }
  }
  mutable_unknown_fields()->MergeFrom(from.unknown_fields());
}

void PitmanYorProcessDiscrete_Shared::CopyFrom(const ::google::protobuf::Message& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

void PitmanYorProcessDiscrete_Shared::CopyFrom(const PitmanYorProcessDiscrete_Shared& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool PitmanYorProcessDiscrete_Shared::IsInitialized() const {
  if ((_has_bits_[0] & 0x00000001) != 0x00000001) return false;
  
  return true;
}

void PitmanYorProcessDiscrete_Shared::Swap(PitmanYorProcessDiscrete_Shared* other) {
  if (other != this) {
    std::swap(alpha_, other->alpha_);
    d_.Swap(&other->d_);
    counts_.Swap(&other->counts_);
    std::swap(_has_bits_[0], other->_has_bits_[0]);
    _unknown_fields_.Swap(&other->_unknown_fields_);
    std::swap(_cached_size_, other->_cached_size_);
  }
}

::google::protobuf::Metadata PitmanYorProcessDiscrete_Shared::GetMetadata() const {
  protobuf_AssignDescriptorsOnce();
  ::google::protobuf::Metadata metadata;
  metadata.descriptor = PitmanYorProcessDiscrete_Shared_descriptor_;
  metadata.reflection = PitmanYorProcessDiscrete_Shared_reflection_;
  return metadata;
}


// -------------------------------------------------------------------

#ifndef _MSC_VER
const int PitmanYorProcessDiscrete_GridPrior::kAlphaDFieldNumber;
#endif  // !_MSC_VER

PitmanYorProcessDiscrete_GridPrior::PitmanYorProcessDiscrete_GridPrior()
  : ::google::protobuf::Message() {
  SharedCtor();
}

void PitmanYorProcessDiscrete_GridPrior::InitAsDefaultInstance() {
}

PitmanYorProcessDiscrete_GridPrior::PitmanYorProcessDiscrete_GridPrior(const PitmanYorProcessDiscrete_GridPrior& from)
  : ::google::protobuf::Message() {
  SharedCtor();
  MergeFrom(from);
}

void PitmanYorProcessDiscrete_GridPrior::SharedCtor() {
  _cached_size_ = 0;
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}

PitmanYorProcessDiscrete_GridPrior::~PitmanYorProcessDiscrete_GridPrior() {
  SharedDtor();
}

void PitmanYorProcessDiscrete_GridPrior::SharedDtor() {
  if (this != default_instance_) {
  }
}

void PitmanYorProcessDiscrete_GridPrior::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* PitmanYorProcessDiscrete_GridPrior::descriptor() {
  protobuf_AssignDescriptorsOnce();
  return PitmanYorProcessDiscrete_GridPrior_descriptor_;
}

const PitmanYorProcessDiscrete_GridPrior& PitmanYorProcessDiscrete_GridPrior::default_instance() {
  if (default_instance_ == NULL) protobuf_AddDesc_distributions_2fio_2fschema_2eproto();  return *default_instance_;
}

PitmanYorProcessDiscrete_GridPrior* PitmanYorProcessDiscrete_GridPrior::default_instance_ = NULL;

PitmanYorProcessDiscrete_GridPrior* PitmanYorProcessDiscrete_GridPrior::New() const {
  return new PitmanYorProcessDiscrete_GridPrior;
}

void PitmanYorProcessDiscrete_GridPrior::Clear() {
  alpha_d_.Clear();
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
  mutable_unknown_fields()->Clear();
}

bool PitmanYorProcessDiscrete_GridPrior::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!(EXPRESSION)) return false
  ::google::protobuf::uint32 tag;
  while ((tag = input->ReadTag()) != 0) {
    switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
      // repeated .protobuf.distributions.Clustering.PitmanYor alpha_d = 1;
      case 1: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED) {
         parse_alpha_d:
          DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
                input, add_alpha_d()));
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(10)) goto parse_alpha_d;
        if (input->ExpectAtEnd()) return true;
        break;
      }
      
      default: {
      handle_uninterpreted:
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
          return true;
        }
        DO_(::google::protobuf::internal::WireFormat::SkipField(
              input, tag, mutable_unknown_fields()));
        break;
      }
    }
  }
  return true;
#undef DO_
}

void PitmanYorProcessDiscrete_GridPrior::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  // repeated .protobuf.distributions.Clustering.PitmanYor alpha_d = 1;
  for (int i = 0; i < this->alpha_d_size(); i++) {
    ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
      1, this->alpha_d(i), output);
  }
  
  if (!unknown_fields().empty()) {
    ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
        unknown_fields(), output);
  }
}

::google::protobuf::uint8* PitmanYorProcessDiscrete_GridPrior::SerializeWithCachedSizesToArray(
    ::google::protobuf::uint8* target) const {
  // repeated .protobuf.distributions.Clustering.PitmanYor alpha_d = 1;
  for (int i = 0; i < this->alpha_d_size(); i++) {
    target = ::google::protobuf::internal::WireFormatLite::
      WriteMessageNoVirtualToArray(
        1, this->alpha_d(i), target);
  }
  
  if (!unknown_fields().empty()) {
    target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
        unknown_fields(), target);
  }
  return target;
}

int PitmanYorProcessDiscrete_GridPrior::ByteSize() const {
  int total_size = 0;
  
  // repeated .protobuf.distributions.Clustering.PitmanYor alpha_d = 1;
  total_size += 1 * this->alpha_d_size();
  for (int i = 0; i < this->alpha_d_size(); i++) {
    total_size +=
      ::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
        this->alpha_d(i));
  }
  
  if (!unknown_fields().empty()) {
    total_size +=
      ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
        unknown_fields());
  }
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = total_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void PitmanYorProcessDiscrete_GridPrior::MergeFrom(const ::google::protobuf::Message& from) {
  GOOGLE_CHECK_NE(&from, this);
  const PitmanYorProcessDiscrete_GridPrior* source =
    ::google::protobuf::internal::dynamic_cast_if_available<const PitmanYorProcessDiscrete_GridPrior*>(
      &from);
  if (source == NULL) {
    ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  } else {
    MergeFrom(*source);
  }
}

void PitmanYorProcessDiscrete_GridPrior::MergeFrom(const PitmanYorProcessDiscrete_GridPrior& from) {
  GOOGLE_CHECK_NE(&from, this);
  alpha_d_.MergeFrom(from.alpha_d_);
  mutable_unknown_fields()->MergeFrom(from.unknown_fields());
}

void PitmanYorProcessDiscrete_GridPrior::CopyFrom(const ::google::protobuf::Message& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

void PitmanYorProcessDiscrete_GridPrior::CopyFrom(const PitmanYorProcessDiscrete_GridPrior& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool PitmanYorProcessDiscrete_GridPrior::IsInitialized() const {
  
  for (int i = 0; i < alpha_d_size(); i++) {
    if (!this->alpha_d(i).IsInitialized()) return false;
  }
  return true;
}

void PitmanYorProcessDiscrete_GridPrior::Swap(PitmanYorProcessDiscrete_GridPrior* other) {
  if (other != this) {
    alpha_d_.Swap(&other->alpha_d_);
    std::swap(_has_bits_[0], other->_has_bits_[0]);
    _unknown_fields_.Swap(&other->_unknown_fields_);
    std::swap(_cached_size_, other->_cached_size_);
  }
}

::google::protobuf::Metadata PitmanYorProcessDiscrete_GridPrior::GetMetadata() const {
  protobuf_AssignDescriptorsOnce();
  ::google::protobuf::Metadata metadata;
  metadata.descriptor = PitmanYorProcessDiscrete_GridPrior_descriptor_;
  metadata.reflection = PitmanYorProcessDiscrete_GridPrior_reflection_;
  return metadata;
}


// -------------------------------------------------------------------

#ifndef _MSC_VER
const int PitmanYorProcessDiscrete_Group::kKeysFieldNumber;
const int PitmanYorProcessDiscrete_Group::kValuesFieldNumber;
#endif  // !_MSC_VER

PitmanYorProcessDiscrete_Group::PitmanYorProcessDiscrete_Group()
  : ::google::protobuf::Message() {
  SharedCtor();
}

void PitmanYorProcessDiscrete_Group::InitAsDefaultInstance() {
}

PitmanYorProcessDiscrete_Group::PitmanYorProcessDiscrete_Group(const PitmanYorProcessDiscrete_Group& from)
  : ::google::protobuf::Message() {
  SharedCtor();
  MergeFrom(from);
}

void PitmanYorProcessDiscrete_Group::SharedCtor() {
  _cached_size_ = 0;
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}

PitmanYorProcessDiscrete_Group::~PitmanYorProcessDiscrete_Group() {
  SharedDtor();
}

void PitmanYorProcessDiscrete_Group::SharedDtor() {
  if (this != default_instance_) {
  }
}

void PitmanYorProcessDiscrete_Group::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* PitmanYorProcessDiscrete_Group::descriptor() {
  protobuf_AssignDescriptorsOnce();
  return PitmanYorProcessDiscrete_Group_descriptor_;
}

const PitmanYorProcessDiscrete_Group& PitmanYorProcessDiscrete_Group::default_instance() {
  if (default_instance_ == NULL) protobuf_AddDesc_distributions_2fio_2fschema_2eproto();  return *default_instance_;
}

PitmanYorProcessDiscrete_Group* PitmanYorProcessDiscrete_Group::default_instance_ = NULL;

PitmanYorProcessDiscrete_Group* PitmanYorProcessDiscrete_Group::New() const {
  return new PitmanYorProcessDiscrete_Group;
}

void PitmanYorProcessDiscrete_Group::Clear() {
  keys_.Clear();
  values_.Clear();
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
  mutable_unknown_fields()->Clear();
}

bool PitmanYorProcessDiscrete_Group::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!(EXPRESSION)) return false
  ::google::protobuf::uint32 tag;
  while ((tag = input->ReadTag()) != 0) {
    switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
      // repeated uint32 keys = 1;
      case 1: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
         parse_keys:
          DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
                   ::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
                 1, 8, input, this->mutable_keys())));
        } else if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag)
                   == ::google::protobuf::internal::WireFormatLite::
                      WIRETYPE_LENGTH_DELIMITED) {
          DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
                   ::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
                 input, this->mutable_keys())));
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(8)) goto parse_keys;
        if (input->ExpectTag(16)) goto parse_values;
        break;
      }
      
      // repeated uint64 values = 2;
      case 2: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
         parse_values:
          DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
                   ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
                 1, 16, input, this->mutable_values())));
        } else if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag)
                   == ::google::protobuf::internal::WireFormatLite::
                      WIRETYPE_LENGTH_DELIMITED) {
          DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
                   ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
                 input, this->mutable_values())));
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(16)) goto parse_values;
        if (input->ExpectAtEnd()) return true;
        break;
      }
      
      default: {
      handle_uninterpreted:
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
          return true;
        }
        DO_(::google::protobuf::internal::WireFormat::SkipField(
              input, tag, mutable_unknown_fields()));
        break;
      }
    }
  }
  return true;
#undef DO_
}

void PitmanYorProcessDiscrete_Group::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  // repeated uint32 keys = 1;
  for (int i = 0; i < this->keys_size(); i++) {
    ::google::protobuf::internal::WireFormatLite::WriteUInt32(
      1, this->keys(i), output);
  }
  
  // repeated uint64 values = 2;
  for (int i = 0; i < this->values_size(); i++) {
    ::google::protobuf::internal::WireFormatLite::WriteUInt64(
      2, this->values(i), output);
  }
  
  if (!unknown_fields().empty()) {
    ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
        unknown_fields(), output);
  }
}

::google::protobuf::uint8* PitmanYorProcessDiscrete_Group::SerializeWithCachedSizesToArray(
    ::google::protobuf::uint8* target) const {
  // repeated uint32 keys = 1;
  for (int i = 0; i < this->keys_size(); i++) {
    target = ::google::protobuf::internal::WireFormatLite::
      WriteUInt32ToArray(1, this->keys(i), target);
  }
  
  // repeated uint64 values = 2;
  for (int i = 0; i < this->values_size(); i++) {
    target = ::google::protobuf::internal::WireFormatLite::
      WriteUInt64ToArray(2, this->values(i), target);
  }
  
  if (!unknown_fields().empty()) {
    target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
        unknown_fields(), target);
  }
  return target;
}

int PitmanYorProcessDiscrete_Group::ByteSize() const {
  int total_size = 0;
  
  // repeated uint32 keys = 1;
  {
    int data_size = 0;
    for (int i = 0; i < this->keys_size(); i++) {
      data_size += ::google::protobuf::internal::WireFormatLite::
        UInt32Size(this->keys(i));
    }
    total_size += 1 * this->keys_size() + data_size;
  }
  
  // repeated uint64 values = 2;
  {
    int data_size = 0;
    for (int i = 0; i < this->values_size(); i++) {
      data_size += ::google::protobuf::internal::WireFormatLite::
        UInt64Size(this->values(i));
    }
    total_size += 1 * this->values_size() + data_size;
  }
  
  if (!unknown_fields().empty()) {
    total_size +=
      ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
        unknown_fields());
  }
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = total_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void PitmanYorProcessDiscrete_Group::MergeFrom(const ::google::protobuf::Message& from) {
  GOOGLE_CHECK_NE(&from, this);
  const PitmanYorProcessDiscrete_Group* source =
    ::google::protobuf::internal::dynamic_cast_if_available<const PitmanYorProcessDiscrete_Group*>(
      &from);
  if (source == NULL) {
    ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  } else {
    MergeFrom(*source);
  }
}

void PitmanYorProcessDiscrete_Group::MergeFrom(const PitmanYorProcessDiscrete_Group& from) {
  GOOGLE_CHECK_NE(&from, this);
  keys_.MergeFrom(from.keys_);
  values_.MergeFrom(from.values_);
  mutable_unknown_fields()->MergeFrom(from.unknown_fields());
}

void PitmanYorProcessDiscrete_Group::CopyFrom(const ::google::protobuf::Message& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

void PitmanYorProcessDiscrete_Group::CopyFrom(const PitmanYorProcessDiscrete_Group& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool PitmanYorProcessDiscrete_Group::IsInitialized() const {
  
  return true;
}

void PitmanYorProcessDiscrete_Group::Swap(PitmanYorProcessDiscrete_Group* other) {
  if (other != this) {
    keys_.Swap(&other->keys_);
    values_.Swap(&other->values_);
    std::swap(_has_bits_[0], other->_has_bits_[0]);
    _unknown_fields_.Swap(&other->_unknown_fields_);
    std::swap(_cached_size_, other->_cached_size_);
  }
}

::google::protobuf::Metadata PitmanYorProcessDiscrete_Group::GetMetadata() const {
  protobuf_AssignDescriptorsOnce();
  ::google::protobuf::Metadata metadata;
  metadata.descriptor = PitmanYorProcessDiscrete_Group_descriptor_;
  metadata.reflection = PitmanYorProcessDiscrete_Group_reflection_;
  return metadata;
}


// -------------------------------------------------------------------

#ifndef _MSC_VER
#endif  // !_MSC_VER

PitmanYorProcessDiscrete::PitmanYorProcessDiscrete()
  : ::google::protobuf::Message() {
  SharedCtor();
}

void PitmanYorProcessDiscrete::InitAsDefaultInstance() {
}

PitmanYorProcessDiscrete::PitmanYorProcessDiscrete(const PitmanYorProcessDiscrete& from)
  : ::google::protobuf::Message() {
  SharedCtor();
  MergeFrom(from);
}

void PitmanYorProcessDiscrete::SharedCtor() {
  _cached_size_ = 0;
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}

PitmanYorProcessDiscrete::~PitmanYorProcessDiscrete() {
  SharedDtor();
}

void PitmanYorProcessDiscrete::SharedDtor() {
  if (this != default_instance_) {
  }
}

void PitmanYorProcessDiscrete::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* PitmanYorProcessDiscrete::descriptor() {
  protobuf_AssignDescriptorsOnce();
  return PitmanYorProcessDiscrete_descriptor_;
}

const PitmanYorProcessDiscrete& PitmanYorProcessDiscrete::default_instance() {
  if (default_instance_ == NULL) protobuf_AddDesc_distributions_2fio_2fschema_2eproto();  return *default_instance_;
}

PitmanYorProcessDiscrete* PitmanYorProcessDiscrete::default_instance_ = NULL;

PitmanYorProcessDiscrete* PitmanYorProcessDiscrete::New() const {
  return new PitmanYorProcessDiscrete;
}

void PitmanYorProcessDiscrete::Clear() {
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
  mutable_unknown_fields()->Clear();
}

bool PitmanYorProcessDiscrete::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!(EXPRESSION)) return false
  ::google::protobuf::uint32 tag;
  while ((tag = input->ReadTag()) != 0) {
    if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
        ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
      return true;
    }
    DO_(::google::protobuf::internal::WireFormat::SkipField(
          input, tag, mutable_unknown_fields()));
  }
  return true;
#undef DO_
}

void PitmanYorProcessDiscrete::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  if (!unknown_fields().empty()) {
    ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
        unknown_fields(), output);
  }
}

::google::protobuf::uint8* PitmanYorProcessDiscrete::SerializeWithCachedSizesToArray(
    ::google::protobuf::uint8* target) const {
  if (!unknown_fields().empty()) {
    target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
        unknown_fields(), target);
  }
  return target;
}

int PitmanYorProcessDiscrete::ByteSize() const {
  int total_size = 0;
  
  if (!unknown_fields().empty()) {
    total_size +=
      ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
        unknown_fields());
  }
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = total_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void PitmanYorProcessDiscrete::MergeFrom(const ::google::protobuf::Message& from) {
  GOOGLE_CHECK_NE(&from, this);
  const PitmanYorProcessDiscrete* source =
    ::google::protobuf::internal::dynamic_cast_if_available<const PitmanYorProcessDiscrete*>(
      &from);
  if (source == NULL) {
    ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  } else {
    MergeFrom(*source);
  }
}

void PitmanYorProcessDiscrete::MergeFrom(const PitmanYorProcessDiscrete& from) {
  GOOGLE_CHECK_NE(&from, this);
  mutable_unknown_fields()->MergeFrom(from.unknown_fields());
}

void PitmanYorProcessDiscrete::CopyFrom(const ::google::protobuf::Message& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

void PitmanYorProcessDiscrete::CopyFrom(const PitmanYorProcessDiscrete& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool PitmanYorProcessDiscrete::IsInitialized() const {
  
  return true;
}

void PitmanYorProcessDiscrete::Swap(PitmanYorProcessDiscrete* other) {
  if (other != this) {
    _unknown_fields_.Swap(&other->_unknown_fields_);
    std::swap(_cached_size_, other->_cached_size_);
  }
}

::google::protobuf::Metadata PitmanYorProcessDiscrete::GetMetadata() const {
  protobuf_AssignDescriptorsOnce();
  ::google::protobuf::Metadata metadata;
  metadata.descriptor = PitmanYorProcessDiscrete_descriptor_;
  metadata.reflection = PitmanYorProcessDiscrete_reflection_;
  return metadata;
}


// ===================================================================

#ifndef _MSC_VER
const int GammaPoisson_Shared::kAlphaFieldNumber;
const int GammaPoisson_Shared::kInvBetaFieldNumber;
#endif  // !_MSC_VER

GammaPoisson_Shared::GammaPoisson_Shared()
  : ::google::protobuf::Message() {
  SharedCtor();
}

void GammaPoisson_Shared::InitAsDefaultInstance() {
}

GammaPoisson_Shared::GammaPoisson_Shared(const GammaPoisson_Shared& from)
  : ::google::protobuf::Message() {
  SharedCtor();
  MergeFrom(from);
}

void GammaPoisson_Shared::SharedCtor() {
  _cached_size_ = 0;
  alpha_ = 0;
  inv_beta_ = 0;
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}

GammaPoisson_Shared::~GammaPoisson_Shared() {
  SharedDtor();
}

void GammaPoisson_Shared::SharedDtor() {
  if (this != default_instance_) {
  }
}

void GammaPoisson_Shared::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* GammaPoisson_Shared::descriptor() {
  protobuf_AssignDescriptorsOnce();
  return GammaPoisson_Shared_descriptor_;
}

const GammaPoisson_Shared& GammaPoisson_Shared::default_instance() {
  if (default_instance_ == NULL) protobuf_AddDesc_distributions_2fio_2fschema_2eproto();  return *default_instance_;
}

GammaPoisson_Shared* GammaPoisson_Shared::default_instance_ = NULL;

GammaPoisson_Shared* GammaPoisson_Shared::New() const {
  return new GammaPoisson_Shared;
}

void GammaPoisson_Shared::Clear() {
  if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    alpha_ = 0;
    inv_beta_ = 0;
  }
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
  mutable_unknown_fields()->Clear();
}

bool GammaPoisson_Shared::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!(EXPRESSION)) return false
  ::google::protobuf::uint32 tag;
  while ((tag = input->ReadTag()) != 0) {
    switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
      // required float alpha = 1;
      case 1: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_FIXED32) {
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 input, &alpha_)));
          set_has_alpha();
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(21)) goto parse_inv_beta;
        break;
      }
      
      // required float inv_beta = 2;
      case 2: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_FIXED32) {
         parse_inv_beta:
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 input, &inv_beta_)));
          set_has_inv_beta();
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectAtEnd()) return true;
        break;
      }
      
      default: {
      handle_uninterpreted:
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
          return true;
        }
        DO_(::google::protobuf::internal::WireFormat::SkipField(
              input, tag, mutable_unknown_fields()));
        break;
      }
    }
  }
  return true;
#undef DO_
}

void GammaPoisson_Shared::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  // required float alpha = 1;
  if (has_alpha()) {
    ::google::protobuf::internal::WireFormatLite::WriteFloat(1, this->alpha(), output);
  }
  
  // required float inv_beta = 2;
  if (has_inv_beta()) {
    ::google::protobuf::internal::WireFormatLite::WriteFloat(2, this->inv_beta(), output);
  }
  
  if (!unknown_fields().empty()) {
    ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
        unknown_fields(), output);
  }
}

::google::protobuf::uint8* GammaPoisson_Shared::SerializeWithCachedSizesToArray(
    ::google::protobuf::uint8* target) const {
  // required float alpha = 1;
  if (has_alpha()) {
    target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(1, this->alpha(), target);
  }
  
  // required float inv_beta = 2;
  if (has_inv_beta()) {
    target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(2, this->inv_beta(), target);
  }
  
  if (!unknown_fields().empty()) {
    target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
        unknown_fields(), target);
  }
  return target;
}

int GammaPoisson_Shared::ByteSize() const {
  int total_size = 0;
  
  if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    // required float alpha = 1;
    if (has_alpha()) {
      total_size += 1 + 4;
    }
    
    // required float inv_beta = 2;
    if (has_inv_beta()) {
      total_size += 1 + 4;
    }
    
  }
  if (!unknown_fields().empty()) {
    total_size +=
      ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
        unknown_fields());
  }
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = total_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void GammaPoisson_Shared::MergeFrom(const ::google::protobuf::Message& from) {
  GOOGLE_CHECK_NE(&from, this);
  const GammaPoisson_Shared* source =
    ::google::protobuf::internal::dynamic_cast_if_available<const GammaPoisson_Shared*>(
      &from);
  if (source == NULL) {
    ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  } else {
    MergeFrom(*source);
  }
}

void GammaPoisson_Shared::MergeFrom(const GammaPoisson_Shared& from) {
  GOOGLE_CHECK_NE(&from, this);
  if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    if (from.has_alpha()) {
      set_alpha(from.alpha());
    }
    if (from.has_inv_beta()) {
      set_inv_beta(from.inv_beta());
    }
  }
  mutable_unknown_fields()->MergeFrom(from.unknown_fields());
}

void GammaPoisson_Shared::CopyFrom(const ::google::protobuf::Message& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

void GammaPoisson_Shared::CopyFrom(const GammaPoisson_Shared& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool GammaPoisson_Shared::IsInitialized() const {
  if ((_has_bits_[0] & 0x00000003) != 0x00000003) return false;
  
  return true;
}

void GammaPoisson_Shared::Swap(GammaPoisson_Shared* other) {
  if (other != this) {
    std::swap(alpha_, other->alpha_);
    std::swap(inv_beta_, other->inv_beta_);
    std::swap(_has_bits_[0], other->_has_bits_[0]);
    _unknown_fields_.Swap(&other->_unknown_fields_);
    std::swap(_cached_size_, other->_cached_size_);
  }
}

::google::protobuf::Metadata GammaPoisson_Shared::GetMetadata() const {
  protobuf_AssignDescriptorsOnce();
  ::google::protobuf::Metadata metadata;
  metadata.descriptor = GammaPoisson_Shared_descriptor_;
  metadata.reflection = GammaPoisson_Shared_reflection_;
  return metadata;
}


// -------------------------------------------------------------------

#ifndef _MSC_VER
const int GammaPoisson_GridPrior::kAlphaFieldNumber;
const int GammaPoisson_GridPrior::kInvBetaFieldNumber;
#endif  // !_MSC_VER

GammaPoisson_GridPrior::GammaPoisson_GridPrior()
  : ::google::protobuf::Message() {
  SharedCtor();
}

void GammaPoisson_GridPrior::InitAsDefaultInstance() {
}

GammaPoisson_GridPrior::GammaPoisson_GridPrior(const GammaPoisson_GridPrior& from)
  : ::google::protobuf::Message() {
  SharedCtor();
  MergeFrom(from);
}

void GammaPoisson_GridPrior::SharedCtor() {
  _cached_size_ = 0;
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}

GammaPoisson_GridPrior::~GammaPoisson_GridPrior() {
  SharedDtor();
}

void GammaPoisson_GridPrior::SharedDtor() {
  if (this != default_instance_) {
  }
}

void GammaPoisson_GridPrior::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* GammaPoisson_GridPrior::descriptor() {
  protobuf_AssignDescriptorsOnce();
  return GammaPoisson_GridPrior_descriptor_;
}

const GammaPoisson_GridPrior& GammaPoisson_GridPrior::default_instance() {
  if (default_instance_ == NULL) protobuf_AddDesc_distributions_2fio_2fschema_2eproto();  return *default_instance_;
}

GammaPoisson_GridPrior* GammaPoisson_GridPrior::default_instance_ = NULL;

GammaPoisson_GridPrior* GammaPoisson_GridPrior::New() const {
  return new GammaPoisson_GridPrior;
}

void GammaPoisson_GridPrior::Clear() {
  alpha_.Clear();
  inv_beta_.Clear();
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
  mutable_unknown_fields()->Clear();
}

bool GammaPoisson_GridPrior::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!(EXPRESSION)) return false
  ::google::protobuf::uint32 tag;
  while ((tag = input->ReadTag()) != 0) {
    switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
      // repeated float alpha = 1;
      case 1: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_FIXED32) {
         parse_alpha:
          DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 1, 13, input, this->mutable_alpha())));
        } else if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag)
                   == ::google::protobuf::internal::WireFormatLite::
                      WIRETYPE_LENGTH_DELIMITED) {
          DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 input, this->mutable_alpha())));
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(13)) goto parse_alpha;
        if (input->ExpectTag(21)) goto parse_inv_beta;
        break;
      }
      
      // repeated float inv_beta = 2;
      case 2: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_FIXED32) {
         parse_inv_beta:
          DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 1, 21, input, this->mutable_inv_beta())));
        } else if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag)
                   == ::google::protobuf::internal::WireFormatLite::
                      WIRETYPE_LENGTH_DELIMITED) {
          DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 input, this->mutable_inv_beta())));
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(21)) goto parse_inv_beta;
        if (input->ExpectAtEnd()) return true;
        break;
      }
      
      default: {
      handle_uninterpreted:
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
          return true;
        }
        DO_(::google::protobuf::internal::WireFormat::SkipField(
              input, tag, mutable_unknown_fields()));
        break;
      }
    }
  }
  return true;
#undef DO_
}

void GammaPoisson_GridPrior::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  // repeated float alpha = 1;
  for (int i = 0; i < this->alpha_size(); i++) {
    ::google::protobuf::internal::WireFormatLite::WriteFloat(
      1, this->alpha(i), output);
  }
  
  // repeated float inv_beta = 2;
  for (int i = 0; i < this->inv_beta_size(); i++) {
    ::google::protobuf::internal::WireFormatLite::WriteFloat(
      2, this->inv_beta(i), output);
  }
  
  if (!unknown_fields().empty()) {
    ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
        unknown_fields(), output);
  }
}

::google::protobuf::uint8* GammaPoisson_GridPrior::SerializeWithCachedSizesToArray(
    ::google::protobuf::uint8* target) const {
  // repeated float alpha = 1;
  for (int i = 0; i < this->alpha_size(); i++) {
    target = ::google::protobuf::internal::WireFormatLite::
      WriteFloatToArray(1, this->alpha(i), target);
  }
  
  // repeated float inv_beta = 2;
  for (int i = 0; i < this->inv_beta_size(); i++) {
    target = ::google::protobuf::internal::WireFormatLite::
      WriteFloatToArray(2, this->inv_beta(i), target);
  }
  
  if (!unknown_fields().empty()) {
    target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
        unknown_fields(), target);
  }
  return target;
}

int GammaPoisson_GridPrior::ByteSize() const {
  int total_size = 0;
  
  // repeated float alpha = 1;
  {
    int data_size = 0;
    data_size = 4 * this->alpha_size();
    total_size += 1 * this->alpha_size() + data_size;
  }
  
  // repeated float inv_beta = 2;
  {
    int data_size = 0;
    data_size = 4 * this->inv_beta_size();
    total_size += 1 * this->inv_beta_size() + data_size;
  }
  
  if (!unknown_fields().empty()) {
    total_size +=
      ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
        unknown_fields());
  }
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = total_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void GammaPoisson_GridPrior::MergeFrom(const ::google::protobuf::Message& from) {
  GOOGLE_CHECK_NE(&from, this);
  const GammaPoisson_GridPrior* source =
    ::google::protobuf::internal::dynamic_cast_if_available<const GammaPoisson_GridPrior*>(
      &from);
  if (source == NULL) {
    ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  } else {
    MergeFrom(*source);
  }
}

void GammaPoisson_GridPrior::MergeFrom(const GammaPoisson_GridPrior& from) {
  GOOGLE_CHECK_NE(&from, this);
  alpha_.MergeFrom(from.alpha_);
  inv_beta_.MergeFrom(from.inv_beta_);
  mutable_unknown_fields()->MergeFrom(from.unknown_fields());
}

void GammaPoisson_GridPrior::CopyFrom(const ::google::protobuf::Message& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

void GammaPoisson_GridPrior::CopyFrom(const GammaPoisson_GridPrior& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool GammaPoisson_GridPrior::IsInitialized() const {
  
  return true;
}

void GammaPoisson_GridPrior::Swap(GammaPoisson_GridPrior* other) {
  if (other != this) {
    alpha_.Swap(&other->alpha_);
    inv_beta_.Swap(&other->inv_beta_);
    std::swap(_has_bits_[0], other->_has_bits_[0]);
    _unknown_fields_.Swap(&other->_unknown_fields_);
    std::swap(_cached_size_, other->_cached_size_);
  }
}

::google::protobuf::Metadata GammaPoisson_GridPrior::GetMetadata() const {
  protobuf_AssignDescriptorsOnce();
  ::google::protobuf::Metadata metadata;
  metadata.descriptor = GammaPoisson_GridPrior_descriptor_;
  metadata.reflection = GammaPoisson_GridPrior_reflection_;
  return metadata;
}


// -------------------------------------------------------------------

#ifndef _MSC_VER
const int GammaPoisson_Group::kCountFieldNumber;
const int GammaPoisson_Group::kSumFieldNumber;
const int GammaPoisson_Group::kLogProdFieldNumber;
#endif  // !_MSC_VER

GammaPoisson_Group::GammaPoisson_Group()
  : ::google::protobuf::Message() {
  SharedCtor();
}

void GammaPoisson_Group::InitAsDefaultInstance() {
}

GammaPoisson_Group::GammaPoisson_Group(const GammaPoisson_Group& from)
  : ::google::protobuf::Message() {
  SharedCtor();
  MergeFrom(from);
}

void GammaPoisson_Group::SharedCtor() {
  _cached_size_ = 0;
  count_ = GOOGLE_ULONGLONG(0);
  sum_ = GOOGLE_ULONGLONG(0);
  log_prod_ = 0;
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}

GammaPoisson_Group::~GammaPoisson_Group() {
  SharedDtor();
}

void GammaPoisson_Group::SharedDtor() {
  if (this != default_instance_) {
  }
}

void GammaPoisson_Group::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* GammaPoisson_Group::descriptor() {
  protobuf_AssignDescriptorsOnce();
  return GammaPoisson_Group_descriptor_;
}

const GammaPoisson_Group& GammaPoisson_Group::default_instance() {
  if (default_instance_ == NULL) protobuf_AddDesc_distributions_2fio_2fschema_2eproto();  return *default_instance_;
}

GammaPoisson_Group* GammaPoisson_Group::default_instance_ = NULL;

GammaPoisson_Group* GammaPoisson_Group::New() const {
  return new GammaPoisson_Group;
}

void GammaPoisson_Group::Clear() {
  if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    count_ = GOOGLE_ULONGLONG(0);
    sum_ = GOOGLE_ULONGLONG(0);
    log_prod_ = 0;
  }
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
  mutable_unknown_fields()->Clear();
}

bool GammaPoisson_Group::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!(EXPRESSION)) return false
  ::google::protobuf::uint32 tag;
  while ((tag = input->ReadTag()) != 0) {
    switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
      // required uint64 count = 1;
      case 1: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
                 input, &count_)));
          set_has_count();
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(16)) goto parse_sum;
        break;
      }
      
      // required uint64 sum = 2;
      case 2: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
         parse_sum:
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
                 input, &sum_)));
          set_has_sum();
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(29)) goto parse_log_prod;
        break;
      }
      
      // required float log_prod = 3;
      case 3: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_FIXED32) {
         parse_log_prod:
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 input, &log_prod_)));
          set_has_log_prod();
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectAtEnd()) return true;
        break;
      }
      
      default: {
      handle_uninterpreted:
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
          return true;
        }
        DO_(::google::protobuf::internal::WireFormat::SkipField(
              input, tag, mutable_unknown_fields()));
        break;
      }
    }
  }
  return true;
#undef DO_
}

void GammaPoisson_Group::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  // required uint64 count = 1;
  if (has_count()) {
    ::google::protobuf::internal::WireFormatLite::WriteUInt64(1, this->count(), output);
  }
  
  // required uint64 sum = 2;
  if (has_sum()) {
    ::google::protobuf::internal::WireFormatLite::WriteUInt64(2, this->sum(), output);
  }
  
  // required float log_prod = 3;
  if (has_log_prod()) {
    ::google::protobuf::internal::WireFormatLite::WriteFloat(3, this->log_prod(), output);
  }
  
  if (!unknown_fields().empty()) {
    ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
        unknown_fields(), output);
  }
}

::google::protobuf::uint8* GammaPoisson_Group::SerializeWithCachedSizesToArray(
    ::google::protobuf::uint8* target) const {
  // required uint64 count = 1;
  if (has_count()) {
    target = ::google::protobuf::internal::WireFormatLite::WriteUInt64ToArray(1, this->count(), target);
  }
  
  // required uint64 sum = 2;
  if (has_sum()) {
    target = ::google::protobuf::internal::WireFormatLite::WriteUInt64ToArray(2, this->sum(), target);
  }
  
  // required float log_prod = 3;
  if (has_log_prod()) {
    target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(3, this->log_prod(), target);
  }
  
  if (!unknown_fields().empty()) {
    target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
        unknown_fields(), target);
  }
  return target;
}

int GammaPoisson_Group::ByteSize() const {
  int total_size = 0;
  
  if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    // required uint64 count = 1;
    if (has_count()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::UInt64Size(
          this->count());
    }
    
    // required uint64 sum = 2;
    if (has_sum()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::UInt64Size(
          this->sum());
    }
    
    // required float log_prod = 3;
    if (has_log_prod()) {
      total_size += 1 + 4;
    }
    
  }
  if (!unknown_fields().empty()) {
    total_size +=
      ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
        unknown_fields());
  }
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = total_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void GammaPoisson_Group::MergeFrom(const ::google::protobuf::Message& from) {
  GOOGLE_CHECK_NE(&from, this);
  const GammaPoisson_Group* source =
    ::google::protobuf::internal::dynamic_cast_if_available<const GammaPoisson_Group*>(
      &from);
  if (source == NULL) {
    ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  } else {
    MergeFrom(*source);
  }
}

void GammaPoisson_Group::MergeFrom(const GammaPoisson_Group& from) {
  GOOGLE_CHECK_NE(&from, this);
  if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    if (from.has_count()) {
      set_count(from.count());
    }
    if (from.has_sum()) {
      set_sum(from.sum());
    }
    if (from.has_log_prod()) {
      set_log_prod(from.log_prod());
    }
  }
  mutable_unknown_fields()->MergeFrom(from.unknown_fields());
}

void GammaPoisson_Group::CopyFrom(const ::google::protobuf::Message& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

void GammaPoisson_Group::CopyFrom(const GammaPoisson_Group& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool GammaPoisson_Group::IsInitialized() const {
  if ((_has_bits_[0] & 0x00000007) != 0x00000007) return false;
  
  return true;
}

void GammaPoisson_Group::Swap(GammaPoisson_Group* other) {
  if (other != this) {
    std::swap(count_, other->count_);
    std::swap(sum_, other->sum_);
    std::swap(log_prod_, other->log_prod_);
    std::swap(_has_bits_[0], other->_has_bits_[0]);
    _unknown_fields_.Swap(&other->_unknown_fields_);
    std::swap(_cached_size_, other->_cached_size_);
  }
}

::google::protobuf::Metadata GammaPoisson_Group::GetMetadata() const {
  protobuf_AssignDescriptorsOnce();
  ::google::protobuf::Metadata metadata;
  metadata.descriptor = GammaPoisson_Group_descriptor_;
  metadata.reflection = GammaPoisson_Group_reflection_;
  return metadata;
}


// -------------------------------------------------------------------

#ifndef _MSC_VER
#endif  // !_MSC_VER

GammaPoisson::GammaPoisson()
  : ::google::protobuf::Message() {
  SharedCtor();
}

void GammaPoisson::InitAsDefaultInstance() {
}

GammaPoisson::GammaPoisson(const GammaPoisson& from)
  : ::google::protobuf::Message() {
  SharedCtor();
  MergeFrom(from);
}

void GammaPoisson::SharedCtor() {
  _cached_size_ = 0;
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}

GammaPoisson::~GammaPoisson() {
  SharedDtor();
}

void GammaPoisson::SharedDtor() {
  if (this != default_instance_) {
  }
}

void GammaPoisson::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* GammaPoisson::descriptor() {
  protobuf_AssignDescriptorsOnce();
  return GammaPoisson_descriptor_;
}

const GammaPoisson& GammaPoisson::default_instance() {
  if (default_instance_ == NULL) protobuf_AddDesc_distributions_2fio_2fschema_2eproto();  return *default_instance_;
}

GammaPoisson* GammaPoisson::default_instance_ = NULL;

GammaPoisson* GammaPoisson::New() const {
  return new GammaPoisson;
}

void GammaPoisson::Clear() {
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
  mutable_unknown_fields()->Clear();
}

bool GammaPoisson::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!(EXPRESSION)) return false
  ::google::protobuf::uint32 tag;
  while ((tag = input->ReadTag()) != 0) {
    if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
        ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
      return true;
    }
    DO_(::google::protobuf::internal::WireFormat::SkipField(
          input, tag, mutable_unknown_fields()));
  }
  return true;
#undef DO_
}

void GammaPoisson::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  if (!unknown_fields().empty()) {
    ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
        unknown_fields(), output);
  }
}

::google::protobuf::uint8* GammaPoisson::SerializeWithCachedSizesToArray(
    ::google::protobuf::uint8* target) const {
  if (!unknown_fields().empty()) {
    target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
        unknown_fields(), target);
  }
  return target;
}

int GammaPoisson::ByteSize() const {
  int total_size = 0;
  
  if (!unknown_fields().empty()) {
    total_size +=
      ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
        unknown_fields());
  }
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = total_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void GammaPoisson::MergeFrom(const ::google::protobuf::Message& from) {
  GOOGLE_CHECK_NE(&from, this);
  const GammaPoisson* source =
    ::google::protobuf::internal::dynamic_cast_if_available<const GammaPoisson*>(
      &from);
  if (source == NULL) {
    ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  } else {
    MergeFrom(*source);
  }
}

void GammaPoisson::MergeFrom(const GammaPoisson& from) {
  GOOGLE_CHECK_NE(&from, this);
  mutable_unknown_fields()->MergeFrom(from.unknown_fields());
}

void GammaPoisson::CopyFrom(const ::google::protobuf::Message& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

void GammaPoisson::CopyFrom(const GammaPoisson& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool GammaPoisson::IsInitialized() const {
  
  return true;
}

void GammaPoisson::Swap(GammaPoisson* other) {
  if (other != this) {
    _unknown_fields_.Swap(&other->_unknown_fields_);
    std::swap(_cached_size_, other->_cached_size_);
  }
}

::google::protobuf::Metadata GammaPoisson::GetMetadata() const {
  protobuf_AssignDescriptorsOnce();
  ::google::protobuf::Metadata metadata;
  metadata.descriptor = GammaPoisson_descriptor_;
  metadata.reflection = GammaPoisson_reflection_;
  return metadata;
}


// ===================================================================

#ifndef _MSC_VER
const int BetaNegativeBinomial_Shared::kAlphaFieldNumber;
const int BetaNegativeBinomial_Shared::kBetaFieldNumber;
const int BetaNegativeBinomial_Shared::kRFieldNumber;
#endif  // !_MSC_VER

BetaNegativeBinomial_Shared::BetaNegativeBinomial_Shared()
  : ::google::protobuf::Message() {
  SharedCtor();
}

void BetaNegativeBinomial_Shared::InitAsDefaultInstance() {
}

BetaNegativeBinomial_Shared::BetaNegativeBinomial_Shared(const BetaNegativeBinomial_Shared& from)
  : ::google::protobuf::Message() {
  SharedCtor();
  MergeFrom(from);
}

void BetaNegativeBinomial_Shared::SharedCtor() {
  _cached_size_ = 0;
  alpha_ = 0;
  beta_ = 0;
  r_ = GOOGLE_ULONGLONG(0);
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}

BetaNegativeBinomial_Shared::~BetaNegativeBinomial_Shared() {
  SharedDtor();
}

void BetaNegativeBinomial_Shared::SharedDtor() {
  if (this != default_instance_) {
  }
}

void BetaNegativeBinomial_Shared::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* BetaNegativeBinomial_Shared::descriptor() {
  protobuf_AssignDescriptorsOnce();
  return BetaNegativeBinomial_Shared_descriptor_;
}

const BetaNegativeBinomial_Shared& BetaNegativeBinomial_Shared::default_instance() {
  if (default_instance_ == NULL) protobuf_AddDesc_distributions_2fio_2fschema_2eproto();  return *default_instance_;
}

BetaNegativeBinomial_Shared* BetaNegativeBinomial_Shared::default_instance_ = NULL;

BetaNegativeBinomial_Shared* BetaNegativeBinomial_Shared::New() const {
  return new BetaNegativeBinomial_Shared;
}

void BetaNegativeBinomial_Shared::Clear() {
  if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    alpha_ = 0;
    beta_ = 0;
    r_ = GOOGLE_ULONGLONG(0);
  }
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
  mutable_unknown_fields()->Clear();
}

bool BetaNegativeBinomial_Shared::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!(EXPRESSION)) return false
  ::google::protobuf::uint32 tag;
  while ((tag = input->ReadTag()) != 0) {
    switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
      // required float alpha = 1;
      case 1: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_FIXED32) {
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 input, &alpha_)));
          set_has_alpha();
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(21)) goto parse_beta;
        break;
      }
      
      // required float beta = 2;
      case 2: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_FIXED32) {
         parse_beta:
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 input, &beta_)));
          set_has_beta();
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(24)) goto parse_r;
        break;
      }
      
      // required uint64 r = 3;
      case 3: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
         parse_r:
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
                 input, &r_)));
          set_has_r();
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectAtEnd()) return true;
        break;
      }
      
      default: {
      handle_uninterpreted:
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
          return true;
        }
        DO_(::google::protobuf::internal::WireFormat::SkipField(
              input, tag, mutable_unknown_fields()));
        break;
      }
    }
  }
  return true;
#undef DO_
}

void BetaNegativeBinomial_Shared::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  // required float alpha = 1;
  if (has_alpha()) {
    ::google::protobuf::internal::WireFormatLite::WriteFloat(1, this->alpha(), output);
  }
  
  // required float beta = 2;
  if (has_beta()) {
    ::google::protobuf::internal::WireFormatLite::WriteFloat(2, this->beta(), output);
  }
  
  // required uint64 r = 3;
  if (has_r()) {
    ::google::protobuf::internal::WireFormatLite::WriteUInt64(3, this->r(), output);
  }
  
  if (!unknown_fields().empty()) {
    ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
        unknown_fields(), output);
  }
}

::google::protobuf::uint8* BetaNegativeBinomial_Shared::SerializeWithCachedSizesToArray(
    ::google::protobuf::uint8* target) const {
  // required float alpha = 1;
  if (has_alpha()) {
    target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(1, this->alpha(), target);
  }
  
  // required float beta = 2;
  if (has_beta()) {
    target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(2, this->beta(), target);
  }
  
  // required uint64 r = 3;
  if (has_r()) {
    target = ::google::protobuf::internal::WireFormatLite::WriteUInt64ToArray(3, this->r(), target);
  }
  
  if (!unknown_fields().empty()) {
    target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
        unknown_fields(), target);
  }
  return target;
}

int BetaNegativeBinomial_Shared::ByteSize() const {
  int total_size = 0;
  
  if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    // required float alpha = 1;
    if (has_alpha()) {
      total_size += 1 + 4;
    }
    
    // required float beta = 2;
    if (has_beta()) {
      total_size += 1 + 4;
    }
    
    // required uint64 r = 3;
    if (has_r()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::UInt64Size(
          this->r());
    }
    
  }
  if (!unknown_fields().empty()) {
    total_size +=
      ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
        unknown_fields());
  }
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = total_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void BetaNegativeBinomial_Shared::MergeFrom(const ::google::protobuf::Message& from) {
  GOOGLE_CHECK_NE(&from, this);
  const BetaNegativeBinomial_Shared* source =
    ::google::protobuf::internal::dynamic_cast_if_available<const BetaNegativeBinomial_Shared*>(
      &from);
  if (source == NULL) {
    ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  } else {
    MergeFrom(*source);
  }
}

void BetaNegativeBinomial_Shared::MergeFrom(const BetaNegativeBinomial_Shared& from) {
  GOOGLE_CHECK_NE(&from, this);
  if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    if (from.has_alpha()) {
      set_alpha(from.alpha());
    }
    if (from.has_beta()) {
      set_beta(from.beta());
    }
    if (from.has_r()) {
      set_r(from.r());
    }
  }
  mutable_unknown_fields()->MergeFrom(from.unknown_fields());
}

void BetaNegativeBinomial_Shared::CopyFrom(const ::google::protobuf::Message& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

void BetaNegativeBinomial_Shared::CopyFrom(const BetaNegativeBinomial_Shared& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool BetaNegativeBinomial_Shared::IsInitialized() const {
  if ((_has_bits_[0] & 0x00000007) != 0x00000007) return false;
  
  return true;
}

void BetaNegativeBinomial_Shared::Swap(BetaNegativeBinomial_Shared* other) {
  if (other != this) {
    std::swap(alpha_, other->alpha_);
    std::swap(beta_, other->beta_);
    std::swap(r_, other->r_);
    std::swap(_has_bits_[0], other->_has_bits_[0]);
    _unknown_fields_.Swap(&other->_unknown_fields_);
    std::swap(_cached_size_, other->_cached_size_);
  }
}

::google::protobuf::Metadata BetaNegativeBinomial_Shared::GetMetadata() const {
  protobuf_AssignDescriptorsOnce();
  ::google::protobuf::Metadata metadata;
  metadata.descriptor = BetaNegativeBinomial_Shared_descriptor_;
  metadata.reflection = BetaNegativeBinomial_Shared_reflection_;
  return metadata;
}


// -------------------------------------------------------------------

#ifndef _MSC_VER
const int BetaNegativeBinomial_GridPrior::kAlphaFieldNumber;
const int BetaNegativeBinomial_GridPrior::kBetaFieldNumber;
const int BetaNegativeBinomial_GridPrior::kRFieldNumber;
#endif  // !_MSC_VER

BetaNegativeBinomial_GridPrior::BetaNegativeBinomial_GridPrior()
  : ::google::protobuf::Message() {
  SharedCtor();
}

void BetaNegativeBinomial_GridPrior::InitAsDefaultInstance() {
}

BetaNegativeBinomial_GridPrior::BetaNegativeBinomial_GridPrior(const BetaNegativeBinomial_GridPrior& from)
  : ::google::protobuf::Message() {
  SharedCtor();
  MergeFrom(from);
}

void BetaNegativeBinomial_GridPrior::SharedCtor() {
  _cached_size_ = 0;
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}

BetaNegativeBinomial_GridPrior::~BetaNegativeBinomial_GridPrior() {
  SharedDtor();
}

void BetaNegativeBinomial_GridPrior::SharedDtor() {
  if (this != default_instance_) {
  }
}

void BetaNegativeBinomial_GridPrior::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* BetaNegativeBinomial_GridPrior::descriptor() {
  protobuf_AssignDescriptorsOnce();
  return BetaNegativeBinomial_GridPrior_descriptor_;
}

const BetaNegativeBinomial_GridPrior& BetaNegativeBinomial_GridPrior::default_instance() {
  if (default_instance_ == NULL) protobuf_AddDesc_distributions_2fio_2fschema_2eproto();  return *default_instance_;
}

BetaNegativeBinomial_GridPrior* BetaNegativeBinomial_GridPrior::default_instance_ = NULL;

BetaNegativeBinomial_GridPrior* BetaNegativeBinomial_GridPrior::New() const {
  return new BetaNegativeBinomial_GridPrior;
}

void BetaNegativeBinomial_GridPrior::Clear() {
  alpha_.Clear();
  beta_.Clear();
  r_.Clear();
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
  mutable_unknown_fields()->Clear();
}

bool BetaNegativeBinomial_GridPrior::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!(EXPRESSION)) return false
  ::google::protobuf::uint32 tag;
  while ((tag = input->ReadTag()) != 0) {
    switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
      // repeated float alpha = 1;
      case 1: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_FIXED32) {
         parse_alpha:
          DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 1, 13, input, this->mutable_alpha())));
        } else if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag)
                   == ::google::protobuf::internal::WireFormatLite::
                      WIRETYPE_LENGTH_DELIMITED) {
          DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 input, this->mutable_alpha())));
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(13)) goto parse_alpha;
        if (input->ExpectTag(21)) goto parse_beta;
        break;
      }
      
      // repeated float beta = 2;
      case 2: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_FIXED32) {
         parse_beta:
          DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 1, 21, input, this->mutable_beta())));
        } else if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag)
                   == ::google::protobuf::internal::WireFormatLite::
                      WIRETYPE_LENGTH_DELIMITED) {
          DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 input, this->mutable_beta())));
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(21)) goto parse_beta;
        if (input->ExpectTag(24)) goto parse_r;
        break;
      }
      
      // repeated uint64 r = 3;
      case 3: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
         parse_r:
          DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
                   ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
                 1, 24, input, this->mutable_r())));
        } else if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag)
                   == ::google::protobuf::internal::WireFormatLite::
                      WIRETYPE_LENGTH_DELIMITED) {
          DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
                   ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
                 input, this->mutable_r())));
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(24)) goto parse_r;
        if (input->ExpectAtEnd()) return true;
        break;
      }
      
      default: {
      handle_uninterpreted:
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
          return true;
        }
        DO_(::google::protobuf::internal::WireFormat::SkipField(
              input, tag, mutable_unknown_fields()));
        break;
      }
    }
  }
  return true;
#undef DO_
}

void BetaNegativeBinomial_GridPrior::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  // repeated float alpha = 1;
  for (int i = 0; i < this->alpha_size(); i++) {
    ::google::protobuf::internal::WireFormatLite::WriteFloat(
      1, this->alpha(i), output);
  }
  
  // repeated float beta = 2;
  for (int i = 0; i < this->beta_size(); i++) {
    ::google::protobuf::internal::WireFormatLite::WriteFloat(
      2, this->beta(i), output);
  }
  
  // repeated uint64 r = 3;
  for (int i = 0; i < this->r_size(); i++) {
    ::google::protobuf::internal::WireFormatLite::WriteUInt64(
      3, this->r(i), output);
  }
  
  if (!unknown_fields().empty()) {
    ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
        unknown_fields(), output);
  }
}

::google::protobuf::uint8* BetaNegativeBinomial_GridPrior::SerializeWithCachedSizesToArray(
    ::google::protobuf::uint8* target) const {
  // repeated float alpha = 1;
  for (int i = 0; i < this->alpha_size(); i++) {
    target = ::google::protobuf::internal::WireFormatLite::
      WriteFloatToArray(1, this->alpha(i), target);
  }
  
  // repeated float beta = 2;
  for (int i = 0; i < this->beta_size(); i++) {
    target = ::google::protobuf::internal::WireFormatLite::
      WriteFloatToArray(2, this->beta(i), target);
  }
  
  // repeated uint64 r = 3;
  for (int i = 0; i < this->r_size(); i++) {
    target = ::google::protobuf::internal::WireFormatLite::
      WriteUInt64ToArray(3, this->r(i), target);
  }
  
  if (!unknown_fields().empty()) {
    target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
        unknown_fields(), target);
  }
  return target;
}

int BetaNegativeBinomial_GridPrior::ByteSize() const {
  int total_size = 0;
  
  // repeated float alpha = 1;
  {
    int data_size = 0;
    data_size = 4 * this->alpha_size();
    total_size += 1 * this->alpha_size() + data_size;
  }
  
  // repeated float beta = 2;
  {
    int data_size = 0;
    data_size = 4 * this->beta_size();
    total_size += 1 * this->beta_size() + data_size;
  }
  
  // repeated uint64 r = 3;
  {
    int data_size = 0;
    for (int i = 0; i < this->r_size(); i++) {
      data_size += ::google::protobuf::internal::WireFormatLite::
        UInt64Size(this->r(i));
    }
    total_size += 1 * this->r_size() + data_size;
  }
  
  if (!unknown_fields().empty()) {
    total_size +=
      ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
        unknown_fields());
  }
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = total_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void BetaNegativeBinomial_GridPrior::MergeFrom(const ::google::protobuf::Message& from) {
  GOOGLE_CHECK_NE(&from, this);
  const BetaNegativeBinomial_GridPrior* source =
    ::google::protobuf::internal::dynamic_cast_if_available<const BetaNegativeBinomial_GridPrior*>(
      &from);
  if (source == NULL) {
    ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  } else {
    MergeFrom(*source);
  }
}

void BetaNegativeBinomial_GridPrior::MergeFrom(const BetaNegativeBinomial_GridPrior& from) {
  GOOGLE_CHECK_NE(&from, this);
  alpha_.MergeFrom(from.alpha_);
  beta_.MergeFrom(from.beta_);
  r_.MergeFrom(from.r_);
  mutable_unknown_fields()->MergeFrom(from.unknown_fields());
}

void BetaNegativeBinomial_GridPrior::CopyFrom(const ::google::protobuf::Message& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

void BetaNegativeBinomial_GridPrior::CopyFrom(const BetaNegativeBinomial_GridPrior& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool BetaNegativeBinomial_GridPrior::IsInitialized() const {
  
  return true;
}

void BetaNegativeBinomial_GridPrior::Swap(BetaNegativeBinomial_GridPrior* other) {
  if (other != this) {
    alpha_.Swap(&other->alpha_);
    beta_.Swap(&other->beta_);
    r_.Swap(&other->r_);
    std::swap(_has_bits_[0], other->_has_bits_[0]);
    _unknown_fields_.Swap(&other->_unknown_fields_);
    std::swap(_cached_size_, other->_cached_size_);
  }
}

::google::protobuf::Metadata BetaNegativeBinomial_GridPrior::GetMetadata() const {
  protobuf_AssignDescriptorsOnce();
  ::google::protobuf::Metadata metadata;
  metadata.descriptor = BetaNegativeBinomial_GridPrior_descriptor_;
  metadata.reflection = BetaNegativeBinomial_GridPrior_reflection_;
  return metadata;
}


// -------------------------------------------------------------------

#ifndef _MSC_VER
const int BetaNegativeBinomial_Group::kCountFieldNumber;
const int BetaNegativeBinomial_Group::kSumFieldNumber;
#endif  // !_MSC_VER

BetaNegativeBinomial_Group::BetaNegativeBinomial_Group()
  : ::google::protobuf::Message() {
  SharedCtor();
}

void BetaNegativeBinomial_Group::InitAsDefaultInstance() {
}

BetaNegativeBinomial_Group::BetaNegativeBinomial_Group(const BetaNegativeBinomial_Group& from)
  : ::google::protobuf::Message() {
  SharedCtor();
  MergeFrom(from);
}

void BetaNegativeBinomial_Group::SharedCtor() {
  _cached_size_ = 0;
  count_ = GOOGLE_ULONGLONG(0);
  sum_ = GOOGLE_ULONGLONG(0);
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}

BetaNegativeBinomial_Group::~BetaNegativeBinomial_Group() {
  SharedDtor();
}

void BetaNegativeBinomial_Group::SharedDtor() {
  if (this != default_instance_) {
  }
}

void BetaNegativeBinomial_Group::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* BetaNegativeBinomial_Group::descriptor() {
  protobuf_AssignDescriptorsOnce();
  return BetaNegativeBinomial_Group_descriptor_;
}

const BetaNegativeBinomial_Group& BetaNegativeBinomial_Group::default_instance() {
  if (default_instance_ == NULL) protobuf_AddDesc_distributions_2fio_2fschema_2eproto();  return *default_instance_;
}

BetaNegativeBinomial_Group* BetaNegativeBinomial_Group::default_instance_ = NULL;

BetaNegativeBinomial_Group* BetaNegativeBinomial_Group::New() const {
  return new BetaNegativeBinomial_Group;
}

void BetaNegativeBinomial_Group::Clear() {
  if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    count_ = GOOGLE_ULONGLONG(0);
    sum_ = GOOGLE_ULONGLONG(0);
  }
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
  mutable_unknown_fields()->Clear();
}

bool BetaNegativeBinomial_Group::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!(EXPRESSION)) return false
  ::google::protobuf::uint32 tag;
  while ((tag = input->ReadTag()) != 0) {
    switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
      // required uint64 count = 1;
      case 1: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
                 input, &count_)));
          set_has_count();
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(16)) goto parse_sum;
        break;
      }
      
      // required uint64 sum = 2;
      case 2: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
         parse_sum:
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
                 input, &sum_)));
          set_has_sum();
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectAtEnd()) return true;
        break;
      }
      
      default: {
      handle_uninterpreted:
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
          return true;
        }
        DO_(::google::protobuf::internal::WireFormat::SkipField(
              input, tag, mutable_unknown_fields()));
        break;
      }
    }
  }
  return true;
#undef DO_
}

void BetaNegativeBinomial_Group::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  // required uint64 count = 1;
  if (has_count()) {
    ::google::protobuf::internal::WireFormatLite::WriteUInt64(1, this->count(), output);
  }
  
  // required uint64 sum = 2;
  if (has_sum()) {
    ::google::protobuf::internal::WireFormatLite::WriteUInt64(2, this->sum(), output);
  }
  
  if (!unknown_fields().empty()) {
    ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
        unknown_fields(), output);
  }
}

::google::protobuf::uint8* BetaNegativeBinomial_Group::SerializeWithCachedSizesToArray(
    ::google::protobuf::uint8* target) const {
  // required uint64 count = 1;
  if (has_count()) {
    target = ::google::protobuf::internal::WireFormatLite::WriteUInt64ToArray(1, this->count(), target);
  }
  
  // required uint64 sum = 2;
  if (has_sum()) {
    target = ::google::protobuf::internal::WireFormatLite::WriteUInt64ToArray(2, this->sum(), target);
  }
  
  if (!unknown_fields().empty()) {
    target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
        unknown_fields(), target);
  }
  return target;
}

int BetaNegativeBinomial_Group::ByteSize() const {
  int total_size = 0;
  
  if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    // required uint64 count = 1;
    if (has_count()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::UInt64Size(
          this->count());
    }
    
    // required uint64 sum = 2;
    if (has_sum()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::UInt64Size(
          this->sum());
    }
    
  }
  if (!unknown_fields().empty()) {
    total_size +=
      ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
        unknown_fields());
  }
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = total_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void BetaNegativeBinomial_Group::MergeFrom(const ::google::protobuf::Message& from) {
  GOOGLE_CHECK_NE(&from, this);
  const BetaNegativeBinomial_Group* source =
    ::google::protobuf::internal::dynamic_cast_if_available<const BetaNegativeBinomial_Group*>(
      &from);
  if (source == NULL) {
    ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  } else {
    MergeFrom(*source);
  }
}

void BetaNegativeBinomial_Group::MergeFrom(const BetaNegativeBinomial_Group& from) {
  GOOGLE_CHECK_NE(&from, this);
  if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    if (from.has_count()) {
      set_count(from.count());
    }
    if (from.has_sum()) {
      set_sum(from.sum());
    }
  }
  mutable_unknown_fields()->MergeFrom(from.unknown_fields());
}

void BetaNegativeBinomial_Group::CopyFrom(const ::google::protobuf::Message& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

void BetaNegativeBinomial_Group::CopyFrom(const BetaNegativeBinomial_Group& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool BetaNegativeBinomial_Group::IsInitialized() const {
  if ((_has_bits_[0] & 0x00000003) != 0x00000003) return false;
  
  return true;
}

void BetaNegativeBinomial_Group::Swap(BetaNegativeBinomial_Group* other) {
  if (other != this) {
    std::swap(count_, other->count_);
    std::swap(sum_, other->sum_);
    std::swap(_has_bits_[0], other->_has_bits_[0]);
    _unknown_fields_.Swap(&other->_unknown_fields_);
    std::swap(_cached_size_, other->_cached_size_);
  }
}

::google::protobuf::Metadata BetaNegativeBinomial_Group::GetMetadata() const {
  protobuf_AssignDescriptorsOnce();
  ::google::protobuf::Metadata metadata;
  metadata.descriptor = BetaNegativeBinomial_Group_descriptor_;
  metadata.reflection = BetaNegativeBinomial_Group_reflection_;
  return metadata;
}


// -------------------------------------------------------------------

#ifndef _MSC_VER
#endif  // !_MSC_VER

BetaNegativeBinomial::BetaNegativeBinomial()
  : ::google::protobuf::Message() {
  SharedCtor();
}

void BetaNegativeBinomial::InitAsDefaultInstance() {
}

BetaNegativeBinomial::BetaNegativeBinomial(const BetaNegativeBinomial& from)
  : ::google::protobuf::Message() {
  SharedCtor();
  MergeFrom(from);
}

void BetaNegativeBinomial::SharedCtor() {
  _cached_size_ = 0;
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}

BetaNegativeBinomial::~BetaNegativeBinomial() {
  SharedDtor();
}

void BetaNegativeBinomial::SharedDtor() {
  if (this != default_instance_) {
  }
}

void BetaNegativeBinomial::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* BetaNegativeBinomial::descriptor() {
  protobuf_AssignDescriptorsOnce();
  return BetaNegativeBinomial_descriptor_;
}

const BetaNegativeBinomial& BetaNegativeBinomial::default_instance() {
  if (default_instance_ == NULL) protobuf_AddDesc_distributions_2fio_2fschema_2eproto();  return *default_instance_;
}

BetaNegativeBinomial* BetaNegativeBinomial::default_instance_ = NULL;

BetaNegativeBinomial* BetaNegativeBinomial::New() const {
  return new BetaNegativeBinomial;
}

void BetaNegativeBinomial::Clear() {
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
  mutable_unknown_fields()->Clear();
}

bool BetaNegativeBinomial::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!(EXPRESSION)) return false
  ::google::protobuf::uint32 tag;
  while ((tag = input->ReadTag()) != 0) {
    if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
        ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
      return true;
    }
    DO_(::google::protobuf::internal::WireFormat::SkipField(
          input, tag, mutable_unknown_fields()));
  }
  return true;
#undef DO_
}

void BetaNegativeBinomial::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  if (!unknown_fields().empty()) {
    ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
        unknown_fields(), output);
  }
}

::google::protobuf::uint8* BetaNegativeBinomial::SerializeWithCachedSizesToArray(
    ::google::protobuf::uint8* target) const {
  if (!unknown_fields().empty()) {
    target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
        unknown_fields(), target);
  }
  return target;
}

int BetaNegativeBinomial::ByteSize() const {
  int total_size = 0;
  
  if (!unknown_fields().empty()) {
    total_size +=
      ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
        unknown_fields());
  }
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = total_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void BetaNegativeBinomial::MergeFrom(const ::google::protobuf::Message& from) {
  GOOGLE_CHECK_NE(&from, this);
  const BetaNegativeBinomial* source =
    ::google::protobuf::internal::dynamic_cast_if_available<const BetaNegativeBinomial*>(
      &from);
  if (source == NULL) {
    ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  } else {
    MergeFrom(*source);
  }
}

void BetaNegativeBinomial::MergeFrom(const BetaNegativeBinomial& from) {
  GOOGLE_CHECK_NE(&from, this);
  mutable_unknown_fields()->MergeFrom(from.unknown_fields());
}

void BetaNegativeBinomial::CopyFrom(const ::google::protobuf::Message& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

void BetaNegativeBinomial::CopyFrom(const BetaNegativeBinomial& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool BetaNegativeBinomial::IsInitialized() const {
  
  return true;
}

void BetaNegativeBinomial::Swap(BetaNegativeBinomial* other) {
  if (other != this) {
    _unknown_fields_.Swap(&other->_unknown_fields_);
    std::swap(_cached_size_, other->_cached_size_);
  }
}

::google::protobuf::Metadata BetaNegativeBinomial::GetMetadata() const {
  protobuf_AssignDescriptorsOnce();
  ::google::protobuf::Metadata metadata;
  metadata.descriptor = BetaNegativeBinomial_descriptor_;
  metadata.reflection = BetaNegativeBinomial_reflection_;
  return metadata;
}


// ===================================================================

#ifndef _MSC_VER
const int NormalInverseChiSq_Shared::kMuFieldNumber;
const int NormalInverseChiSq_Shared::kKappaFieldNumber;
const int NormalInverseChiSq_Shared::kSigmasqFieldNumber;
const int NormalInverseChiSq_Shared::kNuFieldNumber;
#endif  // !_MSC_VER

NormalInverseChiSq_Shared::NormalInverseChiSq_Shared()
  : ::google::protobuf::Message() {
  SharedCtor();
}

void NormalInverseChiSq_Shared::InitAsDefaultInstance() {
}

NormalInverseChiSq_Shared::NormalInverseChiSq_Shared(const NormalInverseChiSq_Shared& from)
  : ::google::protobuf::Message() {
  SharedCtor();
  MergeFrom(from);
}

void NormalInverseChiSq_Shared::SharedCtor() {
  _cached_size_ = 0;
  mu_ = 0;
  kappa_ = 0;
  sigmasq_ = 0;
  nu_ = 0;
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}

NormalInverseChiSq_Shared::~NormalInverseChiSq_Shared() {
  SharedDtor();
}

void NormalInverseChiSq_Shared::SharedDtor() {
  if (this != default_instance_) {
  }
}

void NormalInverseChiSq_Shared::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* NormalInverseChiSq_Shared::descriptor() {
  protobuf_AssignDescriptorsOnce();
  return NormalInverseChiSq_Shared_descriptor_;
}

const NormalInverseChiSq_Shared& NormalInverseChiSq_Shared::default_instance() {
  if (default_instance_ == NULL) protobuf_AddDesc_distributions_2fio_2fschema_2eproto();  return *default_instance_;
}

NormalInverseChiSq_Shared* NormalInverseChiSq_Shared::default_instance_ = NULL;

NormalInverseChiSq_Shared* NormalInverseChiSq_Shared::New() const {
  return new NormalInverseChiSq_Shared;
}

void NormalInverseChiSq_Shared::Clear() {
  if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    mu_ = 0;
    kappa_ = 0;
    sigmasq_ = 0;
    nu_ = 0;
  }
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
  mutable_unknown_fields()->Clear();
}

bool NormalInverseChiSq_Shared::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!(EXPRESSION)) return false
  ::google::protobuf::uint32 tag;
  while ((tag = input->ReadTag()) != 0) {
    switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
      // required float mu = 1;
      case 1: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_FIXED32) {
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 input, &mu_)));
          set_has_mu();
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(21)) goto parse_kappa;
        break;
      }
      
      // required float kappa = 2;
      case 2: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_FIXED32) {
         parse_kappa:
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 input, &kappa_)));
          set_has_kappa();
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(29)) goto parse_sigmasq;
        break;
      }
      
      // required float sigmasq = 3;
      case 3: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_FIXED32) {
         parse_sigmasq:
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 input, &sigmasq_)));
          set_has_sigmasq();
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(37)) goto parse_nu;
        break;
      }
      
      // required float nu = 4;
      case 4: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_FIXED32) {
         parse_nu:
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 input, &nu_)));
          set_has_nu();
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectAtEnd()) return true;
        break;
      }
      
      default: {
      handle_uninterpreted:
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
          return true;
        }
        DO_(::google::protobuf::internal::WireFormat::SkipField(
              input, tag, mutable_unknown_fields()));
        break;
      }
    }
  }
  return true;
#undef DO_
}

void NormalInverseChiSq_Shared::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  // required float mu = 1;
  if (has_mu()) {
    ::google::protobuf::internal::WireFormatLite::WriteFloat(1, this->mu(), output);
  }
  
  // required float kappa = 2;
  if (has_kappa()) {
    ::google::protobuf::internal::WireFormatLite::WriteFloat(2, this->kappa(), output);
  }
  
  // required float sigmasq = 3;
  if (has_sigmasq()) {
    ::google::protobuf::internal::WireFormatLite::WriteFloat(3, this->sigmasq(), output);
  }
  
  // required float nu = 4;
  if (has_nu()) {
    ::google::protobuf::internal::WireFormatLite::WriteFloat(4, this->nu(), output);
  }
  
  if (!unknown_fields().empty()) {
    ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
        unknown_fields(), output);
  }
}

::google::protobuf::uint8* NormalInverseChiSq_Shared::SerializeWithCachedSizesToArray(
    ::google::protobuf::uint8* target) const {
  // required float mu = 1;
  if (has_mu()) {
    target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(1, this->mu(), target);
  }
  
  // required float kappa = 2;
  if (has_kappa()) {
    target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(2, this->kappa(), target);
  }
  
  // required float sigmasq = 3;
  if (has_sigmasq()) {
    target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(3, this->sigmasq(), target);
  }
  
  // required float nu = 4;
  if (has_nu()) {
    target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(4, this->nu(), target);
  }
  
  if (!unknown_fields().empty()) {
    target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
        unknown_fields(), target);
  }
  return target;
}

int NormalInverseChiSq_Shared::ByteSize() const {
  int total_size = 0;
  
  if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    // required float mu = 1;
    if (has_mu()) {
      total_size += 1 + 4;
    }
    
    // required float kappa = 2;
    if (has_kappa()) {
      total_size += 1 + 4;
    }
    
    // required float sigmasq = 3;
    if (has_sigmasq()) {
      total_size += 1 + 4;
    }
    
    // required float nu = 4;
    if (has_nu()) {
      total_size += 1 + 4;
    }
    
  }
  if (!unknown_fields().empty()) {
    total_size +=
      ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
        unknown_fields());
  }
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = total_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void NormalInverseChiSq_Shared::MergeFrom(const ::google::protobuf::Message& from) {
  GOOGLE_CHECK_NE(&from, this);
  const NormalInverseChiSq_Shared* source =
    ::google::protobuf::internal::dynamic_cast_if_available<const NormalInverseChiSq_Shared*>(
      &from);
  if (source == NULL) {
    ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  } else {
    MergeFrom(*source);
  }
}

void NormalInverseChiSq_Shared::MergeFrom(const NormalInverseChiSq_Shared& from) {
  GOOGLE_CHECK_NE(&from, this);
  if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    if (from.has_mu()) {
      set_mu(from.mu());
    }
    if (from.has_kappa()) {
      set_kappa(from.kappa());
    }
    if (from.has_sigmasq()) {
      set_sigmasq(from.sigmasq());
    }
    if (from.has_nu()) {
      set_nu(from.nu());
    }
  }
  mutable_unknown_fields()->MergeFrom(from.unknown_fields());
}

void NormalInverseChiSq_Shared::CopyFrom(const ::google::protobuf::Message& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

void NormalInverseChiSq_Shared::CopyFrom(const NormalInverseChiSq_Shared& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool NormalInverseChiSq_Shared::IsInitialized() const {
  if ((_has_bits_[0] & 0x0000000f) != 0x0000000f) return false;
  
  return true;
}

void NormalInverseChiSq_Shared::Swap(NormalInverseChiSq_Shared* other) {
  if (other != this) {
    std::swap(mu_, other->mu_);
    std::swap(kappa_, other->kappa_);
    std::swap(sigmasq_, other->sigmasq_);
    std::swap(nu_, other->nu_);
    std::swap(_has_bits_[0], other->_has_bits_[0]);
    _unknown_fields_.Swap(&other->_unknown_fields_);
    std::swap(_cached_size_, other->_cached_size_);
  }
}

::google::protobuf::Metadata NormalInverseChiSq_Shared::GetMetadata() const {
  protobuf_AssignDescriptorsOnce();
  ::google::protobuf::Metadata metadata;
  metadata.descriptor = NormalInverseChiSq_Shared_descriptor_;
  metadata.reflection = NormalInverseChiSq_Shared_reflection_;
  return metadata;
}


// -------------------------------------------------------------------

#ifndef _MSC_VER
const int NormalInverseChiSq_GridPrior::kMuFieldNumber;
const int NormalInverseChiSq_GridPrior::kKappaFieldNumber;
const int NormalInverseChiSq_GridPrior::kSigmasqFieldNumber;
const int NormalInverseChiSq_GridPrior::kNuFieldNumber;
#endif  // !_MSC_VER

NormalInverseChiSq_GridPrior::NormalInverseChiSq_GridPrior()
  : ::google::protobuf::Message() {
  SharedCtor();
}

void NormalInverseChiSq_GridPrior::InitAsDefaultInstance() {
}

NormalInverseChiSq_GridPrior::NormalInverseChiSq_GridPrior(const NormalInverseChiSq_GridPrior& from)
  : ::google::protobuf::Message() {
  SharedCtor();
  MergeFrom(from);
}

void NormalInverseChiSq_GridPrior::SharedCtor() {
  _cached_size_ = 0;
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}

NormalInverseChiSq_GridPrior::~NormalInverseChiSq_GridPrior() {
  SharedDtor();
}

void NormalInverseChiSq_GridPrior::SharedDtor() {
  if (this != default_instance_) {
  }
}

void NormalInverseChiSq_GridPrior::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* NormalInverseChiSq_GridPrior::descriptor() {
  protobuf_AssignDescriptorsOnce();
  return NormalInverseChiSq_GridPrior_descriptor_;
}

const NormalInverseChiSq_GridPrior& NormalInverseChiSq_GridPrior::default_instance() {
  if (default_instance_ == NULL) protobuf_AddDesc_distributions_2fio_2fschema_2eproto();  return *default_instance_;
}

NormalInverseChiSq_GridPrior* NormalInverseChiSq_GridPrior::default_instance_ = NULL;

NormalInverseChiSq_GridPrior* NormalInverseChiSq_GridPrior::New() const {
  return new NormalInverseChiSq_GridPrior;
}

void NormalInverseChiSq_GridPrior::Clear() {
  mu_.Clear();
  kappa_.Clear();
  sigmasq_.Clear();
  nu_.Clear();
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
  mutable_unknown_fields()->Clear();
}

bool NormalInverseChiSq_GridPrior::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!(EXPRESSION)) return false
  ::google::protobuf::uint32 tag;
  while ((tag = input->ReadTag()) != 0) {
    switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
      // repeated float mu = 1;
      case 1: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_FIXED32) {
         parse_mu:
          DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 1, 13, input, this->mutable_mu())));
        } else if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag)
                   == ::google::protobuf::internal::WireFormatLite::
                      WIRETYPE_LENGTH_DELIMITED) {
          DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 input, this->mutable_mu())));
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(13)) goto parse_mu;
        if (input->ExpectTag(21)) goto parse_kappa;
        break;
      }
      
      // repeated float kappa = 2;
      case 2: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_FIXED32) {
         parse_kappa:
          DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 1, 21, input, this->mutable_kappa())));
        } else if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag)
                   == ::google::protobuf::internal::WireFormatLite::
                      WIRETYPE_LENGTH_DELIMITED) {
          DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 input, this->mutable_kappa())));
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(21)) goto parse_kappa;
        if (input->ExpectTag(29)) goto parse_sigmasq;
        break;
      }
      
      // repeated float sigmasq = 3;
      case 3: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_FIXED32) {
         parse_sigmasq:
          DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 1, 29, input, this->mutable_sigmasq())));
        } else if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag)
                   == ::google::protobuf::internal::WireFormatLite::
                      WIRETYPE_LENGTH_DELIMITED) {
          DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 input, this->mutable_sigmasq())));
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(29)) goto parse_sigmasq;
        if (input->ExpectTag(37)) goto parse_nu;
        break;
      }
      
      // repeated float nu = 4;
      case 4: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_FIXED32) {
         parse_nu:
          DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 1, 37, input, this->mutable_nu())));
        } else if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag)
                   == ::google::protobuf::internal::WireFormatLite::
                      WIRETYPE_LENGTH_DELIMITED) {
          DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 input, this->mutable_nu())));
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(37)) goto parse_nu;
        if (input->ExpectAtEnd()) return true;
        break;
      }
      
      default: {
      handle_uninterpreted:
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
          return true;
        }
        DO_(::google::protobuf::internal::WireFormat::SkipField(
              input, tag, mutable_unknown_fields()));
        break;
      }
    }
  }
  return true;
#undef DO_
}

void NormalInverseChiSq_GridPrior::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  // repeated float mu = 1;
  for (int i = 0; i < this->mu_size(); i++) {
    ::google::protobuf::internal::WireFormatLite::WriteFloat(
      1, this->mu(i), output);
  }
  
  // repeated float kappa = 2;
  for (int i = 0; i < this->kappa_size(); i++) {
    ::google::protobuf::internal::WireFormatLite::WriteFloat(
      2, this->kappa(i), output);
  }
  
  // repeated float sigmasq = 3;
  for (int i = 0; i < this->sigmasq_size(); i++) {
    ::google::protobuf::internal::WireFormatLite::WriteFloat(
      3, this->sigmasq(i), output);
  }
  
  // repeated float nu = 4;
  for (int i = 0; i < this->nu_size(); i++) {
    ::google::protobuf::internal::WireFormatLite::WriteFloat(
      4, this->nu(i), output);
  }
  
  if (!unknown_fields().empty()) {
    ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
        unknown_fields(), output);
  }
}

::google::protobuf::uint8* NormalInverseChiSq_GridPrior::SerializeWithCachedSizesToArray(
    ::google::protobuf::uint8* target) const {
  // repeated float mu = 1;
  for (int i = 0; i < this->mu_size(); i++) {
    target = ::google::protobuf::internal::WireFormatLite::
      WriteFloatToArray(1, this->mu(i), target);
  }
  
  // repeated float kappa = 2;
  for (int i = 0; i < this->kappa_size(); i++) {
    target = ::google::protobuf::internal::WireFormatLite::
      WriteFloatToArray(2, this->kappa(i), target);
  }
  
  // repeated float sigmasq = 3;
  for (int i = 0; i < this->sigmasq_size(); i++) {
    target = ::google::protobuf::internal::WireFormatLite::
      WriteFloatToArray(3, this->sigmasq(i), target);
  }
  
  // repeated float nu = 4;
  for (int i = 0; i < this->nu_size(); i++) {
    target = ::google::protobuf::internal::WireFormatLite::
      WriteFloatToArray(4, this->nu(i), target);
  }
  
  if (!unknown_fields().empty()) {
    target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
        unknown_fields(), target);
  }
  return target;
}

int NormalInverseChiSq_GridPrior::ByteSize() const {
  int total_size = 0;
  
  // repeated float mu = 1;
  {
    int data_size = 0;
    data_size = 4 * this->mu_size();
    total_size += 1 * this->mu_size() + data_size;
  }
  
  // repeated float kappa = 2;
  {
    int data_size = 0;
    data_size = 4 * this->kappa_size();
    total_size += 1 * this->kappa_size() + data_size;
  }
  
  // repeated float sigmasq = 3;
  {
    int data_size = 0;
    data_size = 4 * this->sigmasq_size();
    total_size += 1 * this->sigmasq_size() + data_size;
  }
  
  // repeated float nu = 4;
  {
    int data_size = 0;
    data_size = 4 * this->nu_size();
    total_size += 1 * this->nu_size() + data_size;
  }
  
  if (!unknown_fields().empty()) {
    total_size +=
      ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
        unknown_fields());
  }
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = total_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void NormalInverseChiSq_GridPrior::MergeFrom(const ::google::protobuf::Message& from) {
  GOOGLE_CHECK_NE(&from, this);
  const NormalInverseChiSq_GridPrior* source =
    ::google::protobuf::internal::dynamic_cast_if_available<const NormalInverseChiSq_GridPrior*>(
      &from);
  if (source == NULL) {
    ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  } else {
    MergeFrom(*source);
  }
}

void NormalInverseChiSq_GridPrior::MergeFrom(const NormalInverseChiSq_GridPrior& from) {
  GOOGLE_CHECK_NE(&from, this);
  mu_.MergeFrom(from.mu_);
  kappa_.MergeFrom(from.kappa_);
  sigmasq_.MergeFrom(from.sigmasq_);
  nu_.MergeFrom(from.nu_);
  mutable_unknown_fields()->MergeFrom(from.unknown_fields());
}

void NormalInverseChiSq_GridPrior::CopyFrom(const ::google::protobuf::Message& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

void NormalInverseChiSq_GridPrior::CopyFrom(const NormalInverseChiSq_GridPrior& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool NormalInverseChiSq_GridPrior::IsInitialized() const {
  
  return true;
}

void NormalInverseChiSq_GridPrior::Swap(NormalInverseChiSq_GridPrior* other) {
  if (other != this) {
    mu_.Swap(&other->mu_);
    kappa_.Swap(&other->kappa_);
    sigmasq_.Swap(&other->sigmasq_);
    nu_.Swap(&other->nu_);
    std::swap(_has_bits_[0], other->_has_bits_[0]);
    _unknown_fields_.Swap(&other->_unknown_fields_);
    std::swap(_cached_size_, other->_cached_size_);
  }
}

::google::protobuf::Metadata NormalInverseChiSq_GridPrior::GetMetadata() const {
  protobuf_AssignDescriptorsOnce();
  ::google::protobuf::Metadata metadata;
  metadata.descriptor = NormalInverseChiSq_GridPrior_descriptor_;
  metadata.reflection = NormalInverseChiSq_GridPrior_reflection_;
  return metadata;
}


// -------------------------------------------------------------------

#ifndef _MSC_VER
const int NormalInverseChiSq_Group::kCountFieldNumber;
const int NormalInverseChiSq_Group::kMeanFieldNumber;
const int NormalInverseChiSq_Group::kCountTimesVarianceFieldNumber;
#endif  // !_MSC_VER

NormalInverseChiSq_Group::NormalInverseChiSq_Group()
  : ::google::protobuf::Message() {
  SharedCtor();
}

void NormalInverseChiSq_Group::InitAsDefaultInstance() {
}

NormalInverseChiSq_Group::NormalInverseChiSq_Group(const NormalInverseChiSq_Group& from)
  : ::google::protobuf::Message() {
  SharedCtor();
  MergeFrom(from);
}

void NormalInverseChiSq_Group::SharedCtor() {
  _cached_size_ = 0;
  count_ = GOOGLE_ULONGLONG(0);
  mean_ = 0;
  count_times_variance_ = 0;
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}

NormalInverseChiSq_Group::~NormalInverseChiSq_Group() {
  SharedDtor();
}

void NormalInverseChiSq_Group::SharedDtor() {
  if (this != default_instance_) {
  }
}

void NormalInverseChiSq_Group::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* NormalInverseChiSq_Group::descriptor() {
  protobuf_AssignDescriptorsOnce();
  return NormalInverseChiSq_Group_descriptor_;
}

const NormalInverseChiSq_Group& NormalInverseChiSq_Group::default_instance() {
  if (default_instance_ == NULL) protobuf_AddDesc_distributions_2fio_2fschema_2eproto();  return *default_instance_;
}

NormalInverseChiSq_Group* NormalInverseChiSq_Group::default_instance_ = NULL;

NormalInverseChiSq_Group* NormalInverseChiSq_Group::New() const {
  return new NormalInverseChiSq_Group;
}

void NormalInverseChiSq_Group::Clear() {
  if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    count_ = GOOGLE_ULONGLONG(0);
    mean_ = 0;
    count_times_variance_ = 0;
  }
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
  mutable_unknown_fields()->Clear();
}

bool NormalInverseChiSq_Group::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!(EXPRESSION)) return false
  ::google::protobuf::uint32 tag;
  while ((tag = input->ReadTag()) != 0) {
    switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
      // required uint64 count = 1;
      case 1: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
                 input, &count_)));
          set_has_count();
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(21)) goto parse_mean;
        break;
      }
      
      // required float mean = 2;
      case 2: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_FIXED32) {
         parse_mean:
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 input, &mean_)));
          set_has_mean();
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(29)) goto parse_count_times_variance;
        break;
      }
      
      // required float count_times_variance = 3;
      case 3: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_FIXED32) {
         parse_count_times_variance:
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
                 input, &count_times_variance_)));
          set_has_count_times_variance();
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectAtEnd()) return true;
        break;
      }
      
      default: {
      handle_uninterpreted:
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
          return true;
        }
        DO_(::google::protobuf::internal::WireFormat::SkipField(
              input, tag, mutable_unknown_fields()));
        break;
      }
    }
  }
  return true;
#undef DO_
}

void NormalInverseChiSq_Group::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  // required uint64 count = 1;
  if (has_count()) {
    ::google::protobuf::internal::WireFormatLite::WriteUInt64(1, this->count(), output);
  }
  
  // required float mean = 2;
  if (has_mean()) {
    ::google::protobuf::internal::WireFormatLite::WriteFloat(2, this->mean(), output);
  }
  
  // required float count_times_variance = 3;
  if (has_count_times_variance()) {
    ::google::protobuf::internal::WireFormatLite::WriteFloat(3, this->count_times_variance(), output);
  }
  
  if (!unknown_fields().empty()) {
    ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
        unknown_fields(), output);
  }
}

::google::protobuf::uint8* NormalInverseChiSq_Group::SerializeWithCachedSizesToArray(
    ::google::protobuf::uint8* target) const {
  // required uint64 count = 1;
  if (has_count()) {
    target = ::google::protobuf::internal::WireFormatLite::WriteUInt64ToArray(1, this->count(), target);
  }
  
  // required float mean = 2;
  if (has_mean()) {
    target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(2, this->mean(), target);
  }
  
  // required float count_times_variance = 3;
  if (has_count_times_variance()) {
    target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(3, this->count_times_variance(), target);
  }
  
  if (!unknown_fields().empty()) {
    target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
        unknown_fields(), target);
  }
  return target;
}

int NormalInverseChiSq_Group::ByteSize() const {
  int total_size = 0;
  
  if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    // required uint64 count = 1;
    if (has_count()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::UInt64Size(
          this->count());
    }
    
    // required float mean = 2;
    if (has_mean()) {
      total_size += 1 + 4;
    }
    
    // required float count_times_variance = 3;
    if (has_count_times_variance()) {
      total_size += 1 + 4;
    }
    
  }
  if (!unknown_fields().empty()) {
    total_size +=
      ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
        unknown_fields());
  }
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = total_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void NormalInverseChiSq_Group::MergeFrom(const ::google::protobuf::Message& from) {
  GOOGLE_CHECK_NE(&from, this);
  const NormalInverseChiSq_Group* source =
    ::google::protobuf::internal::dynamic_cast_if_available<const NormalInverseChiSq_Group*>(
      &from);
  if (source == NULL) {
    ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  } else {
    MergeFrom(*source);
  }
}

void NormalInverseChiSq_Group::MergeFrom(const NormalInverseChiSq_Group& from) {
  GOOGLE_CHECK_NE(&from, this);
  if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    if (from.has_count()) {
      set_count(from.count());
    }
    if (from.has_mean()) {
      set_mean(from.mean());
    }
    if (from.has_count_times_variance()) {
      set_count_times_variance(from.count_times_variance());
    }
  }
  mutable_unknown_fields()->MergeFrom(from.unknown_fields());
}

void NormalInverseChiSq_Group::CopyFrom(const ::google::protobuf::Message& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

void NormalInverseChiSq_Group::CopyFrom(const NormalInverseChiSq_Group& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool NormalInverseChiSq_Group::IsInitialized() const {
  if ((_has_bits_[0] & 0x00000007) != 0x00000007) return false;
  
  return true;
}

void NormalInverseChiSq_Group::Swap(NormalInverseChiSq_Group* other) {
  if (other != this) {
    std::swap(count_, other->count_);
    std::swap(mean_, other->mean_);
    std::swap(count_times_variance_, other->count_times_variance_);
    std::swap(_has_bits_[0], other->_has_bits_[0]);
    _unknown_fields_.Swap(&other->_unknown_fields_);
    std::swap(_cached_size_, other->_cached_size_);
  }
}

::google::protobuf::Metadata NormalInverseChiSq_Group::GetMetadata() const {
  protobuf_AssignDescriptorsOnce();
  ::google::protobuf::Metadata metadata;
  metadata.descriptor = NormalInverseChiSq_Group_descriptor_;
  metadata.reflection = NormalInverseChiSq_Group_reflection_;
  return metadata;
}


// -------------------------------------------------------------------

#ifndef _MSC_VER
#endif  // !_MSC_VER

NormalInverseChiSq::NormalInverseChiSq()
  : ::google::protobuf::Message() {
  SharedCtor();
}

void NormalInverseChiSq::InitAsDefaultInstance() {
}

NormalInverseChiSq::NormalInverseChiSq(const NormalInverseChiSq& from)
  : ::google::protobuf::Message() {
  SharedCtor();
  MergeFrom(from);
}

void NormalInverseChiSq::SharedCtor() {
  _cached_size_ = 0;
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}

NormalInverseChiSq::~NormalInverseChiSq() {
  SharedDtor();
}

void NormalInverseChiSq::SharedDtor() {
  if (this != default_instance_) {
  }
}

void NormalInverseChiSq::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* NormalInverseChiSq::descriptor() {
  protobuf_AssignDescriptorsOnce();
  return NormalInverseChiSq_descriptor_;
}

const NormalInverseChiSq& NormalInverseChiSq::default_instance() {
  if (default_instance_ == NULL) protobuf_AddDesc_distributions_2fio_2fschema_2eproto();  return *default_instance_;
}

NormalInverseChiSq* NormalInverseChiSq::default_instance_ = NULL;

NormalInverseChiSq* NormalInverseChiSq::New() const {
  return new NormalInverseChiSq;
}

void NormalInverseChiSq::Clear() {
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
  mutable_unknown_fields()->Clear();
}

bool NormalInverseChiSq::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!(EXPRESSION)) return false
  ::google::protobuf::uint32 tag;
  while ((tag = input->ReadTag()) != 0) {
    if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
        ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
      return true;
    }
    DO_(::google::protobuf::internal::WireFormat::SkipField(
          input, tag, mutable_unknown_fields()));
  }
  return true;
#undef DO_
}

void NormalInverseChiSq::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  if (!unknown_fields().empty()) {
    ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
        unknown_fields(), output);
  }
}

::google::protobuf::uint8* NormalInverseChiSq::SerializeWithCachedSizesToArray(
    ::google::protobuf::uint8* target) const {
  if (!unknown_fields().empty()) {
    target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
        unknown_fields(), target);
  }
  return target;
}

int NormalInverseChiSq::ByteSize() const {
  int total_size = 0;
  
  if (!unknown_fields().empty()) {
    total_size +=
      ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
        unknown_fields());
  }
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = total_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void NormalInverseChiSq::MergeFrom(const ::google::protobuf::Message& from) {
  GOOGLE_CHECK_NE(&from, this);
  const NormalInverseChiSq* source =
    ::google::protobuf::internal::dynamic_cast_if_available<const NormalInverseChiSq*>(
      &from);
  if (source == NULL) {
    ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  } else {
    MergeFrom(*source);
  }
}

void NormalInverseChiSq::MergeFrom(const NormalInverseChiSq& from) {
  GOOGLE_CHECK_NE(&from, this);
  mutable_unknown_fields()->MergeFrom(from.unknown_fields());
}

void NormalInverseChiSq::CopyFrom(const ::google::protobuf::Message& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

void NormalInverseChiSq::CopyFrom(const NormalInverseChiSq& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool NormalInverseChiSq::IsInitialized() const {
  
  return true;
}

void NormalInverseChiSq::Swap(NormalInverseChiSq* other) {
  if (other != this) {
    _unknown_fields_.Swap(&other->_unknown_fields_);
    std::swap(_cached_size_, other->_cached_size_);
  }
}

::google::protobuf::Metadata NormalInverseChiSq::GetMetadata() const {
  protobuf_AssignDescriptorsOnce();
  ::google::protobuf::Metadata metadata;
  metadata.descriptor = NormalInverseChiSq_descriptor_;
  metadata.reflection = NormalInverseChiSq_reflection_;
  return metadata;
}


// @@protoc_insertion_point(namespace_scope)

}  // namespace distributions
}  // namespace protobuf

// @@protoc_insertion_point(global_scope)
