diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/gui_index.c | 2 | ||||
-rw-r--r-- | src/indexamajig.c | 11 | ||||
-rw-r--r-- | src/process_image.h | 1 |
3 files changed, 13 insertions, 1 deletions
diff --git a/src/gui_index.c b/src/gui_index.c index f244f1f5..4b7254de 100644 --- a/src/gui_index.c +++ b/src/gui_index.c @@ -519,7 +519,7 @@ static void run_indexing_once(struct crystfelproject *proj) ipriv = setup_indexing(methods, cell, proj->indexing_params.tols, indexing_flags(&proj->indexing_params), - proj->cur_image->lambda, + proj->cur_image->lambda, 1, taketwoopts, xgandalf_opts, pinkIndexer_opts, felix_opts); free(methods); diff --git a/src/indexamajig.c b/src/indexamajig.c index f6ff129c..e4da883a 100644 --- a/src/indexamajig.c +++ b/src/indexamajig.c @@ -458,6 +458,13 @@ static error_t parse_arg(int key, char *arg, struct argp_state *state) } break; + case 414 : + if (sscanf(arg, "%d", &args->iargs.n_threads) != 1) + { + ERROR("Invalid value for --max-indexer-threads\n"); + return EINVAL; + } + break; /* ---------- Integration ---------- */ case 501 : @@ -670,6 +677,7 @@ int main(int argc, char *argv[]) args.iargs.no_image_data = 0; args.iargs.no_mask_data = 0; args.iargs.wavelength_estimate = NAN; + args.iargs.n_threads = 1; argp_program_version_hook = show_version; @@ -769,6 +777,8 @@ int main(int argc, char *argv[]) {"no-cell-combinations", 412, NULL, OPTION_HIDDEN, NULL}, {"wavelength-estimate", 413, "metres", 0, "Estimate of the incident radiation wavelength, in metres."}, + {"max-indexer-threads", 414, "n", 0, + "Maximum number of threads allowed for indexing engines."}, {NULL, 0, 0, OPTION_DOC, "Integration options:", 5}, {"integration", 501, "method", OPTION_NO_USAGE, "Integration method"}, @@ -971,6 +981,7 @@ int main(int argc, char *argv[]) args.iargs.tols, flags, args.iargs.wavelength_estimate, + args.iargs.n_threads, taketwo_opts, xgandalf_opts, pinkindexer_opts, diff --git a/src/process_image.h b/src/process_image.h index 8174f73d..703f0cde 100644 --- a/src/process_image.h +++ b/src/process_image.h @@ -99,6 +99,7 @@ struct index_args int no_image_data; int no_mask_data; float wavelength_estimate; + int n_threads; }; |