fix live preview

This commit is contained in:
Vladimir Mandic
2023-04-19 07:52:26 -04:00
parent 2b1b75dd12
commit ee3cea54eb
6 changed files with 28 additions and 32 deletions
+2 -7
View File
@@ -3,15 +3,10 @@
function start_training_textual_inversion(){
gradioApp().querySelector('#ti_error').innerHTML=''
var id = randomId()
requestProgress(id, gradioApp().getElementById('ti_output'), gradioApp().getElementById('ti_gallery'), function(){}, function(progress){
gradioApp().getElementById('ti_progress').innerHTML = progress.textinfo
})
const onProgress = (progress) => gradioApp().getElementById('ti_progress').innerHTML = progress.textinfo;
requestProgress(id, gradioApp().getElementById('ti_output'), gradioApp().getElementById('ti_gallery'), null, onProgress, false)
var res = args_to_array(arguments)
res[0] = id
return res
}