ComfyUI Node

3D_TrainConfig

The control room for the whole Paint3D pipeline

By N3rd00d·Created 2 years ago·Updated 2 years ago· 77
3D_TrainConfig
  • ckpt
  • clip
  • vae
  • positive
  • negative
  • depth_controlnet
  • inpaint_controlnet
  • TRAINCONFIG
mesh_file_path
sampler
scheduler
seed-1
txt2img_steps20
txt2img_cfg8.0
txt2img_denoise1.00
inpaint_steps20
inpaint_cfg3.0
inpaint_denoise1.00
depth_strength1.00
inpaint_strength0.50
projection_mode
look_at_height0.25
cam_front0
cam_back23
cam_left5
cam_right6
cam_top24
cam_bottom25
grid_size512

Calling this node "TrainConfig" is a leftover from the Paint3D research code it wraps - there's no training happening. What 3D_TrainConfig actually is: the single place where you declare every global setting the whole texturing pipeline will use. One config object, threaded through the rest of the graph, so you're not re-entering the mesh path or the camera angles in six different nodes.

What it does

It packages a giant pile of inputs into one TRAINCONFIG object. Downstream, 3D_LoadMeshModel reads the mesh path out of it, 3D_TrainConfigPipe unpacks everything back into normal wires for KSampler, and the render nodes read the camera list, grid size, and projection mode from it. Think of it as the environment block for the entire pack - everything else is downstream of this node, so it sits at the top-left of the bundled workflow.

The inputs that matter

You don't need to touch all ~27 of them. The ones a beginner actually sets:

  • mesh_file_path - absolute path to your .obj file. This is the model you're texturing. The pack ships a sample (Suzanne_monkey.obj) if you want to test before committing your own mesh.
  • ckpt / clip / vae - wire in your checkpoint loader. SD1.5 checkpoint, no way around it; the UV Pos ControlNet this whole thing depends on only exists for SD1.5. The bundled workflow uses a revAnimated-style anime checkpoint with a VAE.
  • positive / negative - the common prompt for all sampling stages. The README has a specific tip here: for the albedo (lightless texture) you want a negative like strong light, bright light, intense light, dazzling light, brilliant light, radiant light, shade, darkness, silhouette, dimness, obscurity, shadow, glasses. You're sampling a diffuse texture, not a lit render - keep lighting words out of the positive too. The README is honest that the effect is "minor, but better than nothing."
  • txt2img_* / inpaint_* - steps, CFG, and denoise, separately tuned for the front/back sampling stage vs. the rotating inpaint stage. Defaults are 20 steps, txt2img CFG 8, inpaint CFG 3.
  • depth_strength / depth_controlnet and inpaint_strength / inpaint_controlnet - the two ControlNets and their weights. Depth holds geometry during the initial pass (default strength 1.0); inpaint control fills in the unpainted views (default 0.5). Feed the models from ControlNetLoader nodes.
  • projection_mode - Orthographic or Pinhole. Defaults to Orthographic (the fov is tuned for it in the source); Pinhole is the perspective alternative.
  • cam_front / cam_back / cam_left / cam_right / cam_top / cam_bottom - the six camera indices used throughout. Defaults (0, 23, 5, 6, 24, 25) correspond to views in the renderer's 26-view rotation, and they're what every cam1/cam2 parameter elsewhere should match.
  • grid_size - render resolution, default 512. The latent that comes out of the pipe is 1024×512 to match.

Output

One output: train_config (TRAINCONFIG). It feeds 3D_LoadMeshModel and 3D_TrainConfigPipe.

Installing

ComfyUI Manager → search ComfyUI-Paint3D-Nodes, or:

cd ComfyUI/custom_nodes
git clone https://github.com/N3rd00d/ComfyUI-Paint3D-Nodes
pip install -r requirements.txt
pip install kaolin==0.15.0 -f https://nvidia-kaolin.s3.us-east-2.amazonaws.com/torch-2.1.0_cu121.html

The kaolin install is the fragile bit - if your torch version doesn't match the wheel, the README tells you to pin torch==2.1.0 + cu121 and reinstall. Two ControlNet downloads: depth + inpaint from comfyanonymous/ControlNet-v1-1_fp16_safetensors, plus the UV Pos ControlNet from GeorgeQi/Paint3d_UVPos_Control. All three go in ComfyUI/models/controlnet.

Gotchas

Since this node holds the mesh path, a typo here fails everywhere downstream - double-check it. And remember this pack is SD1.5-only; plugging an SDXL or Flux checkpoint in will just error out when the ControlNets load. There's essentially no community troubleshooting to lean on for this pack, so if sampling settings give you seams later, the fix is usually the two strength dials here rather than anything deeper.

CategoryPaint3D

Inputs (28)

NameTypeDefaultDescription
mesh_file_pathSTRING
ckptMODEL
clipCLIP
vaeVAE
samplerCOMBO34 options: euler, euler_cfg_pp, euler_ancestral, euler_ancestral_cfg_pp, heun, heunpp2, +28
schedulerCOMBO9 options: normal, karras, exponential, sgm_uniform, simple, ddim_uniform, +3
positiveCONDITIONING
negativeCONDITIONING
seedINT-1
txt2img_stepsINT201–10000
txt2img_cfgFLOAT8.00–100
txt2img_denoiseFLOAT1.000–1
inpaint_stepsINT201–10000
inpaint_cfgFLOAT3.00–100
inpaint_denoiseFLOAT1.000–1
depth_strengthFLOAT1.000–10
depth_controlnetCONTROL_NET
inpaint_strengthFLOAT0.500–10
inpaint_controlnetCONTROL_NET
projection_modeCOMBO2 options: Orthographic, Pinhole
look_at_heightFLOAT0.25
cam_frontINT00–25
cam_backINT230–25
cam_leftINT50–25
cam_rightINT60–25
cam_topINT240–25
cam_bottomINT250–25
grid_sizeINT512

Outputs (1)

NameTypeDescription
TRAINCONFIGTRAINCONFIG