video_camera_calibration_static_moge_mapper#
Compute the camera intrinsics and field of view (FOV) for a static camera using Moge-2 (more accurate than DeepCalib).
使用 Moge-2(比 DeepCalib 更精确)计算静态相机的内参和视场角(FOV)。
Type 算子类型: mapper
Tags 标签: gpu, video
🔧 Parameter Configuration 参数配置#
name 参数名 |
type 类型 |
default 默认值 |
desc 说明 |
|---|---|---|---|
|
<class 'str'> |
|
The path to the Moge-2 model. |
|
typing.Annotated[int, Gt(gt=0)] |
|
The number of frames to be extracted uniformly from the video. If it's 1, only the middle frame will be extracted. If it's 2, only the first and the last frames will be extracted. If it's larger than 2, in addition to the first and the last frames, other frames will be extracted uniformly within the video duration. If "duration" > 0, frame_num is the number of frames per segment. |
|
<class 'float'> |
|
The duration of each segment in seconds. If 0, frames are extracted from the entire video. If duration > 0, the video is segmented into multiple segments based on duration, and frames are extracted from each segment. |
|
<class 'str'> |
|
The field name to store the tags. It's "static_camera_calibration_moge_tags" in default. |
|
<class 'str'> |
|
Output directory to save extracted frames. |
|
<class 'bool'> |
|
Whether to save the camera parameters results to an JSON file. |
|
<class 'str'> |
|
Output directory for saving camera parameters. |
|
<class 'bool'> |
|
Determines whether to output point map in OpenCV camera coordinate system (x right, y down, z forward). For MoGe-2, the point map is in metric scale. |
|
<class 'bool'> |
|
Determines whether to output depth maps. |
|
<class 'bool'> |
|
Determines whether to output a binary mask for valid pixels. |
|
|
extra args |
|
|
|
extra args |
📊 Effect demonstration 效果演示#
test#
VideoCameraCalibrationStaticMogeMapper(model_path='Ruicheng/moge-2-vitl', frame_num=1, duration=1, frame_dir=DATA_JUICER_ASSETS_CACHE, if_output_info=True, output_info_dir=DATA_JUICER_ASSETS_CACHE, if_output_points_info=True, if_output_depth_info=True, if_output_mask_info=True)
📥 input data 输入数据#
📤 output data 输出数据#
test_mul_proc#
VideoCameraCalibrationStaticMogeMapper(model_path='Ruicheng/moge-2-vitl', frame_num=1, duration=1, frame_dir=DATA_JUICER_ASSETS_CACHE, if_output_info=True, output_info_dir=DATA_JUICER_ASSETS_CACHE, if_output_points_info=True, if_output_depth_info=True, if_output_mask_info=True)