Skip to content

Commit

Permalink
Merge pull request #406 from ebolam/Model_Plugins
Browse files Browse the repository at this point in the history
Clarified message on what's required for model backend parameters
  • Loading branch information
henk717 authored Jul 18, 2023
2 parents 5bbcdc4 + 66192ef commit 5f2600d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions aiserver.py
Original file line number Diff line number Diff line change
Expand Up @@ -1619,12 +1619,12 @@ def new_emit(*args, **kwargs):
elif parameter['id'] not in arg_parameters:
arg_parameters[parameter['id']] = parameter['default']
if not ok_to_load:
logger.error("Your selected backend needs additional parameters to run. Please pass through the parameters as a json like {\"[ID]\": \"[Value]\"} using --model_parameters (required parameters shown below)")
logger.error("Your selected backend needs additional parameters to run. Please pass through the parameters as a json like \"{'[ID]': '[Value]', '[ID2]': '[Value]'}\" using --model_parameters (required parameters shown below)")
logger.error("Parameters (ID: Default Value (Help Text)): {}".format("\n".join(["{}: {} ({})".format(x['id'],x['default'],x['tooltip']) for x in parameters if x['uitype'] != "Valid Display"])))
logger.error("Missing: {}".format(", ".join(mising_parameters)))
exit()
if args.model_parameters.lower() == "help":
logger.error("Please pass through the parameters as a json like {\"[ID]\": \"[Value]\"} using --model_parameters (required parameters shown below)")
logger.error("Please pass through the parameters as a json like \"{'[ID]': '[Value]', '[ID2]': '[Value]'}\" using --model_parameters (required parameters shown below)")
logger.error("Parameters (ID: Default Value (Help Text)): {}".format("\n".join(["{}: {} ({})".format(x['id'],x['default'],x['tooltip']) for x in parameters if x['uitype'] != "Valid Display"])))
exit()
arg_parameters['id'] = args.model
Expand Down

0 comments on commit 5f2600d

Please sign in to comment.