Skip to content

Commit

Permalink
amended cli scripts to function better
Browse files Browse the repository at this point in the history
  • Loading branch information
adityasevak123ga committed Nov 23, 2023
1 parent 3c0e9d0 commit 54745c8
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions uncoverml/scripts/uncoverml.py
Expand Up @@ -337,7 +337,8 @@ def unsupervised(config):
@click.argument('calling_process')
@click.option('-p', '--partitions', type=int, default=1,
help='divide each node\'s data into this many partitions')
@click.option('-i', '--interface_job', type=bool, default=False)
@click.option('-i', '--interface_job', is_flag=True,
help='Flag that the call is coming from an interface job')
def validate(pipeline_file, model_or_cluster_file, calling_process, partitions, interface_job):
"""Validate a model with out-of-sample shapefile."""
with open(model_or_cluster_file, 'rb') as f:
Expand Down Expand Up @@ -376,7 +377,8 @@ def validate(pipeline_file, model_or_cluster_file, calling_process, partitions,
help='mask values where to predict')
@click.option('-t', '--prediction_template', type=click.Path(exists=True), default=None,
help='mask values where to predict')
@click.option('-i', '--interface_job', type=bool, default=False)
@click.option('-i', '--interface_job', is_flag=True,
help='Flag that the call is coming from an interface job')
def predict(model_or_cluster_file, partitions, mask, retain, prediction_template, interface_job):
with open(model_or_cluster_file, 'rb') as f:
state_dict = joblib.load(f)
Expand Down

0 comments on commit 54745c8

Please sign in to comment.