This commit is contained in:
Abubakar Abid 2020-07-02 17:40:37 -05:00
parent 4fd27784f8
commit ea05fc5f62
8 changed files with 10 additions and 6 deletions

View File

@ -308,7 +308,11 @@ class Image(AbstractInput):
return array
def process_example(self, example):
return preprocessing_utils.convert_file_to_base64(example)
if os.path.exists(example):
return preprocessing_utils.convert_file_to_base64(example)
else:
return example
class Microphone(AbstractInput):

View File

@ -11,15 +11,15 @@ const radio = {
}
html += "</div>"
this.target.html(html);
this.target.find("input:first-child").prop("checked", true);
},
submit: function() {
checked_val = this.target.find("input:checked").val();
if (checked_val) {
this.io_master.input(this.id, this.choices[checked_val]);
}
this.io_master.input(this.id, this.choices[checked_val]);
},
clear: function() {
this.target.find("input").prop("checked", false);
this.target.find("input:first-child").prop("checked", true);
},
load_example: function(data) {
let child = this.choices.indexOf(data) + 1;

Binary file not shown.

Binary file not shown.

BIN
dist/gradio-0.9.7-py3-none-any.whl vendored Normal file

Binary file not shown.

BIN
dist/gradio-0.9.7.tar.gz vendored Normal file

Binary file not shown.

View File

@ -1,6 +1,6 @@
Metadata-Version: 1.0
Name: gradio
Version: 0.9.6
Version: 0.9.7
Summary: Python library for easily interacting with trained machine learning models
Home-page: https://github.com/gradio-app/gradio-UI
Author: Abubakar Abid

View File

@ -5,7 +5,7 @@ except ImportError:
setup(
name='gradio',
version='0.9.6',
version='0.9.7',
include_package_data=True,
description='Python library for easily interacting with trained machine learning models',
author='Abubakar Abid',