updated PyPi version

This commit is contained in:
Abubakar Abid 2020-07-09 15:16:18 -05:00
parent f523e01e60
commit 7380632c35
3 changed files with 17 additions and 18 deletions

View File

@ -107,12 +107,20 @@ class Interface:
'host_name': hostname,
'ip_address': ip_address
}
if self.capture_session:
try:
import tensorflow as tf
self.session = tf.get_default_graph(), \
tf.keras.backend.get_session()
except (ImportError, AttributeError): # If they are using TF >= 2.0 or don't have TF, just ignore this.
pass
try:
print("try initiated")
requests.post(analytics_url + 'gradio-initiated-analytics/',
data=data)
except requests.ConnectionError:
print("gradio-initiated-analytics/ Connection Error")
pass # do not push analytics if no network
def get_config_file(self):
config = {
@ -144,7 +152,6 @@ class Interface:
return config
def process(self, raw_input):
processed_input = [input_interface.preprocess(
raw_input[i]) for i, input_interface in
@ -214,7 +221,7 @@ class Interface:
requests.post(analytics_url + 'gradio-error-analytics/',
data=data)
except requests.ConnectionError:
print("gradio-error-analytics/ Connection Error")
pass # do not push analytics if no network
if self.verbose:
print("\n----------")
print(
@ -230,7 +237,7 @@ class Interface:
requests.post(analytics_url + 'gradio-error-analytics/',
data=data)
except requests.ConnectionError:
print("gradio-error-analytics/ Connection Error")
pass # do not push analytics if no network
if self.verbose:
print("\n----------")
print(
@ -262,14 +269,6 @@ class Interface:
# if validate and not self.validate_flag:
# self.validate()
if self.capture_session:
try:
import tensorflow as tf
self.session = tf.get_default_graph(), \
tf.keras.backend.get_session()
except (ImportError, AttributeError): # If they are using TF >= 2.0 or don't have TF, just ignore this.
pass
output_directory = tempfile.mkdtemp()
# Set up a port to serve the directory containing the static files with interface.
server_port, httpd = networking.start_simple_server(self, output_directory, self.server_name)
@ -291,7 +290,7 @@ class Interface:
requests.post(analytics_url + 'gradio-error-analytics/',
data=data)
except requests.ConnectionError:
print("Connection Error")
pass # do not push analytics if no network
pass
try:
@ -325,7 +324,7 @@ class Interface:
requests.post(analytics_url + 'gradio-error-analytics/',
data=data)
except requests.ConnectionError:
print("Connection Error")
pass # do not push analytics if no network
share_url = None
if self.verbose:
print(strings.en["NGROK_NO_INTERNET"])
@ -404,7 +403,7 @@ class Interface:
requests.post(analytics_url + 'gradio-launched-analytics/',
data=data)
except requests.ConnectionError:
print("Connection Error")
pass # do not push analytics if no network
return httpd, path_to_local_server, share_url
@classmethod

View File

@ -1,6 +1,6 @@
Metadata-Version: 1.0
Name: gradio
Version: 0.9.9.7
Version: 0.9.9.8
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.9.7',
version='0.9.9.8',
include_package_data=True,
description='Python library for easily interacting with trained machine learning models',
author='Abubakar Abid',