summaryrefslogtreecommitdiff
path: root/cli/app/commands/biggan/search_class.py
diff options
context:
space:
mode:
authorJules Laplace <julescarbon@gmail.com>2020-01-08 01:59:20 +0100
committerJules Laplace <julescarbon@gmail.com>2020-01-08 01:59:20 +0100
commit2034d4c0cd241106900273980ee84f808a73d196 (patch)
treee1a331d6fd0288561a5b4944eadcdcb25514ac2b /cli/app/commands/biggan/search_class.py
parenta194eaa66108d753aac1eac70b7016a9b20897e1 (diff)
up
Diffstat (limited to 'cli/app/commands/biggan/search_class.py')
-rw-r--r--cli/app/commands/biggan/search_class.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/cli/app/commands/biggan/search_class.py b/cli/app/commands/biggan/search_class.py
index 6e1df95..050fbef 100644
--- a/cli/app/commands/biggan/search_class.py
+++ b/cli/app/commands/biggan/search_class.py
@@ -29,10 +29,11 @@ from app.utils.cortex_utils import cortex_folder, download_cortex_files, find_un
help='Feature layers used for loss')
@click.option('-snap', '--snapshot_interval', 'opt_snapshot_interval', default=20,
help='Interval to store sample images')
-
+@click.option('-snap', '--clip_interval', 'opt_clip_interval', default=500,
+ help='Interval to clip vectors')
@click.pass_context
def cli(ctx, opt_folder_id, opt_fp_in, opt_dims, opt_steps, opt_limit, opt_video, opt_tag,
- opt_stochastic_clipping, opt_label_clipping, opt_use_feature_detector, opt_feature_layers, opt_snapshot_interval):
+ opt_stochastic_clipping, opt_label_clipping, opt_use_feature_detector, opt_feature_layers, opt_snapshot_interval, opt_clip_interval):
"""
Search for an image (class vector) in BigGAN using gradient descent
"""
@@ -59,4 +60,4 @@ def cli(ctx, opt_folder_id, opt_fp_in, opt_dims, opt_steps, opt_limit, opt_video
opt_feature_layers = opt_feature_layers.split(',')
find_nearest_vector_for_images(paths, opt_dims, opt_steps, opt_video, opt_tag, opt_limit,
- opt_stochastic_clipping, opt_label_clipping, opt_use_feature_detector, opt_feature_layers, opt_snapshot_interval)
+ opt_stochastic_clipping, opt_label_clipping, opt_use_feature_detector, opt_feature_layers, opt_snapshot_interval, opt_clip_interval)