fix api_mode in Series

This commit is contained in:
xtayex 2022-02-11 15:13:16 +08:00
parent a3e95d68ee
commit 82f999a847

View File

@ -30,7 +30,7 @@ class Parallel(gradio.Interface):
}
kwargs.update(options)
super().__init__(**kwargs)
self.api_mode = interfaces[0].api_mode # TODO(abidlabs): make api_mode a per-function attribute
self.api_mode = interfaces[0].api_mode # TODO(abidlabs): make api_mode a per-function attribute
class Series(gradio.Interface):
@ -81,6 +81,4 @@ class Series(gradio.Interface):
}
kwargs.update(options)
super().__init__(**kwargs)
self.api_mode = (
interfaces[0].api_mode,
) # TODO(abidlabs): make api_mode a per-function attribute
self.api_mode = interfaces[0].api_mode # TODO(abidlabs): make api_mode a per-function attribute