MCPcopy Create free account

hub / github.com/google-research/scenic / functions

Functions4,921 in github.com/google-research/scenic

↓ 1 callersFunction_dataset_fn
Dataset function.
scenic/projects/tasseo/datasets/chrmID_big_metaphase_context_dataset.py:130
↓ 1 callersFunction_dataset_fn
Dataset function.
scenic/projects/tasseo/datasets/chrmID_metaphase_context_dataset.py:124
↓ 1 callersFunction_dataset_fn
Dataset function.
scenic/projects/tasseo/datasets/chrmID_dataset.py:123
↓ 1 callersFunction_dataset_fn
Dataset function.
scenic/projects/svvit/datasets/pileup_coverage_dataset.py:143
↓ 1 callersFunction_dataset_fn
Dataset function.
scenic/projects/svvit/datasets/pileup_window_dataset.py:146
↓ 1 callersFunction_decode_and_random_crop
Make a random crop of `image_size`.
scenic/dataset_lib/imagenet_dataset.py:108
↓ 1 callersFunction_decode_spectrogram
Decodes audio spectrogram. Args: spectrogram: input mel spectrogram inflate: if True, adds a channel dimension zero_centering: if True,
scenic/projects/mbt/datasets/dataset_utils.py:78
↓ 1 callersMethod_decode_time_and_caption
(self, seq, duration)
scenic/projects/streaming_dvc/densecap_evaluator.py:156
↓ 1 callersFunction_denominator
Computes the denominator.
scenic/projects/fast_vit/model_utils.py:1174
↓ 1 callersFunction_dilate_shape
Utility function for computing the shape resulting from a dilation. Args: shape: Shapes (input or kernel i.e. lhr or rhs) to which the dilation
scenic/model_lib/layers/masked_layers.py:552
↓ 1 callersMethod_dist_mips_across
( self, query, corpus_scores, local_device_id, recall_target=0.99, exact=F
scenic/projects/knowledge_visual_language/models/knowledge_fid.py:94
↓ 1 callersMethod_dist_mips_local
( self, query, corpus_scores, local_device_id, recall_target=0.99, exact=F
scenic/projects/knowledge_visual_language/models/knowledge_fid.py:82
↓ 1 callersFunction_download_annotations
Downloads the appropriate annotations file.
scenic/projects/owl_vit/evaluator.py:510
↓ 1 callersFunction_download_file
Downloads a file from a URL to a path.
scenic/projects/owl_vit/evaluator.py:495
↓ 1 callersMethod_downsample_video_tokens
Subsamples video tokens.
scenic/projects/unloc/video_text_fusion.py:155
↓ 1 callersMethod_drop_degenerate_features
Drops degenerate (e.g. cropped out) boxes.
scenic/projects/owl_vit/preprocessing/image_ops.py:213
↓ 1 callersMethod_drop_tokens
Subsample token x according to the keeped index in fg_inds. Args: x: batch x num_tokens x hidden_dim fg_inds: batch x num_fg_tokens
scenic/projects/objectvivit/model_utils.py:364
↓ 1 callersMethod_embed_boxes
(self, boxes, image_size=None)
scenic/projects/baselines/segment_anything/modeling/prompt_encoder.py:103
↓ 1 callersMethod_embed_image_jitted
Embeds image and returns image features, class embeddings, and boxes.
scenic/projects/owl_vit/notebooks/inference.py:203
↓ 1 callersMethod_embed_masks
(self, masks)
scenic/projects/baselines/segment_anything/modeling/prompt_encoder.py:116
↓ 1 callersMethod_embed_points
Embed points. Args: points: (num_prompts, num_points, 2). In absolute coordinates. labels: (num_prompts, num_points) pad: bool
scenic/projects/baselines/segment_anything/modeling/prompt_encoder.py:70
↓ 1 callersMethod_embed_texts_jitted
(self, queries: jnp.ndarray)
scenic/projects/owl_vit/notebooks/inference.py:236
↓ 1 callersMethod_erase
Erase an area.
scenic/dataset_lib/video_ops.py:147
↓ 1 callersMethod_eval
Evaluates a trained linear probe. Args: representation_fn: A function that given a batch, returns representations that are passed t
scenic/train_lib/transfer/linear_probe_utils.py:305
↓ 1 callersMethod_eval_stage_context
A context manager for each state of eval.
scenic/projects/boundary_attention/eval_manager.py:178
↓ 1 callersFunction_eval_step_all_gather
Runs a single step of moment retrieval evaluation.
scenic/projects/unloc/eval_utils.py:116
↓ 1 callersMethod_evaluate
Performs a single evaluation pass over the dataset for the given step.
scenic/projects/boundary_attention/eval_manager.py:90
↓ 1 callersMethod_extract_encoder_output
Extracts encoder output.
scenic/projects/unloc/encoders.py:420
↓ 1 callersFunction_extract_metadata_from_first_example
Extracts the image shape from the first example.
scenic/projects/svvit/datasets/pileup_coverage_dataset.py:30
↓ 1 callersFunction_fewshot_acc_fn
Computes (x,y) linear regression accuracy on (x_test, y_test). Args: x: An [n_examples, n_classes] matrix of feature representations. This will
scenic/projects/baselines/bert/train_utils.py:65
↓ 1 callersFunction_fill_rectangle_video
Fills blank area for video.
scenic/dataset_lib/video_ops.py:51
↓ 1 callersFunction_float_feature
(value)
scenic/projects/baselines/centernet/tools/build_coco_tfrecord.py:65
↓ 1 callersFunction_float_feature
(value)
scenic/projects/densevoc/tools/build_vidstg_tfrecord.py:108
↓ 1 callersFunction_float_feature
(value)
scenic/projects/densevoc/tools/build_vg_tfrecord.py:72
↓ 1 callersFunction_float_feature
(value)
scenic/projects/densevoc/tools/convert_video_tfrecord_to_image_tfrecord.py:78
↓ 1 callersFunction_float_feature
(value)
scenic/projects/densevoc/tools/build_vln_tfrecord.py:77
↓ 1 callersFunction_float_feature
(value)
scenic/projects/pixel_llm/tools/build_uninext_ref_tfrecord.py:90
↓ 1 callersFunction_float_feature
(value)
scenic/projects/pixel_llm/tools/build_vg_tfrecord.py:74
↓ 1 callersFunction_float_feature
(value)
scenic/projects/pixel_llm/tools/build_mdetr_ref_tfrecord.py:77
↓ 1 callersFunction_four_rots
Rotates an image four times, with 90 degrees between each rotation.
scenic/dataset_lib/big_transfer/preprocessing/ops.py:537
↓ 1 callersFunction_from_grid
From grid.
scenic/projects/adversarialtraining/attacks/attack_transforms.py:34
↓ 1 callersMethod_gather_top_boxes
Gathers the top instances based on IoU with ground-truth boxes.
scenic/projects/owl_vit/layers.py:439
↓ 1 callersMethod_generate_future_mask
Generate attention mask.
scenic/projects/densevoc/modeling/text_decoder.py:360
↓ 1 callersMethod_generate_future_mask
Generate attention mask.
scenic/projects/pixel_llm/modeling/text_decoder.py:439
↓ 1 callersMethod_generate_future_mask
Generate attention mask.
scenic/projects/streaming_dvc/modeling/text_decoder.py:486
↓ 1 callersMethod_generate_visualization_inputs
Returns fake inputs for visualization tests.
scenic/projects/baselines/detr/tests/test_train_utils.py:150
↓ 1 callersMethod_get_abs_pos
Calculate absolute positional embeddings. If needed, resize embeddings and remove cls_token dimension for the original embeddings. Args
scenic/projects/baselines/centernet/modeling/vitdet.py:388
↓ 1 callersMethod_get_abs_pos
Calculate absolute positional embeddings. If needed, resize embeddings and remove cls_token dimension for the original embeddings. Args
scenic/projects/pixel_llm/modeling/eva02_vit.py:242
↓ 1 callersFunction_get_augreg_cfg
(params_path)
scenic/projects/baselines/vit.py:443
↓ 1 callersMethod_get_bbox_ltrb
generate FCOS style regression targets. Args: grids: array in shape m x 2: all output pixel coordinates. boxes: array in shape n x 4:
scenic/projects/baselines/centernet/modeling/centernet.py:254
↓ 1 callersFunction_get_bytes_feature
(example, name)
scenic/projects/knowledge_visual_language/data/data_utils.py:274
↓ 1 callersMethod_get_centers_and_expand
pad arrays which will be used to generate heatmaps. Args: grids: array in shape m x 2: all output pixel coordinates. boxes: array in
scenic/projects/baselines/centernet/modeling/centernet.py:273
↓ 1 callersMethod_get_chunky_noise
Generates a noise that is a chunky version of the input noise.
scenic/projects/boundary_attention/helpers/additive_noise_model.py:96
↓ 1 callersMethod_get_corpus_scores
(self, corpus_scores, topk_ids)
scenic/projects/knowledge_visual_language/models/knowledge_fid.py:78
↓ 1 callersMethod_get_dataset
Lazy-loads given dataset.
scenic/train_lib/transfer/linear_probe_utils.py:200
↓ 1 callersMethod_get_dataset
Lazy-loads given dataset.
scenic/train_lib/transfer/fewshot_utils.py:211
↓ 1 callersMethod_get_dataset
Lazy-loads given dataset.
scenic/train_lib/transfer/fewshot_utils.py:383
↓ 1 callersMethod_get_dataset
Lazy-loads given dataset.
scenic/projects/baselines/bert/train_utils.py:317
↓ 1 callersMethod_get_decoder
(self, dec_type: str, dec_config: ml_collections.ConfigDict,
scenic/projects/vid2seq/models.py:164
↓ 1 callersMethod_get_decoder
(self, dec_type: str, dec_config: ml_collections.ConfigDict,
scenic/projects/streaming_dvc/modeling/vid2seq_model.py:233
↓ 1 callersFunction_get_default_configs_for_testing
()
scenic/projects/pointcloud/models.py:359
↓ 1 callersFunction_get_default_configs_for_testing
()
scenic/projects/pointcloud/segmentation_model.py:232
↓ 1 callersFunction_get_default_configs_for_testing
()
scenic/projects/ncr/resnet.py:184
↓ 1 callersMethod_get_encoder
(self, enc_type: str, enc_config: ml_collections.ConfigDict,
scenic/projects/vid2seq/models.py:131
↓ 1 callersMethod_get_encoder
(self, enc_type: str, enc_config: ml_collections.ConfigDict,
scenic/projects/streaming_dvc/modeling/vid2seq_model.py:217
↓ 1 callersFunction_get_func_args_and_kwargs
(call)
scenic/dataset_lib/big_transfer/registry.py:138
↓ 1 callersFunction_get_func_name
(expr)
scenic/dataset_lib/big_transfer/registry.py:128
↓ 1 callersMethod_get_gaussian_noise
Generates a gaussian noise.
scenic/projects/boundary_attention/helpers/additive_noise_model.py:92
↓ 1 callersFunction_get_grid_per_box
Obtain a size x size meshgrid inside the given box. Args: box: XYXY-format boxes of shape (T, 4). size: Resolution of the grid. sparse:
scenic/projects/baselines/centernet/modeling/roi_align.py:26
↓ 1 callersFunction_get_index_and_weights
Computes the 1d index & their weights to be used in interpolation.
scenic/projects/baselines/centernet/modeling/roi_align.py:56
↓ 1 callersMethod_get_instance_axis
Looks up the axis storing object instances for a given feature.
scenic/projects/owl_vit/preprocessing/image_ops.py:100
↓ 1 callersMethod_get_label_map
(self)
scenic/projects/owl_vit/preprocessing/label_ops.py:539
↓ 1 callersFunction_get_layer_id
(name: str, num_layers: int)
scenic/projects/baselines/centernet/optimizer_utils.py:103
↓ 1 callersFunction_get_layer_id
(name: str, num_layers: int)
scenic/projects/objectvivit/optimizer_utils.py:100
↓ 1 callersFunction_get_layer_id
(name: str, num_layers: int)
scenic/projects/av_mae/optimizer_utils.py:103
↓ 1 callersFunction_get_layer_id
(name: str, num_layers: int)
scenic/projects/streaming_dvc/optimizer_utils.py:99
↓ 1 callersFunction_get_merged_dataset
Creates datasets from builders, applies preprocessing, and merges them. Args: builders: List of TFDS dataset builders. splits: List contain
scenic/projects/owl_vit/preprocessing/input_pipeline.py:232
↓ 1 callersFunction_get_param_dict
(params)
scenic/projects/baselines/bert/model.py:192
↓ 1 callersFunction_get_params_dict
(inputs)
scenic/projects/baselines/detr/train_utils.py:374
↓ 1 callersMethod_get_positive_masks
define positive/ negative pixels for regression and heatmap. Args: centers_discret: array in shape m x n x 2: snap each of the n centers to
scenic/projects/baselines/centernet/modeling/centernet.py:301
↓ 1 callersFunction_get_post_mosaic_process_fn
Constructs the preprocess_fn that should be applied after mosaicing. Args: spec: Config string specifying the preprocessing. Returns: Pr
scenic/projects/owl_vit/preprocessing/input_pipeline.py:165
↓ 1 callersFunction_get_pre_mosaic_process_fn
Constructs the preprocess_fn that should be applied before mosaicing. Args: builder: TFDS dataset builder. decoder_kwargs: Decoder kwargs.
scenic/projects/owl_vit/preprocessing/input_pipeline.py:104
↓ 1 callersFunction_get_query_legend_html
(queries)
scenic/projects/owl_vit/notebooks/interactive.py:329
↓ 1 callersMethod_get_regression_and_heatmaps
generate heatmaps and normalized regression targets. Args: area: array in shape n: area if each ground truth box. centers_expanded: a
scenic/projects/baselines/centernet/modeling/centernet.py:335
↓ 1 callersFunction_get_single_grain_dataset
Creates a Grain-backed dataset from builder and applies preprocessing. Args: builder: TFDS dataset builder. start_index: Index dataset (Gra
scenic/projects/pixel_llm/io/flexio.py:225
↓ 1 callersFunction_get_single_grain_dataset
Creates a Grain-backed dataset from builder and applies preprocessing. Args: builder: TFDS dataset builder. start_index: Index dataset (Gra
scenic/dataset_lib/flexio/flexio.py:220
↓ 1 callersFunction_get_single_tfds_dataset
Creates dataset from builder and applies pre-mosaic preprocessing. Args: builder: TFDS dataset builder. split: Train/test/validation split.
scenic/projects/owl_vit/preprocessing/input_pipeline.py:186
↓ 1 callersFunction_get_single_tfds_dataset
Creates dataset from builder and applies preprocessing. Args: builder: TFDS dataset builder. split: Train/test/validation split. batch_
scenic/projects/pixel_llm/io/flexio.py:148
↓ 1 callersFunction_get_single_tfds_dataset
Creates dataset from builder and applies preprocessing. Args: builder: TFDS dataset builder. split: Train/test/validation split. batch_
scenic/dataset_lib/flexio/flexio.py:143
↓ 1 callersFunction_get_single_tfrecord_dataset
Creates dataset using DMVR and applies preprocessing. Args: tfrecords: Path to tfrecords. context_features: Dictionary of context features
scenic/projects/pixel_llm/io/flexio.py:313
↓ 1 callersFunction_get_single_tfrecord_dataset
Creates dataset using DMVR and applies preprocessing. Args: tfrecords: Path to tfrecords. context_features: Dictionary of context features
scenic/projects/streaming_dvc/io/flexio.py:76
↓ 1 callersMethod_get_unique_labelset
Gets a unique set of queries and corresponding labels for one image.
scenic/projects/owl_vit/preprocessing/label_ops.py:875
↓ 1 callersMethod_global_encode
Applies the global encoder. We support two strategies to merge encoded tokens from each view: In the first strategy, we extract the CLS toke
scenic/projects/mtv/model.py:543
↓ 1 callersFunction_greedy_assignment
Greedily assigns workers to jobs based on an adjaceny matrix. Starting with an adjacency matrix representing the available connections in the bi-
scenic/model_lib/matchers/hungarian_cover.py:56
↓ 1 callersFunction_image_tiles_to_mosaic
Reshapes a batch of image tiles into a mosaic.
scenic/projects/owl_vit/preprocessing/mosaic.py:107
↓ 1 callersMethod_image_to_patch
Converts an image to patches. Args: vid: A 5D tensor of shape [B, T, H, W, C]. patch_size: integer, dimension of a square patch.
scenic/projects/unloc/encoders.py:452
↓ 1 callersFunction_improve_assignment
Improves an assignment by backtracking the augmented path using state. Args: assignment: A bool [b, n, m] array, where each element of the inne
scenic/model_lib/matchers/hungarian_cover.py:214
↓ 1 callersFunction_inflate_with_mean_channel
Inflate tensor with an extra mean channel.
scenic/projects/av_mae/mbt.py:66
↓ 1 callersFunction_initialize_model
Initialization function to be jitted.
scenic/projects/baselines/bert/train_utils.py:250
↓ 1 callersFunction_initialize_model
Initialization function to be jitted.
scenic/projects/mbt/train_utils.py:104
← previousnext →701–800 of 4,921, ranked by callers