summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--cli/app/commands/biggan/search_class.py4
-rw-r--r--cli/app/search/search_class.py2
2 files changed, 3 insertions, 3 deletions
diff --git a/cli/app/commands/biggan/search_class.py b/cli/app/commands/biggan/search_class.py
index 066062f..6e1df95 100644
--- a/cli/app/commands/biggan/search_class.py
+++ b/cli/app/commands/biggan/search_class.py
@@ -20,9 +20,9 @@ from app.utils.cortex_utils import cortex_folder, download_cortex_files, find_un
@click.option('-t', '--tag', 'opt_tag', default='inverse_' + str(int(time.time() * 1000)),
help='Tag this dataset')
@click.option('-sc', '--stochastic_clipping', 'opt_stochastic_clipping', default=0,
- help='Compute feature loss')
+ help='Compute feature loss. Specify interval to do the clipping')
@click.option('-lc', '--label_clipping', 'opt_label_clipping', default=0,
- help='Normalize labels every N steps')
+ help='Normalize labels every N steps. Specify interval to do the normalization')
@click.option('-feat', '--use_feature_detector', 'opt_use_feature_detector', is_flag=True,
help='Compute feature loss')
@click.option('-ll', '--feature_layers', 'opt_feature_layers', default="1a,2a,4a,7a",
diff --git a/cli/app/search/search_class.py b/cli/app/search/search_class.py
index a4bec07..cd53a71 100644
--- a/cli/app/search/search_class.py
+++ b/cli/app/search/search_class.py
@@ -116,7 +116,7 @@ def find_nearest_vector(sess, generator, opt_fp_in, opt_dims, out_images, out_la
## if computing Feature loss, use these encoders
if opt_use_feature_detector:
print("Initializing feature detector...")
- pix_square_diff = tf.square((target_img - gen_img) / 2.0)
+ pix_square_diff = tf.square((target - output) / 2.0)
mse_loss = tf.reduce_mean(pix_square_diff)
feature_extractor = hub.Module("https://tfhub.dev/google/imagenet/inception_v3/feature_vector/1")