> ## Documentation Index
> Fetch the complete documentation index at: https://docs.comfy.org/llms.txt
> Use this file to discover all available pages before exploring further.

# ComfyUI MoGe 예제

> 이 가이드에서는 ComfyUI에서 MoGe를 사용해 단안 기하학 추정, 즉 계량 점 지도, 깊이 지도, 법선 지도 및 메시 생성 방법을 보여줍니다.

# ComfyUI MoGe 소개

[MoGe](https://github.com/microsoft/MoGe) (CVPR 2025, 마이크로소프트 리서치 출처)는 단안 오픈 도메인 이미지로부터 3D 기하학을 복원하는 강력한 모델입니다. 이 모델은 한 번의 순방향 전파만으로 계량 점 지도, 계량 깊이 지도, 법선 지도 및 카메라 FOV를 추정합니다.

주요 기능:

* **정확한 3D 기하학 추정**: 단일 이미지에서 점 지도, 깊이 지도 및 법선 지도를 하나의 모델, 한 번의 순방향 전파로 추정
* **계량 스케일**(MoGe-2): 실세계 스케일의 점 지도와 깊이 지도
* **유연한 해상도 지원**: 다양한 해상도와 종횡비(2:1부터 1:2까지)와 호환
* **빠른 추론**: A100 / RTX 3090에서 이미지당 약 60ms (FP16, ViT-L)
* **투시 및 파노라마 이미지로부터 메시 생성**

MoGe는 두 가지 버전으로 제공됩니다:

| 파일                        | 버전         | 계량 스케일 | 법선 지도 | 매개변수 |
| ------------------------- | ---------- | :----: | :---: | :--: |
| `moge_1_vitl_fp16`        | **MoGe-1** |    -   |   -   | 314M |
| `moge_2_vitl_normal_fp16` | **MoGe-2** |    ✅   |   ✅   | 331M |

> MoGe-2는 계량 스케일과 고화질 법선 지도 추정을 추가하여 더 선명한 시각적 디테일과 낮은 추론 레이턴시를 제공합니다. **법선 포함된 MoGe-2(`moge_2_vitl_normal_fp16`)가 권장 체크포인트입니다.**

<Tip>
  <Tabs>
    <Tab title="휴대용 또는 자체 배포 사용자">
      ComfyUI가 최신 버전으로 업데이트되었는지 확인하세요.

      * [ComfyUI 다운로드](https://www.comfy.org/download)
      * [업데이트 가이드](/ko/installation/update_comfyui)

      이 가이드의 워크플로우는 [워크플로우 템플릿](/ko/interface/features/template)에서 확인할 수 있습니다.
      템플릿에서 찾을 수 없다면, 귀하의 ComfyUI가 오래된 버전일 수 있습니다. (데스크톱 버전의 업데이트는 다소 지연될 수 있습니다)

      워크플로우를 로드할 때 노드가 누락되는 경우, 가능한 원인:

      1. 최신 ComfyUI 버전(야간 빌드)을 사용하고 있지 않음
      2. 일부 노드가 시작 시 가져오기에 실패함
    </Tab>

    <Tab title="데스크톱 또는 클라우드 사용자">
      * 데스크톱 버전은 ComfyUI 안정판 기반으로, 새로운 데스크톱 안정판이 출시되면 자동으로 업데이트됩니다.
      * [클라우드](https://cloud.comfy.org)는 ComfyUI 안정판 출시 후 업데이트됩니다.

      따라서 이 문서에서 핵심 노드가 누락된 것을 발견했다면, 그 이유는 새로운 핵심 노드가 아직 최신 안정판에 공개되지 않았기 때문일 수 있습니다. 다음 안정판 출시를 기다려 주세요.
    </Tab>
  </Tabs>
</Tip>

<Tip>
  ComfyUI는 이제 MoGe 노드를 기본적으로 지원합니다. 시작하기 전에 [ComfyUI](https://github.com/Comfy-Org/ComfyUI)의 최신 버전으로 업데이트했는지 확인하세요.

  생성된 `.glb` 형식의 모델은 `ComfyUI/output/mesh` 폴더에 출력됩니다.
</Tip>

## 모델 설치

MoGe 체크포인트를 다운로드하고 해당 ComfyUI 폴더에 저장하세요:

* **MoGe-2 (권장)**: [moge\_2\_vitl\_normal\_fp16.safetensors](https://huggingface.co/Comfy-Org/MoGe/resolve/main/moge_2_vitl_normal_fp16.safetensors)
* **MoGe-1 (기준)**: [moge\_1\_vitl\_fp16.safetensors](https://huggingface.co/Comfy-Org/MoGe/resolve/main/moge_1_vitl_fp16.safetensors)

```
ComfyUI/
├── models/
│   ├── geometry_estimation/
│   │   ├── moge_2_vitl_normal_fp16.safetensors
│   │   └── moge_1_vitl_fp16.safetensors
```

## 예제 워크플로우

***

## 1. 깊이 추정

**작동 방식**: 단일 이미지를 입력받아 계량 깊이 지도, 컬러화된 깊이 미리보기 및 마스크를 추정합니다. MoGe가 한 번의 순방향 전파로 추정한 동일한 계량 스케일의 깊이를 출력합니다. 합성, 깊이 기반 효과 또는 메시 생성 전 처리용 장면 깊이 참조로 유용합니다.

MoGe는 이미지로부터 카메라의 시야각(FOV)도 추정하며, 이를 정확성을 더욱 높이기 위해 실제값으로 덮어쓸 수도 있습니다.

<Card title="워크플로우 다운로드" icon="download" href="https://github.com/Comfy-Org/workflow_templates/blob/main/templates/utility_moge_depth_estimation.json">
  JSON 다운로드하거나 템플릿 라이브러리에서 "MoGe 깊이 추정" 검색
</Card>

<Card title="샘플 이미지 다운로드" icon="image" href="https://raw.githubusercontent.com/Comfy-Org/workflow_templates/main/input/alien_world.png">
  이 워크플로우의 예제 입력 이미지 받기
</Card>

<div style={{display: 'flex', gap: '1rem', flexWrap: 'wrap'}}>
  <img src="https://raw.githubusercontent.com/Comfy-Org/workflow_templates/main/templates/utility_moge_depth_estimation-2.webp" alt="깊이 추정 컬러 미리보기" style={{maxWidth: '48%', height: 'auto'}} />

  <img src="https://raw.githubusercontent.com/Comfy-Org/workflow_templates/main/templates/utility_moge_depth_estimation-1.webp" alt="깊이 추정 원본 미리보기" style={{maxWidth: '48%', height: 'auto'}} />
</div>

### 1.1 실행 단계

1. `LoadMoGeModel` 노드가 MoGe 체크포인트를 로드했는지 확인
2. `Load Image` 노드에서 이미지를 로드
3. `Queue`를 클릭하거나 `Ctrl(cmd) + Enter`를 사용해 실행
4. 워크플로우는 컬러화된 깊이 미리보기, 원본 깊이 미리보기 및 마스크를 출력합니다.

***

## 2. 투시도에서 메시 생성

**작동 방식**: 단일 투시 사진을 질감이 적용된 GLB 메시로 변환하며, 법선 및 깊이 미리보기를 함께 제공합니다. MoGe는 보이는 장면에서 점 지도, 깊이 및 법선을 추정한 후 이를 메시로 변환합니다. 이는 **단안 기하학 추정**으로, 가려진 부분과 객체 뒷면은 누락되거나 조각나게 됩니다. 빠른 장면 프로토타입, 참조 기하학 또는 깊이와 법선을 메시로 시각화하는 데 유용하지만, 다중뷰 3D 재구성의 대체물은 아닙니다.

<Card title="워크플로우 다운로드" icon="download" href="https://github.com/Comfy-Org/workflow_templates/blob/main/templates/3d_moge_perspective_to_mesh.json">
  JSON 다운로드하거나 템플릿 라이브러리에서 "3D MoGe 투시도에서 메시 생성" 검색
</Card>

<Card title="샘플 이미지 다운로드" icon="image" href="https://raw.githubusercontent.com/Comfy-Org/workflow_templates/main/input/modern_living_room.png">
  이 워크플로우의 예제 입력 이미지 받기
</Card>

![투시도에서 메시 생성 미리보기](https://raw.githubusercontent.com/Comfy-Org/workflow_templates/main/templates/3d_moge_perspective_to_mesh-1.webp)

### 2.1 실행 단계

1. `LoadMoGeModel` 노드가 MoGe 체크포인트를 로드했는지 확인
2. `Load Image` 노드에서 투시 사진을 로드
3. (선택사항) OpenGL 및 DirectX 법선 미리보기를 확인
4. `Queue`를 클릭하거나 `Ctrl(cmd) + Enter`를 사용해 실행

***

## 3. 파노라마에서 메시 생성

**작동 방식**: 등거리(360°) 파노라마를 질감이 적용된 GLB 메시로 변환합니다. 워크플로우는 `MoGePanoramaInference`를 사용해 파노라마를 12개의 투시도로 분할한 후 각각의 투시도에서 단안 기하학 추정을 독립적으로 수행한 후 이를 하나의 메시로 합칩니다. 각 세그먼트는 여전히 단일뷰 추정이므로 결과는 대략적인 장면 재구성입니다. 360° 장면의 공간적 개요를 얻는 데 유용하지만, 가려진 부분과 표면 뒤쪽의 기하학은 누락되거나 조각나게 됩니다.

<Card title="워크플로우 다운로드" icon="download" href="https://github.com/Comfy-Org/workflow_templates/blob/main/templates/3d_moge_panorama_to_mesh.json">
  JSON 다운로드하거나 템플릿 라이브러리에서 "3D MoGe 파노라마에서 메시 생성" 검색
</Card>

<Card title="샘플 이미지 다운로드" icon="image" href="https://raw.githubusercontent.com/Comfy-Org/workflow_templates/main/input/lego_street_panorama.png">
  이 워크플로우의 예제 입력 이미지 받기
</Card>

![파노라마에서 메시 생성 미리보기](https://raw.githubusercontent.com/Comfy-Org/workflow_templates/main/templates/3d_moge_panorama_to_mesh-1.webp)

### 3.1 실행 단계

1. `LoadMoGeModel` 노드가 MoGe 체크포인트 중 하나를 로드했는지 확인
2. `Load Image` 노드에서 등거리 파노라마 이미지를 로드
3. `Queue`를 클릭하거나 `Ctrl(cmd) + Enter`를 사용해 실행

***

## 커뮤니티 자료

* [MoGe GitHub (microsoft/MoGe)](https://github.com/microsoft/MoGe) — 연구 논문 및 코드
* [Comfy-Org/MoGe](https://huggingface.co/Comfy-Org/MoGe) — 공식 ComfyUI 모델 가중치
