when i try use pulid, will get error Chroma' object has no attribute 'time_in'. i need help to use pulid.

#31
by leeGee22 - opened

Error Details

  • Node ID: 67
  • Node Type: SamplerCustomAdvanced
  • Exception Type: AttributeError
  • Exception Message: 'Chroma' object has no attribute 'time_in'

Stack Trace

This comment has been hidden (marked as Off-Topic)

It's a shame that it doesn't work. Chroma is best model yet and growing pains I guess. I'm sure it's going to take off soon and get all those kinks worked out.

Is this a part of the model itself? And is this something that is missing for now, in development. Or is this a part that's not going to be incorporated into the model in the future?

ChatGPT says...

time_in is one of the three projection MLPs that sit right at the entrance of every FLUX-style UNet (img_in, time_in, vector_in).
During every denoising step the sampler first converts the current diffusion timestep t into a 256-dim sinusoidal embedding, then feeds that vector through time_in:

text
Copy
t_emb = timestep_embedding(t, 256) # sin / cos encoding
cond = self.time_in(t_emb) # 256 → 3 072 projection
The projected tensor is later added-or-gated into all transformer blocks so the network “knows” which diffusion step it is processing. The PULID/TeaCache wrapper that SamplerCustomAdvanced installs hooks that layer to cache its output, which is why it is accessed explicitly in their patched forward:

ini
Copy
vec = self.time_in(timestep_embedding(timesteps, 256).to(img.dtype)) # TeaCache line 58
Why the error shows up with Chroma
The Chroma checkpoints you’re loading are derived from FLUX-schnell but the authors have refactored the model class and renamed or removed time_in (often folded into a generic time_emb or time_proj).
Because the attribute is missing, TeaCache (and therefore the PULID node that depends on it) raises:

pgsql
Copy
AttributeError: 'Chroma' object has no attribute 'time_in'
Exactly the same stack-trace was reported on the TeaCache issue tracker, and the maintainer confirmed that Chroma isn’t supported yet .

What you can do right now
Option What it means How to try it
Disable TeaCache / PuLID for this run Use the plain built-in Sampler or KSampler nodes with Chroma. Remove the TeaCache or PuLID node(s) from the graph and connect the sampler directly.
Wait for an update The TeaCache / PuLID authors will need to add a compatibility shim that points their code to Chroma’s renamed layer. Keep the extension up-to-date; watch TeaCache #128 for progress.
Quick monkey-patch (experimental) After loading the checkpoint but before sampling, inject a dummy alias:
if not hasattr(model.diffusion_model, "time_in") and hasattr(model.diffusion_model, "time_proj"):
  model.diffusion_model.time_in = model.diffusion_model.time_proj Add a tiny “PyExecute” node before the sampler. Works only if Chroma exposes an equivalent layer (often time_proj).

Take-away
time_in is simply the FLUX module that projects the timestep embedding.
It isn’t missing in your environment—only in Chroma’s rewritten class—so the fix is to either use a sampler that doesn’t rely on TeaCache/PULID or wait until those extensions add explicit support for Chroma’s new attribute names.

I discovered that the Native Comfyui Pulid Node works just fine with Chroma and it is being actively updated.
https://github.com/cubiq/PuLID_ComfyUI

I discovered that the Native Comfyui Pulid Node works just fine with Chroma and it is being actively updated.
https://github.com/cubiq/PuLID_ComfyUI

Do you have a workflow example that works, haven't been able to find anything. Thanks

I discovered that the Native Comfyui Pulid Node works just fine with Chroma and it is being actively updated.
https://github.com/cubiq/PuLID_ComfyUI

Can you verify you've linked the right custom_node? the one you link says:

"2025.04.14 - I do not use ComfyUI as my main way to interact with Gen AI anymore as a result I'm setting the repository in "maintenance only" mode."

Also, I too cannot get this custom node to work with Chroma. I believe this particular custom node does not support flux native, also with the enhancement mod for flux it does not work with Chroma.
This leaves me to believe you might have used a different node than you've mentioned.

Sign up or log in to comment