Update app.py
Browse files
app.py
CHANGED
@@ -1,15 +1,8 @@
|
|
1 |
import gradio as gr
|
2 |
import tensorflow as tf
|
3 |
-
import wget
|
4 |
|
5 |
-
|
6 |
-
|
7 |
-
|
8 |
-
dec_url = 'https://huggingface.co/ariG23498/nst/blob/main/nst-decoder.h5'
|
9 |
-
dec_filename = wget.download(dec_url)
|
10 |
-
|
11 |
-
encoder = tf.keras.models.load_model(enc_filename, compile=False)
|
12 |
-
decoder = tf.keras.models.load_model(dec_filename, compile=False)
|
13 |
|
14 |
def get_mean_std(tensor, epsilon=1e-5):
|
15 |
axes = [1, 2]
|
|
|
1 |
import gradio as gr
|
2 |
import tensorflow as tf
|
|
|
3 |
|
4 |
+
encoder = tf.keras.models.load_model("nst-encoder.h5", compile=False)
|
5 |
+
decoder = tf.keras.models.load_model("nst-decoder.h5", compile=False)
|
|
|
|
|
|
|
|
|
|
|
|
|
6 |
|
7 |
def get_mean_std(tensor, epsilon=1e-5):
|
8 |
axes = [1, 2]
|