MCPcopy Create free account

hub / github.com/allenai/molmo2 / functions

Functions2,270 in github.com/allenai/molmo2

↓ 3 callersFunction_find_video_by_id
Find video path for a video_id using on-demand lookup. Checks in-memory cache first, then disk cache, then searches 3 subdirectories. Dis
olmo/data/molmo2_datasets.py:446
↓ 3 callersFunction_find_video_point_path_by_id
Find 2fps video path for a video_id using on-demand lookup. Checks in-memory cache first, then disk cache, then searches subdirectories. Disc
olmo/data/molmo2_datasets.py:502
↓ 3 callersMethod_format_example
(self, message, example, is_training, for_inference, rng)
olmo/preprocessing/data_formatter.py:1820
↓ 3 callersMethod_format_example
(self, message, example, is_training, for_inference, rng, points_to_indices)
olmo/models/molmo_point/molmo_point_data_formatter.py:1043
↓ 3 callersMethod_get_frames_dir
(cls, split, video_name)
olmo/data/molmo2_video_track_datasets.py:1098
↓ 3 callersFunction_get_gui_instruct_prompt
(prompt_format, instruction)
olmo/data/academic_image_datasets.py:1028
↓ 3 callersMethod_get_max_grad_norm_coeff
( self, initial_value: Optional[float], step: int, max_steps: int )
olmo/train/optim.py:305
↓ 3 callersMethod_get_style
(self, rng)
olmo/data/molmo2_datasets.py:1004
↓ 3 callersMethod_linear_warmup
(self, initial_lr: float, step: int, warmup_steps: int = 2000)
olmo/train/optim.py:330
↓ 3 callersFunction_load_cache_from_disk
Load video path cache from disk.
olmo/data/molmo2_datasets.py:406
↓ 3 callersFunction_load_hf_dataset
Load an HF dataset, caching locally under VIDEO_DATA_HOME.
olmo/data/academic_video_datasets.py:74
↓ 3 callersFunction_prepare_env_for_save
( dir: PathOrStr, process_group: Optional[dist.ProcessGroup] = None, save_overwrite: bool = False,
olmo/train/distributed_checkpointing.py:659
↓ 3 callersFunction_save_cache_to_disk
Save video path cache to disk.
olmo/data/molmo2_datasets.py:420
↓ 3 callersMethod_split_heads
(self, hidden_states, num_heads)
olmo/hf_model/modeling_molmo_point.py:258
↓ 3 callersMethod_split_heads
(self, hidden_states, num_heads)
olmo/hf_model/modeling_molmo2.py:150
↓ 3 callersMethod_split_heads
(self, hidden_states, num_heads)
olmo/nn/image_vit.py:199
↓ 3 callersFunction_weighted_cross_entropy
(logits, targets, weight, mask, labels_padded=False)
olmo/models/molmo_point/molmo_point.py:302
↓ 3 callersMethodbatch_shard
Shard inputs on their sequence dimension, optionally adding padding if needed. .. important:: If using intra-document ma
olmo/nn/cp_load_balancer.py:68
↓ 3 callersMethodbuild
(self, tokenizer, image_preprocessor: ImagePreprocessor, text_seq_len, max_seq_len)
olmo/models/molmo/molmo_preprocessor.py:17
↓ 3 callersFunctionbuild_image_asset
(image_src, src_folder=None)
olmo/html_utils.py:188
↓ 3 callersMethodbuild_image_preprocessor
(self, tokenizer, image_preprocessor, image_padding_mask=False, legacy_image_
olmo/preprocessing/multicrop_preprocessor.py:37
↓ 3 callersMethodbuild_model
(self, device=None)
olmo/models/molmo2/molmo2.py:131
↓ 3 callersMethodbuild_single_crop
(self, image, is_training, rng, image_size=None)
olmo/preprocessing/image_preprocessor.py:390
↓ 3 callersMethodbuild_text_preprocessor
(self, tokenizer, max_seq_len)
olmo/models/molmo_point/molmo_point_text_preprocessor.py:22
↓ 3 callersFunctioncompute_area
(bbox: list, invalid: float=None)
olmo/eval/evaluators.py:1025
↓ 3 callersFunctionconvert_point_tracking_to_trajectory_format
Convert extracted point tracking data to standardized trajectory format. Args: points_data: List of dicts with 'time' and 'point
olmo/eval/object_tracking_utils.py:298
↓ 3 callersFunctiondraw_points
(image, points)
scripts/unified_demo.py:51
↓ 3 callersFunctionensure_multiple_of
(x: int, of: int)
olmo/util.py:49
↓ 3 callersFunctionescape_html
(text)
olmo/html_utils.py:62
↓ 3 callersFunctioneval_caption_consistency
( statements_list, category_list, data: Dict, openai_api_key: str, bat
olmo/eval/vixmo_caption_utils.py:230
↓ 3 callersFunctioneval_caption_recall
( prediction: str, data: Dict, openai_api_key: str, batch_size: int = -1 )
olmo/eval/vixmo_caption_utils.py:299
↓ 3 callersMethodextract_segment
Extract a segment from the video that contains the moment. Args: moment_start (float): Start time of the moment in second
olmo/data/academic_video_datasets.py:3358
↓ 3 callersMethodfinish
(self)
olmo/train/trainer.py:148
↓ 3 callersMethodformat_input_timestamps
Format input timestamp as text
olmo/preprocessing/data_formatter.py:1637
↓ 3 callersMethodformat_video_points
(self, example, points_to_indices)
olmo/models/molmo_point/molmo_point_data_formatter.py:262
↓ 3 callersFunctionfreeze_module
(module: torch.nn.Module, exclude_params: Optional[List[str]] = None)
olmo/torch_util.py:227
↓ 3 callersFunctionget_cp_mesh
Get the context parallel sub-mesh associated with a ``DeviceMesh`` created from :func:`build_world_mesh()`. :param device_mesh: The worl
olmo/dist_util.py:318
↓ 3 callersFunctionget_dataset_class_by_name
Get the class of the named dataset
olmo/data/get_dataset.py:546
↓ 3 callersFunctionget_default_thread_count
Get the default maximum number of threads allowed.
olmo/util.py:448
↓ 3 callersFunctionget_eval_result
(prompt: str, openai_api_key: str, maxtry: int=10, system_prompt: str=None)
olmo/eval/temp_compass_utils.py:103
↓ 3 callersFunctionget_patch_coordinates
Build ground truth target ids for a point point: (x, y) normalized coordinates between 0 and 1 patch_idx_arr: Mapping of patch x,y coordinate
olmo/models/molmo_point/molmo_point_example_preprocessor.py:30
↓ 3 callersFunctionget_preprocessor
()
tests/data/test_preprocessor.py:12
↓ 3 callersMethodget_quantized_max_len
(self)
olmo/data/dynamic_packer.py:350
↓ 3 callersMethodget_quantized_value
(self, val: int)
olmo/data/dynamic_packer.py:347
↓ 3 callersMethodget_save_dir
Get directory to save the eval results
olmo/eval/model_evaluator.py:232
↓ 3 callersFunctioninterpolate_position_embeddings
( position_embeddings: torch.Tensor, num_patches: int, dim: int, patch_size: int, height:
scripts/prepare_pretrained_model.py:51
↓ 3 callersFunctionis_point_in_region
Check if the point (x, y) is within the region defined by the boolean mask. Parameters: - point (tuple of floats): x/y-coordinate of the
olmo/eval/evaluators.py:364
↓ 3 callersFunctionis_point_in_region
Check if point falls within the segmentation mask region. (Copied from olmo.eval.evaluators.py)
olmo/eval/object_tracking_utils.py:501
↓ 3 callersFunctionjoin_path
Join two paths. :param path1: The first path. :param path2: The second path. :returns: The joined result.
olmo/io.py:49
↓ 3 callersFunctionllm_activation_checkpoint_function
(cfg: 'LlmConfig')
olmo/nn/llm.py:162
↓ 3 callersMethodload
(self)
olmo/data/molmo2_datasets.py:1211
↓ 3 callersFunctionload_model_state
Load model state in-place from `dir` Works for any combination of sharded/unshared checkpoints and sharded/unshared model
olmo/train/checkpointer.py:86
↓ 3 callersFunctionload_video_decord
Load video frames with decord
olmo/data/video_loader.py:479
↓ 3 callersFunctionlog_metrics_to_console
(prefix: str, metrics: Dict[str, float])
olmo/util.py:498
↓ 3 callersMethodmax_dictionaries
(*other: Dict[str, 'TensorSpec'])
olmo/preprocessing/preprocessor_utils.py:96
↓ 3 callersMethodnormalize_image_tensor
(self, image: torch.FloatTensor)
olmo/preprocessing/image_preprocessor.py:354
↓ 3 callersFunctionnormalize_str
Normalize the str to lower case and make them float numbers if possible.
olmo/eval/mmmu_eval_utils.py:111
↓ 3 callersMethodpad
( self, x: torch.Tensor, seq_dim: int, value: Union[int, float], lengt
olmo/nn/cp_load_balancer.py:244
↓ 3 callersFunctionpeak_gpu_memory
Get the peak GPU memory usage in MB across all ranks. Only rank 0 will get the final result.
olmo/torch_util.py:171
↓ 3 callersFunctionquery_gpt
(prompt: str, openai_api_key: str, system_prompt: str = None, maxtry: int = 10)
olmo/eval/video_caption_utils.py:73
↓ 3 callersMethodreset_with_pretrained_weights
(self)
olmo/nn/llm.py:754
↓ 3 callersFunctionrun_trainer
(cfg: TrainConfig)
olmo/train/run_trainer.py:49
↓ 3 callersMethodsave_checkpoint
(self, checkpoint_type: CheckpointType, optim=True)
olmo/train/trainer.py:602
↓ 3 callersFunctionsetup_pil
()
olmo/preprocessing/image_preprocessor.py:32
↓ 3 callersFunctionsynchronize_value
(value: V, device: torch.device)
olmo/torch_util.py:196
↓ 3 callersFunctiontemplate_mc_question
( question, options, rng, unlabelled=False, p_inline=0.1, p_use_instruction_template=0.5, p_label_
olmo/preprocessing/multiple_choice_templates.py:119
↓ 3 callersMethodtokenize_and_interleave
Build a batch by interleaving the text tokens from tokenizing `message_list` and the multi-modal tokens from `multi_model_tokens`
olmo/models/molmo_point/molmo_point_text_preprocessor.py:229
↓ 3 callersMethodtokenize_message
(self, message_list: List[str], weight, bos=True, add_last_eos=True)
olmo/preprocessing/text_preprocessor.py:86
↓ 3 callersMethodupdate_legacy_settings
(cls, config: D)
olmo/models/molmo_point/molmo_point.py:205
↓ 3 callersMethodupdate_state
( self, state: ConstraintStateType, last_prediction: torch.Tensor, last_backpo
olmo/nn/beam_search.py:703
↓ 3 callersMethodvision_backbone
(self)
olmo/hf_model/modeling_molmo2.py:1602
↓ 2 callersMethod__init__
(self, submodule: nn.Module)
olmo/nn/vision_backbone.py:176
↓ 2 callersFunction_build_iterator
(_resume_from=None)
tests/data/test_data_iterator.py:223
↓ 2 callersMethod_build_multi_image_coordinates
( self, rng, timestamps, frame_points, scales, multi_image, indices=None)
olmo/preprocessing/point_formatter.py:370
↓ 2 callersFunction_check_num_replicas
(num_replicas: int, dp_world_size: int)
olmo/dist_util.py:89
↓ 2 callersFunction_check_shard_degree
(shard_degree: int, dp_world_size: int)
olmo/dist_util.py:99
↓ 2 callersMethod_clean_label
Strip leading '#X' and capitalize.
olmo/data/academic_video_datasets.py:5474
↓ 2 callersFunction_collate
(tensors, max_shape=None, dtype=None, pad=None, pad_value=-1, allow_truncate=True)
olmo/preprocessing/multimodal_collator.py:38
↓ 2 callersFunction_download_motion_bench
(max_workers)
olmo/data/academic_video_datasets.py:254
↓ 2 callersMethod_ensure_object_info
(self)
olmo/io.py:1029
↓ 2 callersMethod_example_str
(self, example)
olmo/data/dynamic_packer.py:421
↓ 2 callersFunction_expand_token
(token, batch_size: int)
olmo/nn/image_vit.py:109
↓ 2 callersMethod_filter_all_but_start_end
(point_tracks: List[PointTrack])
olmo/preprocessing/point_formatter.py:349
↓ 2 callersMethod_filter_for_initial_points
Filter point_tracks to only include points AFTER initial_points Args: point_tracks: List of frame data with points
olmo/preprocessing/point_formatter.py:325
↓ 2 callersMethod_filter_frames_to_video
Filter frames_data to only include frames that match actual video timestamps. Uses numpy broadcasting for efficient comparison.
olmo/preprocessing/data_formatter.py:1333
↓ 2 callersMethod_filter_frames_to_video
Filter frames_data to only include frames that match actual video timestamps. Uses numpy broadcasting for efficient comparison.
olmo/models/molmo_point/molmo_point_data_formatter.py:487
↓ 2 callersMethod_find_annotation_dir
Return dir with annotations: v1 path (VIDEO_DIR) or v2 path (HOME).
olmo/data/academic_video_datasets.py:5346
↓ 2 callersMethod_format_image_points
Convert image points that are already sorted and scaled into a string
olmo/preprocessing/point_formatter.py:423
↓ 2 callersMethod_format_video_points_per_frame
Format points for a single frame in video as {id: [x, y], ...} Shared by: - `_format_video_point_track_per_frame`
olmo/preprocessing/point_formatter.py:701
↓ 2 callersFunction_gcs_file_size
(bucket_name: str, key: str)
olmo/io.py:628
↓ 2 callersFunction_get_device_batch
(_worker_its, device_batch_size)
tests/data/test_data_iterator.py:72
↓ 2 callersMethod_get_split_config
Return (zip_names, frames_root) for each split.
olmo/data/molmo2_video_track_datasets.py:884
↓ 2 callersFunction_get_video_point_preprocessed_path
Get path for the preprocessed rows_with_clips pickle.
olmo/data/molmo2_datasets.py:732
↓ 2 callersMethod_load_all_dataset_and_fps
Load/cache annotations across all tasks/splits, return {(data_split, video_name): fps}. video_name is the video identifier without file exten
olmo/data/molmo2_video_track_datasets.py:1820
↓ 2 callersFunction_load_unsharded_keys
( dir: PathOrStr, keys: List[str], *, pre_download: bool = False, work_dir: Optional[PathO
olmo/train/distributed_checkpointing.py:702
↓ 2 callersMethod_load_video_list
Load video list for a specific dataset (k600 or k700)
olmo/data/academic_video_datasets.py:2517
↓ 2 callersMethod_prepare_annotation_dir
Extract tar files and decode mp4s to frames.
olmo/data/molmo2_video_track_datasets.py:1111
↓ 2 callersMethod_reset_point_predictors
(self)
olmo/models/molmo_point/molmo_point.py:473
↓ 2 callersMethod_resolve_video_path
Look up the video path from the pre-built cache. Args: video_id: the `video` column value from HF (video_id, no extension)
olmo/data/molmo2_video_track_datasets.py:1804
↓ 2 callersFunction_s3_file_size
(scheme: str, bucket_name: str, key: str)
olmo/io.py:850
← previousnext →201–300 of 2,270, ranked by callers