Discrepancy in scheduler `offset` usage
See original GitHub issueWhat API design would you like to have changed or added to the library? Why?
@jonatanklosko brought up an issue with some confusing code (why are alphas
indexed differently across PNDMScheduler
and DDIMScheduler
), and some inconsistency in the offset usage.
Two questions:
- Why does only one shift by offset?
- Can
offset
be changed from an arbitraryint
to abool
setting that shifts by 1 (the integer shift is more confusing if the only use case is stable diffusion inference withoffset = 1
)
Discussion began in #444, see here
I can tell you that the PNDMScheduler and DDIMScheduler have indexed the alpha’s differently for a while. Before introducing offset, PNDMScheduler had
alpha_prod_t = self.alphas_cumprod[timestep + 1]
alpha_prod_t_prev = self.alphas_cumprod[timestep_prev + 1]
And DDIMScheduler had
alpha_prod_t = self.alphas_cumprod[timestep]
alpha_prod_t_prev = self.alphas_cumprod[timestep_prev]
At minimum, we can figure this out and document better!
Issue Analytics
- State:
- Created a year ago
- Reactions:1
- Comments:13 (13 by maintainers)
Top Results From Across the Web
Understanding Offset Concepts - Cisco
Enterprise Scheduler follows certain concepts when it compiles a production schedule. The concepts are basic but can result in complicated timing scenarios ...
Read more >Data Discrepancy Troubleshooting Guide | Stitch Documentation
Row count discrepancies describe discrepancies that affect the number of records in your destination. Complete records may be missing, ...
Read more >Reports Scheduler
Enter the criteria you want to use to search for reports that are scheduled. Report Name. Name of the scheduled report you wish...
Read more >VistA Scheduling Enhancements (VSE) VS GUI User Guide
1.2 Overview. VS GUI is a software module that allows schedulers to make appointments quickly by viewing multiple appointment request types ...
Read more >Quantifying the Underlying Causes of a Discrepancy Between ...
This gives rise to significant discrepancies between simulation results and actual measured energy consumption, termed “the performance gap.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
By
timesteps[n]
you probably meantalphas_cumprod[n]
in the list of cases above, no?Also here:
I don’t see why we need to add the offset. For example, at timestamp
101
, prev timestamp would be1
, so we want to takealphas_cumprod[1]
rather thanalphas_cumprod[1 + self._offset]
.Just to summarize, I think by having both:
steps_offset
andset_alpha_to_one
in the config as you suggested @jonatanklosko we should enable all use cases that we need. We should then indeed document this nicely.@jonatanklosko very cool summary here, let me know if you need any help 😃