diff --git a/index.html b/index.html index f32419f..797c48d 100644 --- a/index.html +++ b/index.html @@ -339,7 +339,7 @@ - + @@ -368,10 +368,10 @@ - + diff --git a/js/ui/tool/dream.js b/js/ui/tool/dream.js index 7760de4..daa0670 100644 --- a/js/ui/tool/dream.js +++ b/js/ui/tool/dream.js @@ -177,6 +177,7 @@ const _dream = async (endpoint, request) => { * @returns {Promise} */ const _generate = async (endpoint, request, bb, options = {}) => { + var alertCount = 0; defaultOpt(options, { drawEvery: 0.2 / request.n_iter, keepUnmask: null, @@ -532,9 +533,14 @@ const _generate = async (endpoint, request, bb, options = {}) => { seeds.push(...dreamData.seeds); imageindextxt.textContent = `${at}/${images.length - 1}`; } catch (e) { - alert( - `Error generating images. Please try again or see console for more details` - ); + if (alertCount < 2) { + alert( + `Error generating images. Please try again or see console for more details` + ); + } else { + eagerGenerateCount = 0; + } + alertCount++; console.warn(`[dream] Error generating images:`); console.warn(e); } finally {