# Path: alphafold/model/tf/data_transforms.py
# NUM_RES = shape_placeholders.NUM_RES
# NUM_MSA_SEQ = shape_placeholders.NUM_MSA_SEQ
# NUM_EXTRA_SEQ = shape_placeholders.NUM_EXTRA_SEQ
# NUM_TEMPLATES = shape_placeholders.NUM_TEMPLATES
# _MSA_FEATURE_NAMES = [
#     'msa', 'deletion_matrix', 'msa_mask', 'msa_row_mask', 'bert_mask',
#     'true_msa'
# ]
# def cast_64bit_ints(protein):
# def make_seq_mask(protein):
# def make_template_mask(protein):
# def curry1(f):
#   def fc(*args, **kwargs):
# def add_distillation_flag(protein, distillation):
# def make_all_atom_aatype(protein):
# def fix_templates_aatype(protein):
# def correct_msa_restypes(protein):
# def squeeze_features(protein):
# def make_random_crop_to_size_seed(protein):
# def randomly_replace_msa_with_unknown(protein, replace_proportion):
# def sample_msa(protein, max_seq, keep_extra):
# def crop_extra_msa(protein, max_extra_msa):
# def delete_extra_msa(protein):
# def block_delete_msa(protein, config):
# def nearest_neighbor_clusters(protein, gap_agreement_weight=0.):
# def summarize_clusters(protein):
#   def csum(x):
# def make_msa_mask(protein):
# def pseudo_beta_fn(aatype, all_atom_positions, all_atom_masks):
# def make_pseudo_beta(protein, prefix=''):
# def add_constant_field(protein, key, value):
# def shaped_categorical(probs, epsilon=1e-10):
# def make_hhblits_profile(protein):
# def make_masked_msa(protein, config, replace_fraction):
# def make_fixed_size(protein, shape_schema, msa_cluster_size, extra_msa_size,
#                     num_res, num_templates=0):
# def make_msa_feat(protein):
# def select_feat(protein, feature_list):
# def crop_templates(protein, max_templates):
# def random_crop_to_size(protein, crop_size, max_templates, shape_schema,
#                         subsample_templates=False):
# def make_atom14_masks(protein):
# 
# Path: alphafold/model/tf/shape_placeholders.py
# NUM_RES = 'num residues placeholder'
# NUM_MSA_SEQ = 'msa placeholder'
# NUM_EXTRA_SEQ = 'extra msa placeholder'
# NUM_TEMPLATES = 'num templates placeholder'


from alphafold.model.tf import data_transforms
from alphafold.model.tf import shape_placeholders
import tensorflow.compat.v1 as tf
import tree
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#      http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

"""Feature pre-processing input pipeline for AlphaFold."""


# Pylint gets confused by the curry1 decorator because it changes the number
#   of arguments to the function.
# pylint:disable=no-value-for-parameter


NUM_RES = shape_placeholders.NUM_RES
NUM_MSA_SEQ = shape_placeholders.NUM_MSA_SEQ
NUM_EXTRA_SEQ = shape_placeholders.NUM_EXTRA_SEQ
NUM_TEMPLATES = shape_placeholders.NUM_TEMPLATES


def nonensembled_map_fns(data_config):
  """Input pipeline functions which are not ensembled."""
  common_cfg = data_config.common

  map_fns = [

# Path: alphafold/model/tf/data_transforms.py
# NUM_RES = shape_placeholders.NUM_RES
# NUM_MSA_SEQ = shape_placeholders.NUM_MSA_SEQ
# NUM_EXTRA_SEQ = shape_placeholders.NUM_EXTRA_SEQ
# NUM_TEMPLATES = shape_placeholders.NUM_TEMPLATES
# _MSA_FEATURE_NAMES = [
#     'msa', 'deletion_matrix', 'msa_mask', 'msa_row_mask', 'bert_mask',
#     'true_msa'
# ]
# def cast_64bit_ints(protein):
# def make_seq_mask(protein):
# def make_template_mask(protein):
# def curry1(f):
#   def fc(*args, **kwargs):
# def add_distillation_flag(protein, distillation):
# def make_all_atom_aatype(protein):
# def fix_templates_aatype(protein):
# def correct_msa_restypes(protein):
# def squeeze_features(protein):
# def make_random_crop_to_size_seed(protein):
# def randomly_replace_msa_with_unknown(protein, replace_proportion):
# def sample_msa(protein, max_seq, keep_extra):
# def crop_extra_msa(protein, max_extra_msa):
# def delete_extra_msa(protein):
# def block_delete_msa(protein, config):
# def nearest_neighbor_clusters(protein, gap_agreement_weight=0.):
# def summarize_clusters(protein):
#   def csum(x):
# def make_msa_mask(protein):
# def pseudo_beta_fn(aatype, all_atom_positions, all_atom_masks):
# def make_pseudo_beta(protein, prefix=''):
# def add_constant_field(protein, key, value):
# def shaped_categorical(probs, epsilon=1e-10):
# def make_hhblits_profile(protein):
# def make_masked_msa(protein, config, replace_fraction):
# def make_fixed_size(protein, shape_schema, msa_cluster_size, extra_msa_size,
#                     num_res, num_templates=0):
# def make_msa_feat(protein):
# def select_feat(protein, feature_list):
# def crop_templates(protein, max_templates):
# def random_crop_to_size(protein, crop_size, max_templates, shape_schema,
#                         subsample_templates=False):
# def make_atom14_masks(protein):
# 
# Path: alphafold/model/tf/shape_placeholders.py
# NUM_RES = 'num residues placeholder'
# NUM_MSA_SEQ = 'msa placeholder'
# NUM_EXTRA_SEQ = 'extra msa placeholder'
# NUM_TEMPLATES = 'num templates placeholder'


# Path: alphafold/model/tf/input_pipeline.py
from alphafold.model.tf import data_transforms
from alphafold.model.tf import shape_placeholders
import tensorflow.compat.v1 as tf
import tree

# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#      http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

"""Feature pre-processing input pipeline for AlphaFold."""


# Pylint gets confused by the curry1 decorator because it changes the number
#   of arguments to the function.
# pylint:disable=no-value-for-parameter


NUM_RES = shape_placeholders.NUM_RES
NUM_MSA_SEQ = shape_placeholders.NUM_MSA_SEQ
NUM_EXTRA_SEQ = shape_placeholders.NUM_EXTRA_SEQ
NUM_TEMPLATES = shape_placeholders.NUM_TEMPLATES


def nonensembled_map_fns(data_config):
  """Input pipeline functions which are not ensembled."""
  common_cfg = data_config.common

  map_fns = [

      data_transforms.correct_msa_restypes,