Skip to content

Add multi image referenece#104

Open
dongjinlee123 wants to merge 1 commit intomicrosoft:mainfrom
dongjinlee123:main
Open

Add multi image referenece#104
dongjinlee123 wants to merge 1 commit intomicrosoft:mainfrom
dongjinlee123:main

Conversation

@dongjinlee123
Copy link

@dongjinlee123 dongjinlee123 commented Feb 4, 2026

Multi-image conditioning to TRELLIS.2 for improved 3D reconstruction from multiple views.

Features

  • Multi-image pipeline: Support 2+ images as input via sampler injection
  • Two fusion modes:
    • stochastic: Cycles through images (memory efficient)
    • multidiffusion: Averages all images (higher quality)
  • Gradio UI: Added multi-image mode toggle with gallery input
  • Example script: Simple example_multi_image.py following example.py style

Changes

  • app.py: Multi-image UI and processing logic
  • trellis2/pipelines/trellis2_image_to_3d.py: Added inject_sampler_multi_image() method
  • example_multi_image.py: Standalone example for multi-image generation

Usage

Gradio App:
Toggle "Enable Multi-Image Mode" and upload multiple views

python app.py

Python Script:

python example_multi_image.py

@dongjinlee123
Copy link
Author

@dongjinlee123 please read the following Contributor License Agreement(CLA). If you agree with the CLA, please reply with the following information.

@microsoft-github-policy-service agree [company="{your company}"]

Options:

  • (default - no company specified) I have sole ownership of intellectual property rights to my Submissions and I am not making Submissions in the course of work for my employer.
@microsoft-github-policy-service agree
  • (when company given) I am making Submissions in the course of work for my employer (or my employer has intellectual property rights in my Submissions by contract or applicable law). I have permission from my employer to make Submissions and enter into this Agreement on behalf of my employer. By signing below, the defined term “You” includes me and my employer.
@microsoft-github-policy-service agree company="Microsoft"

Contributor License Agreement

@microsoft-github-policy-service agree

@liyupeng-ing
Copy link

liyupeng-ing commented Feb 4, 2026

Hello, thank you for your code. During testing, I found that the generated 3D model results appear fatter or thinner than expected—in other words, there are deformation deviations relative to the input image. What could be causing this?

@dongjinlee123
Copy link
Author

Hello, thank you for your code. During testing, I found that the generated 3D model results appear fatter or thinner than expected—in other words, there are deformation deviations relative to the input image. What could be causing this?

It might be because we are averaging the output from multiple views (multidiffusion). I am currently working on a fusion method that prioritize results of an image that model is more confident in instead of averaging all the result which might lead to inaccurate result.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants