From f6f8c8046766b93f8be847fa2c71f0cbaf7c5919 Mon Sep 17 00:00:00 2001 From: Thomas White Date: Sat, 1 Aug 2015 18:53:45 +0200 Subject: partialator: Add --no-free (for testing only) --- doc/man/partialator.1 | 5 +++++ src/partialator.c | 7 +++++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/doc/man/partialator.1 b/doc/man/partialator.1 index 272c97a9..572fe988 100644 --- a/doc/man/partialator.1 +++ b/doc/man/partialator.1 @@ -110,6 +110,11 @@ Ignore the first \fIn\fR crystals in the input. The default is \fB--start-after .PD Stop processing after \fIn\fR crystals have been successfully read. The default is \fB--stop-after=0\fR, which means to process all the patterns from the start point to the end of the input (see \fB--start-after\fR). +.PD 0 +.IP \fB--no-free\fR +.PD +Disable cross-validation (for testing only). + .SH PARTIALITY MODELS The available partiality models are: diff --git a/src/partialator.c b/src/partialator.c index 614f439e..8a594116 100644 --- a/src/partialator.c +++ b/src/partialator.c @@ -81,7 +81,8 @@ static void show_help(const char *s) " --no-polarisation Disable polarisation correction.\n" " --max-adu= Saturation value of detector.\n" " --push-res= Merge higher than apparent resolution cutoff.\n" -" -j Run analyses in parallel.\n"); +" -j Run analyses in parallel.\n" +" --no-free Disable cross-validation (testing only).\n"); } @@ -357,6 +358,7 @@ int main(int argc, char *argv[]) FILE *sparams_fh; double push_res = 0.0; gsl_rng *rng; + int no_free = 0; /* Long options */ const struct option longopts[] = { @@ -383,6 +385,7 @@ int main(int argc, char *argv[]) {"no-polarization", 0, &polarisation, 0}, {"polarisation", 0, &polarisation, 1}, /* compat */ {"polarization", 0, &polarisation, 1}, /* compat */ + {"no-free", 0, &no_free, 1}, {0, 0, NULL, 0} }; @@ -632,7 +635,7 @@ int main(int argc, char *argv[]) cur); } - select_free_reflections(cr_refl, rng); + if ( !no_free ) select_free_reflections(cr_refl, rng); as = asymmetric_indices(cr_refl, sym); crystal_set_reflections(cr, as); -- cgit v1.2.3