diff --git a/docs/docs/api_docs/c_api.md b/docs/docs/api_docs/c_api.md index 0f04494..e1a7bd1 100644 --- a/docs/docs/api_docs/c_api.md +++ b/docs/docs/api_docs/c_api.md @@ -25,4 +25,4 @@ To use the API in your project use- share/openbr/cmake/OpenBRConfig.cmake -Please see the [tutorials](../tutorials.md) section for examples. \ No newline at end of file +Please see the [tutorials](../tutorials.md) section for examples. diff --git a/docs/docs/api_docs/c_api/functions.md b/docs/docs/api_docs/c_api/functions.md index 9d2b2e3..90bb8e2 100644 --- a/docs/docs/api_docs/c_api/functions.md +++ b/docs/docs/api_docs/c_api/functions.md @@ -4,7 +4,7 @@ Calls [Context](../cpp_api/context/context.md)::[about](../cpp_api/context/stati * **function definition:** - const char *br_about() + const char *br_about() * **parameters:** None * **output:** (const char *) Returns a string describing OpenBR @@ -18,15 +18,15 @@ Concatenates a list of galleries into 1 gallery. * **function definition:** - void br_cat(int num_input_galleries, const char *input_galleries[], const char *output_gallery) + void br_cat(int num_input_galleries, const char *input_galleries[], const char *output_gallery) * **parameters:** - Parameter | Type | Description - --- | --- | --- - num_input_galleries | int | Size of input_galleries - input_galleries[] | const char * | List of galleries - output_gallery | const char * | Pointer to store concatenated gallery + Parameter | Type | Description + --- | --- | --- + num_input_galleries | int | Size of input_galleries + input_galleries[] | const char * | List of galleries + output_gallery | const char * | Pointer to store concatenated gallery * **output:** void * **see:** [Cat](../cpp_api/apifunctions.md#cat) @@ -39,15 +39,15 @@ Removes duplicate [templates](../cpp_api/template/template.md) in a [gallery](.. * **function definition:** - void br_deduplicate(const char *input_gallery, const char *output_gallery, const char *threshold) + void br_deduplicate(const char *input_gallery, const char *output_gallery, const char *threshold) * **parameters:** - Parameter | Type | Description - --- | --- | --- - input_gallery | const char * | Gallery to be deduplicated - output_gallery | const char * | Deduplicated gallery - threshold | const char * | Comparisons with a match score >= this value are designated to be duplicates. + Parameter | Type | Description + --- | --- | --- + input_gallery | const char * | Gallery to be deduplicated + output_gallery | const char * | Deduplicated gallery + threshold | const char * | Comparisons with a match score >= this value are designated to be duplicates. * **output:** (void) @@ -59,16 +59,16 @@ Clusters one or more similarity matrices into a list of subjects. A [similarity * **function definition:** - void br_cluster(int num_simmats, const char *simmats[], float aggressiveness, const char *csv) + void br_cluster(int num_simmats, const char *simmats[], float aggressiveness, const char *csv) * **parameters:** - Parameter | Type | Description - --- | --- | --- - num_simmats | int | Size of **simmats** - simmats[] | const char * | Array of [simmat](../../tutorials.md#the-evaluation-harness) composing one large self-similarity matrix arranged in row major order. - aggressiveness | float | The higher the aggressiveness the larger the clusters. Suggested range is [0,10] - csv | const char * | The cluster results file to generate. Results are stored one row per cluster and use gallery indices. + Parameter | Type | Description + --- | --- | --- + num_simmats | int | Size of **simmats** + simmats[] | const char * | Array of [simmat](../../tutorials.md#the-evaluation-harness) composing one large self-similarity matrix arranged in row major order. + aggressiveness | float | The higher the aggressiveness the larger the clusters. Suggested range is [0,10] + csv | const char * | The cluster results file to generate. Results are stored one row per cluster and use gallery indices. * **output:** (void) @@ -80,16 +80,16 @@ Combines several equal-sized mask matrices. A comparison may not be simultaneous * **function definition:** - void br_combine_masks(int num_input_masks, const char *input_masks[], const char *output_mask, const char *method) + void br_combine_masks(int num_input_masks, const char *input_masks[], const char *output_mask, const char *method) * **parameters:** - Parameter | Type | Description - --- | --- | --- - num_input_masks | int | Size of **input_masks** - input_masks[] | const char * | Array of [mask matrices](../../tutorials.md#the-evaluation-harness) to combine. All matrices must have the same dimensions. - output_mask | const char * | The file to contain the resulting [mask matrix](../../tutorials.md#the-evaluation-harness) - method | const char * | Possible values are: + Parameter | Type | Description + --- | --- | --- + num_input_masks | int | Size of **input_masks** + input_masks[] | const char * | Array of [mask matrices](../../tutorials.md#the-evaluation-harness) to combine. All matrices must have the same dimensions. + output_mask | const char * | The file to contain the resulting [mask matrix](../../tutorials.md#the-evaluation-harness) + method | const char * | Possible values are: * **see:** [br_make_mask](#br_make_mask) @@ -101,15 +101,15 @@ Compares each [Template](../cpp_api/template/template.md) in the query [Gallery] * **function definition:** - void br_compare(const char *target_gallery, const char *query_gallery, const char *output = "") + void br_compare(const char *target_gallery, const char *query_gallery, const char *output = "") * **parameters:** - Parameter | Type | Description - --- | --- | --- - target_gallery | const char * | target_gallery The [Gallery](../cpp_api/gallery/gallery.md) file whose templates make up the columns of the output. - query_gallery | const char * | The [Gallery](../cpp_api/gallery/gallery.md) file whose templates make up the rows of the output. A value of '.' reuses the target gallery as the query gallery. - output | const char * | (Optional) The [Output](../cpp_api/output/output.md) file to contain the results of comparing the templates. The default behavior is to print scores to the terminal. + Parameter | Type | Description + --- | --- | --- + target_gallery | const char * | target_gallery The [Gallery](../cpp_api/gallery/gallery.md) file whose templates make up the columns of the output. + query_gallery | const char * | The [Gallery](../cpp_api/gallery/gallery.md) file whose templates make up the rows of the output. A value of '.' reuses the target gallery as the query gallery. + output | const char * | (Optional) The [Output](../cpp_api/output/output.md) file to contain the results of comparing the templates. The default behavior is to print scores to the terminal. * **output:** (void) * **see:** br_enroll @@ -122,16 +122,16 @@ Convenience function for comparing to multiple targets. * **function definition:** - void br_compare_n(int num_targets, const char *target_galleries[], const char *query_gallery, const char *output) + void br_compare_n(int num_targets, const char *target_galleries[], const char *query_gallery, const char *output) * **parameters:** - Parameter | Type | Description - --- | --- | --- - num_targets | int | Size of **target_galleries** - target_galleries[] | const char * | Target galleries to compare against - query_gallery | const char * | query gallery for comparison. - output | const char * | (Optional) [Output](../cpp_api/output/output.md) file to contain the results of comparing the templates. The default behavior is to print scores to the terminal. + Parameter | Type | Description + --- | --- | --- + num_targets | int | Size of **target_galleries** + target_galleries[] | const char * | Target galleries to compare against + query_gallery | const char * | query gallery for comparison. + output | const char * | (Optional) [Output](../cpp_api/output/output.md) file to contain the results of comparing the templates. The default behavior is to print scores to the terminal. * **output:** (void) * **see:** br_compare @@ -144,15 +144,15 @@ DOCUMENT ME! * **function definition:** - void br_pairwise_compare(const char *target_gallery, const char *query_gallery, const char *output = "") + void br_pairwise_compare(const char *target_gallery, const char *query_gallery, const char *output = "") * **parameters:** - Parameter | Type | Description - --- | --- | --- - target_gallery | const char * | DOCUMENT ME - query_gallery | const char * | DOCUMENT ME - output | const char * | DOCUMENT ME + Parameter | Type | Description + --- | --- | --- + target_gallery | const char * | DOCUMENT ME + query_gallery | const char * | DOCUMENT ME + output | const char * | DOCUMENT ME * **output:** (void) @@ -164,15 +164,15 @@ Convert a file to a different type. Files can only be converted to types within * **function definition:** - void br_convert(const char *file_type, const char *input_file, const char *output_file) + void br_convert(const char *file_type, const char *input_file, const char *output_file) * **parameters:** - Parameter | Type | Description - --- | --- | --- - file_type | const char * | Type of file to convert. Options are [Format](../cpp_api/format/format.md), [Gallery](../cpp_api/gallery/gallery.md) or [Output](../cpp_api/output/output.md). - input_file | const char * | File to convert. - output_file | const char * | Output file. Type is determined by the file extension. + Parameter | Type | Description + --- | --- | --- + file_type | const char * | Type of file to convert. Options are [Format](../cpp_api/format/format.md), [Gallery](../cpp_api/gallery/gallery.md) or [Output](../cpp_api/output/output.md). + input_file | const char * | File to convert. + output_file | const char * | Output file. Type is determined by the file extension. * **output:** (void) @@ -184,14 +184,14 @@ Constructs [Template(s)](../cpp_api/template/template.md) from an input. * **function definition:** - void br_enroll(const char *input, const char *gallery = "") + void br_enroll(const char *input, const char *gallery = "") * **parameters:** - Parameter | Type | Description - --- | --- | --- - input | const char * | The [format](../cpp_api/format/format.md) or [gallery](../cpp_api/gallery/gallery.md) to enroll. - gallery | const char * | (Optional) The [Gallery](../cpp_api/gallery/gallery.md) file to contain the enrolled templates. By default the gallery will be held in memory and *input* can used as a gallery in [br_compare](#br_compare) + Parameter | Type | Description + --- | --- | --- + input | const char * | The [format](../cpp_api/format/format.md) or [gallery](../cpp_api/gallery/gallery.md) to enroll. + gallery | const char * | (Optional) The [Gallery](../cpp_api/gallery/gallery.md) file to contain the enrolled templates. By default the gallery will be held in memory and *input* can used as a gallery in [br_compare](#br_compare) * **output:** (void) * **see:** [br_enroll_n](#br_enroll_n) @@ -204,15 +204,15 @@ Convenience function for enrolling multiple inputs. * **function definition:** - void br_enroll_n(int num_inputs, const char *inputs[], const char *gallery = "") + void br_enroll_n(int num_inputs, const char *inputs[], const char *gallery = "") * **parameters:** - Parameter | Type | Description - --- | --- | --- - num_inputs | int | Size of **inputs**. - inputs[] | const char * | Array of inputs to enroll. - gallery | const char * | (Optional) The [Gallery](../cpp_api/gallery/gallery.md) file to contain the enroll templates. + Parameter | Type | Description + --- | --- | --- + num_inputs | int | Size of **inputs**. + inputs[] | const char * | Array of inputs to enroll. + gallery | const char * | (Optional) The [Gallery](../cpp_api/gallery/gallery.md) file to contain the enroll templates. * **output:** (void) * **see:** [br_enroll](#br_enroll) @@ -225,14 +225,14 @@ A naive alternative to [br_enroll](#br_enroll). * **function definition:** - void br_project(const char *input, const char *output) + void br_project(const char *input, const char *output) * **parameters:** - Parameter | Type | Description - --- | --- | --- - input | const char * | The [format](../cpp_api/format/format.md) or [gallery](../cpp_api/gallery/gallery.md) to enroll. - output | const char * | The [Gallery](../cpp_api/gallery/gallery.md) file to contain the enrolled templates. By default the gallery will be held in memory and *input* can used as a gallery in [br_compare](#br_compare) + Parameter | Type | Description + --- | --- | --- + input | const char * | The [format](../cpp_api/format/format.md) or [gallery](../cpp_api/gallery/gallery.md) to enroll. + output | const char * | The [Gallery](../cpp_api/gallery/gallery.md) file to contain the enrolled templates. By default the gallery will be held in memory and *input* can used as a gallery in [br_compare](#br_compare) * **output:** (void) * **see:** [br_enroll](#br_enroll) @@ -245,16 +245,16 @@ Creates a **.csv** file containing performance metrics from evaluating the simil * **function defintion:** - float br_eval(const char *simmat, const char *mask, const char *csv = "", int matches = 0) + float br_eval(const char *simmat, const char *mask, const char *csv = "", int matches = 0) * **parameters:** - Parameter | Type | Description - --- | --- | --- - simmat | const char * | The [simmat](../../tutorials.md#the-evaluation-harness) to use - mask | const char * | The [mask](../../tutorials.md#the-evaluation-harness) to use. - csv | const char * | (Optional) The **.csv** file to contain performance metrics. - matches | int | (Optional) An integer number of matches to output around the EER. Default is 0. + Parameter | Type | Description + --- | --- | --- + simmat | const char * | The [simmat](../../tutorials.md#the-evaluation-harness) to use + mask | const char * | The [mask](../../tutorials.md#the-evaluation-harness) to use. + csv | const char * | (Optional) The **.csv** file to contain performance metrics. + matches | int | (Optional) An integer number of matches to output around the EER. Default is 0. * **output:** (float) Returns the true accept rate (TAR) at a false accept rate (FAR) of one in one thousand * **see:** [br_plot](#br_plot) @@ -267,15 +267,15 @@ Evaluates the similarity matrix using the mask matrix. Function aborts if TAR @ * **function definition:** - void br_assert_eval(const char *simmat, const char *mask, const float accuracy) + void br_assert_eval(const char *simmat, const char *mask, const float accuracy) * **parameters:** - Parameter | Type | Description - --- | --- | --- - simmat | const char * | The [simmat](../../tutorials.md#the-evaluation-harness) to use - mask | const char * | The [mask](../../tutorials.md#the-evaluation-harness) - accuracy | const float | Desired true accept rate at false accept rate of one in one thousand. + Parameter | Type | Description + --- | --- | --- + simmat | const char * | The [simmat](../../tutorials.md#the-evaluation-harness) to use + mask | const char * | The [mask](../../tutorials.md#the-evaluation-harness) + accuracy | const float | Desired true accept rate at false accept rate of one in one thousand. * **output:** (void) @@ -287,16 +287,16 @@ Creates a **.csv** file containing performance metrics from evaluating the simil * **function definition:** - float br_inplace_eval(const char * simmat, const char *target, const char *query, const char *csv = "") + float br_inplace_eval(const char * simmat, const char *target, const char *query, const char *csv = "") * **parameters:** - Parameter | Type | Description - --- | --- | --- - simmat | const char * | The [simmat](../../tutorials.md#the-evaluation-harness) - target | const char * | The name of a gallery containing metadata for the target set. - query | const char * | The name of a gallery containing metadata for the query set. - csv | const char * | (Optional) The **.csv** file to contain performance metrics. + Parameter | Type | Description + --- | --- | --- + simmat | const char * | The [simmat](../../tutorials.md#the-evaluation-harness) + target | const char * | The name of a gallery containing metadata for the target set. + query | const char * | The name of a gallery containing metadata for the query set. + csv | const char * | (Optional) The **.csv** file to contain performance metrics. * **output:** (float) Returns the true accept rate (TAR) at a false accept rate (FAR) of one in one thousand * **see:** [br_plot](#br_plot) @@ -309,16 +309,16 @@ Evaluates and prints classification accuracy to terminal. * **function definition:** - void br_eval_classification(const char *predicted_gallery, const char *truth_gallery, const char *predicted_property = "", const char *truth_property = "") + void br_eval_classification(const char *predicted_gallery, const char *truth_gallery, const char *predicted_property = "", const char *truth_property = "") * **parameters:** - Parameter | Type | Description - --- | --- | --- - predicted_gallery | const char * | The predicted [Gallery](../cpp_api/gallery/gallery.md). - truth_gallery | const char * | The ground truth [Gallery](../cpp_api/gallery/gallery.md). - predicted_property | const char * | (Optional) Which metadata key to use from the **predicted_gallery**. - truth_property | const char * | (Optional) Which metadata key to use from the **truth_gallery**. + Parameter | Type | Description + --- | --- | --- + predicted_gallery | const char * | The predicted [Gallery](../cpp_api/gallery/gallery.md). + truth_gallery | const char * | The ground truth [Gallery](../cpp_api/gallery/gallery.md). + predicted_property | const char * | (Optional) Which metadata key to use from the **predicted_gallery**. + truth_property | const char * | (Optional) Which metadata key to use from the **truth_gallery**. * **output:** (void) @@ -330,7 +330,7 @@ Evaluates and prints clustering accuracy to the terminal. * **function definition:** - void br_eval_clustering(const char *csv, const char *gallery, const char * truth_property) + void br_eval_clustering(const char *csv, const char *gallery, const char * truth_property) * **parameters:** @@ -350,18 +350,18 @@ Evaluates and prints detection accuracy to terminal. * **function definition:** - float br_eval_detection(const char *predicted_gallery, const char *truth_gallery, const char *csv = "", bool normalize = false, int minSize = 0, int maxSize = 0) + float br_eval_detection(const char *predicted_gallery, const char *truth_gallery, const char *csv = "", bool normalize = false, int minSize = 0, int maxSize = 0) * **parameters:** - Parameter | Type | Description - --- | --- | --- - predicted_gallery | const char * | The predicted [Gallery](../cpp_api/gallery/gallery.md). - truth_gallery | const char * | The ground truth [Gallery](../cpp_api/gallery/gallery.md). - csv | const char * | (Optional) The **.csv** file to contain performance metrics. - normalize | bool | (Optional) Flag to normalize predicted bounding boxes for improved detection. Defaults to false. - minSize | int | (Optional) Minimum size of faces to be considered in the evaluation. Size is applied to predicted and ground truth galleries. Defaults to -1 (no minimum size). - maxSize | int | (Optional) Maximum size if faces to be considered in the evaluation. Size is applied to predicted and ground truth galleries. Defaults to -1 (no maximum size). + Parameter | Type | Description + --- | --- | --- + predicted_gallery | const char * | The predicted [Gallery](../cpp_api/gallery/gallery.md). + truth_gallery | const char * | The ground truth [Gallery](../cpp_api/gallery/gallery.md). + csv | const char * | (Optional) The **.csv** file to contain performance metrics. + normalize | bool | (Optional) Flag to normalize predicted bounding boxes for improved detection. Defaults to false. + minSize | int | (Optional) Minimum size of faces to be considered in the evaluation. Size is applied to predicted and ground truth galleries. Defaults to -1 (no minimum size). + maxSize | int | (Optional) Maximum size if faces to be considered in the evaluation. Size is applied to predicted and ground truth galleries. Defaults to -1 (no maximum size). * **output:** (float) Returns the true accept rate (TAR) at a false accept rate (FAR) of one in one thousand @@ -373,19 +373,19 @@ Evaluates and prints landmarking accuracy to terminal. * **function definition:** - float br_eval_landmarking(const char *predicted_gallery, const char *truth_gallery, const char *csv = "", int normalization_index_a = 0, int normalization_index_b = 1, int sample_index = 0, int total_examples = 5) + float br_eval_landmarking(const char *predicted_gallery, const char *truth_gallery, const char *csv = "", int normalization_index_a = 0, int normalization_index_b = 1, int sample_index = 0, int total_examples = 5) * **parameters:** - Parameter | Type | Description - --- | --- | --- - predicted_gallery | const char * | The predicted [Gallery](../cpp_api/gallery/gallery.md). - truth_gallery | const char * | The ground truth [Gallery](../cpp_api/gallery/gallery.md). - csv | const char * | (Optional) The **.csv** file to contain performance metrics. - normalization_index_a | int | (Optional) The first index in the list of points to use for normalization. Default is 0. - normalization_index_b | int | (Optional) The second index in the list of points to use for normalization. Default is 1. - sample_index | int | (Optional) The index for sample landmark image in ground truth gallery. Default = 0. - total_examples | int | (Optional) The number of accurate and inaccurate examples to display. Default is 5. + Parameter | Type | Description + --- | --- | --- + predicted_gallery | const char * | The predicted [Gallery](../cpp_api/gallery/gallery.md). + truth_gallery | const char * | The ground truth [Gallery](../cpp_api/gallery/gallery.md). + csv | const char * | (Optional) The **.csv** file to contain performance metrics. + normalization_index_a | int | (Optional) The first index in the list of points to use for normalization. Default is 0. + normalization_index_b | int | (Optional) The second index in the list of points to use for normalization. Default is 1. + sample_index | int | (Optional) The index for sample landmark image in ground truth gallery. Default = 0. + total_examples | int | (Optional) The number of accurate and inaccurate examples to display. Default is 5. * **output:** (float) Returns the true accept rate (TAR) at a false accept rate (FAR) of one in one thousand @@ -397,16 +397,16 @@ Evaluates regression accuracy to disk. * **function definition:** - void br_eval_regression(const char *predicted_gallery, const char *truth_gallery, const char *predicted_property = "", const char *truth_property = "") + void br_eval_regression(const char *predicted_gallery, const char *truth_gallery, const char *predicted_property = "", const char *truth_property = "") * **parameters:** - Parameter | Type | Description - --- | --- | --- - predicted_gallery | const char * | The predicted [Gallery](../cpp_api/gallery/gallery.md) - truth_gallery | const char * | The ground truth [Gallery](../cpp_api/gallery/gallery.md) - predicted_property | const char * | (Optional) Which metadata key to use from **predicted_gallery**. - truth_property | const char * | (Optional) Which metadata key to use from **truth_gallery**. + Parameter | Type | Description + --- | --- | --- + predicted_gallery | const char * | The predicted [Gallery](../cpp_api/gallery/gallery.md) + truth_gallery | const char * | The ground truth [Gallery](../cpp_api/gallery/gallery.md) + predicted_property | const char * | (Optional) Which metadata key to use from **predicted_gallery**. + truth_property | const char * | (Optional) Which metadata key to use from **truth_gallery**. * **output:** (void) @@ -418,17 +418,17 @@ Perform score level fusion on similarity matrices. * **function definition:** - void br_fuse(int num_input_simmats, const char *input_simmats[], const char *normalization, const char *fusion, const char *output_simmat) + void br_fuse(int num_input_simmats, const char *input_simmats[], const char *normalization, const char *fusion, const char *output_simmat) * **parameters:** - Parameter | Type | Description - --- | --- | --- - num_input_simmats | int | Size of **input_simmats**. - input_simmats[] | const char * | Array of [simmats](../../tutorials.md#the-evaluation-harness). All simmats must have the same dimensions. - normalization | const char * | Valid options are: - fusion | const char * | Valid options are: - output_simmat | const char * | [Simmat](../../tutorials.md#the-evaluation-harness) to contain the fused scores. + Parameter | Type | Description + --- | --- | --- + num_input_simmats | int | Size of **input_simmats**. + input_simmats[] | const char * | Array of [simmats](../../tutorials.md#the-evaluation-harness). All simmats must have the same dimensions. + normalization | const char * | Valid options are: + fusion | const char * | Valid options are: + output_simmat | const char * | [Simmat](../../tutorials.md#the-evaluation-harness) to contain the fused scores. * **output:** (void) @@ -440,16 +440,16 @@ Initializes the [Context](../cpp_api/context/context.md). Required at the beginn * **function definition:** - void br_initialize(int &argc, char *argv[], const char *sdk_path = "", bool use_gui = false) + void br_initialize(int &argc, char *argv[], const char *sdk_path = "", bool use_gui = false) * **parameters:** - Parameter | Type | Description - --- | --- | --- - argc | int | Number of command line arguments. - argv[] | char * | Array of command line arguments. - sdk_path | const char * | (Optional) Path to the OpenBR sdk. If no path is provided OpenBR will try and find the sdk automatically. - use_gui | bool | (Optional) Enable OpenBR to use make GUI windows. Default is false. + Parameter | Type | Description + --- | --- | --- + argc | int | Number of command line arguments. + argv[] | char * | Array of command line arguments. + sdk_path | const char * | (Optional) Path to the OpenBR sdk. If no path is provided OpenBR will try and find the sdk automatically. + use_gui | bool | (Optional) Enable OpenBR to use make GUI windows. Default is false. * **output:** (void) * **see:** [br_finalize](#br_finalize) @@ -462,7 +462,7 @@ Initializes the [Context](../cpp_api/context/context.md) with default arguments. * **function definition:** - void br_initialize_default() + void br_initialize_default() * **parameters:** None * **output:** (void) @@ -476,7 +476,7 @@ Finalizes the context. Required at the end of any OpenBR program. * **function definition:** - void br_finalize() + void br_finalize() * **parameters:** None * **output:** (void) @@ -490,13 +490,13 @@ Checks if the provided algorithm is a classifier. Wrapper of [IsClassifier](../c * **function definition:** - bool br_is_classifier(const char *algorithm) + bool br_is_classifier(const char *algorithm) * **parameters:** - Parameter | Type | Description - --- | --- | --- - algorithm | const char * | Algorithm to check. + Parameter | Type | Description + --- | --- | --- + algorithm | const char * | Algorithm to check. * **output:** (bool) Returns true if the algorithm is a classifier (does not have an associated distance) * **see:** [IsClassifier](../cpp_api/apifunctions.md#isclassifier) @@ -509,15 +509,15 @@ Constructs a [mask](../../tutorials.md#the-evaluation-harness) from target and q * **function definition:** - void br_make_mask(const char *target_input, const char *query_input, const char *mask) + void br_make_mask(const char *target_input, const char *query_input, const char *mask) * **parameters:** - Parameter | Type | Description - --- | --- | --- - target_input | const char * | The target [Gallery](../cpp_api/gallery/gallery.md) - query_input | const char * | The query [Gallery](../cpp_api/gallery/gallery.md) - mask | const char * | The file to contain the resulting [mask](../../tutorials.md#the-evaluation-harness). + Parameter | Type | Description + --- | --- | --- + target_input | const char * | The target [Gallery](../cpp_api/gallery/gallery.md) + query_input | const char * | The query [Gallery](../cpp_api/gallery/gallery.md) + mask | const char * | The file to contain the resulting [mask](../../tutorials.md#the-evaluation-harness). * **output:** (void) * **see:** [br_combine_masks](#br_combine_masks) @@ -530,7 +530,7 @@ Constructs a [mask](../../tutorials.md#the-evaluation-harness) from target and q * **function definition:** - void br_make_pairwise_mask(const char *target_input, const char *query_input, const char *mask) + void br_make_pairwise_mask(const char *target_input, const char *query_input, const char *mask) * **parameters:** @@ -551,14 +551,14 @@ Returns the most recent line sent to stderr. For information on input string buf * **function definition:** - int br_most_recent_message(char * buffer, int buffer_length) + int br_most_recent_message(char * buffer, int buffer_length) * **parameters:** - Parameter | Type | Description - --- | --- | --- - buffer | char * | Buffer to store the last line in. - buffer_length | int | Length of the buffer. + Parameter | Type | Description + --- | --- | --- + buffer | char * | Buffer to store the last line in. + buffer_length | int | Length of the buffer. * **output:** (int) Returns the required size of the input buffer for the most recent message to fit completely * **see:** [br_progress](#br_progress), [br_time_remaining](#br_time_remaining) @@ -571,17 +571,17 @@ Returns names and parameters for the requested objects. Each object is newline s * **function definition:** - int br_objects(char * buffer, int buffer_length, const char *abstractions = ".*", const char *implementations = ".*", bool parameters = true) + int br_objects(char * buffer, int buffer_length, const char *abstractions = ".*", const char *implementations = ".*", bool parameters = true) * **parameters:** - Parameter | Type | Description - --- | --- | --- - buffer | char * | Output buffer for results. - buffer_length | int | Length of output buffer. - abstractions | const char * | (Optional) Regular expression of the abstractions to search. Default is ".\*". - implementations | const char * | (Optional) Regular expression of the implementations to search. Default is ".\*". - parameters | bool | (Optional) Include parameters after object name. Default is true. + Parameter | Type | Description + --- | --- | --- + buffer | char * | Output buffer for results. + buffer_length | int | Length of output buffer. + abstractions | const char * | (Optional) Regular expression of the abstractions to search. Default is ".\*". + implementations | const char * | (Optional) Regular expression of the implementations to search. Default is ".\*". + parameters | bool | (Optional) Include parameters after object name. Default is true. * **output:** (int) Returns the required size of the input buffer for the returned objects to fit completely @@ -613,20 +613,20 @@ Matches around the EER will be displayed if the matches parameter is set in [br_ This function requires a current [R][R] installation with the following packages: - install.packages(c("ggplot2", "gplots", "reshape", "scales", "jpg", "png")) + install.packages(c("ggplot2", "gplots", "reshape", "scales", "jpg", "png")) * **function definiton:** - bool br_plot(int num_files, const char *files[], const char *destination, bool show = false) + bool br_plot(int num_files, const char *files[], const char *destination, bool show = false) * **parameters:** - Parameter | Type | Description - --- | --- | --- - num_files | int | Number of **.csv** files. - files[] | const char * | **.csv** files created using [br_eval](#br_eval). - destination | const char * | Basename for the resulting figures. - show | bool | Open **destination.pdf** using the system's default PDF viewer. Default is false. + Parameter | Type | Description + --- | --- | --- + num_files | int | Number of **.csv** files. + files[] | const char * | **.csv** files created using [br_eval](#br_eval). + destination | const char * | Basename for the resulting figures. + show | bool | Open **destination.pdf** using the system's default PDF viewer. Default is false. * **output:** (bool) Returns true on success. Returns false on a failure to compile the figures due to a missing, out of date, or incomplete R installation. * **see:** [br_eval](#br_eval) @@ -656,16 +656,16 @@ This function requires a current [R](http://www.r-project.org/) installation wit * **function definition:** - bool br_plot_detection(int num_files, const char *files[], const char *destination, bool show = false) + bool br_plot_detection(int num_files, const char *files[], const char *destination, bool show = false) * **parameters:** - Parameter | Type | Description - --- | --- | --- - num_files | int | Number of **.csv** files. - files[] | const char * | **.csv** files created using [br_eval_detection](#br_eval_detection). - destination | const char * | Basename for the resulting figures. - show | bool | Open **destination.pdf** using the system's default PDF viewer. Default is false. + Parameter | Type | Description + --- | --- | --- + num_files | int | Number of **.csv** files. + files[] | const char * | **.csv** files created using [br_eval_detection](#br_eval_detection). + destination | const char * | Basename for the resulting figures. + show | bool | Open **destination.pdf** using the system's default PDF viewer. Default is false. * **output:** (bool) Returns true on success. Returns false on a failure to compile the figures due to a missing, out of date, or incomplete R installation. * **see:** [br_eval_detection](#br_eval_detection), [br_plot](#br_plot) @@ -685,16 +685,16 @@ Landmarking error is normalized against the distance between two predifined poin * **function definition:** - bool br_plot_landmarking(int num_files, const char *files[], const char *destination, bool show = false) + bool br_plot_landmarking(int num_files, const char *files[], const char *destination, bool show = false) * **parameters:** - Parameter | Type | Description - --- | --- | --- - num_files | int | Number of **.csv** files. - files[] | const char * | **.csv** files created using [br_eval_landmarking](#br_eval_landmarking). - destination | const char * | Basename for the resulting figures. - show | bool | Open **destination.pdf** using the system's default PDF viewer. Default is false. + Parameter | Type | Description + --- | --- | --- + num_files | int | Number of **.csv** files. + files[] | const char * | **.csv** files created using [br_eval_landmarking](#br_eval_landmarking). + destination | const char * | Basename for the resulting figures. + show | bool | Open **destination.pdf** using the system's default PDF viewer. Default is false. * **output:** (bool) Returns true on success. Returns false on a failure to compile the figures due to a missing, out of date, or incomplete R installation. * **see:** [br_eval_landmarking](#br_eval_landmarking), [br_plot](#br_plot) @@ -707,16 +707,16 @@ Renders metadata figures for a set of **.csv** files with specified columns. * **function definition:** - bool br_plot_metadata(int num_files, const char *files[], const char *columns, bool show = false) + bool br_plot_metadata(int num_files, const char *files[], const char *columns, bool show = false) * **parameters:** - Parameter | Type | Description - --- | --- | --- - num_files | int | Number of **.csv** files. - files[] | const char * | **.csv** files created by enrolling templates to **.csv** metadata files. - columns | const char * | ';' seperated list of columns to plot. - show | bool | Open **PlotMetadata.pdf** using the system's default PDF viewer. + Parameter | Type | Description + --- | --- | --- + num_files | int | Number of **.csv** files. + files[] | const char * | **.csv** files created by enrolling templates to **.csv** metadata files. + columns | const char * | ';' seperated list of columns to plot. + show | bool | Open **PlotMetadata.pdf** using the system's default PDF viewer. * **output:** (bool) Returns true on success. Returns false on a failure to compile the figures due to a missing, out of date, or incomplete R installation. * **see:** [br_plot](#br_plot) @@ -729,7 +729,7 @@ Returns current progress from [Context](../cpp_api/context/context.md)::[progres * **function definition:** - float br_progress() + float br_progress() * **parameters:** None @@ -744,15 +744,15 @@ Read and parse arguments from a named pipe. Used by the [command line api](../cl * **function defintion:** - void br_read_pipe(const char *pipe, int *argc, char ***argv) + void br_read_pipe(const char *pipe, int *argc, char ***argv) * **parameters:** - Parameter | Type | Description - --- | --- | --- - pipe | const char * | Pipe name - argc | int * | Argument count - argv | char *** | Argument list + Parameter | Type | Description + --- | --- | --- + pipe | const char * | Pipe name + argc | int * | Argument count + argv | char *** | Argument list * **output:** (void) @@ -764,14 +764,14 @@ Fills the buffer with the value of [Context](../cpp_api/context/context.md)::[sc * **function defintion:** - int br_scratch_path(char * buffer, int buffer_length) + int br_scratch_path(char * buffer, int buffer_length) * **parameters:** - Parameter | Type | Description - --- | --- | --- - buffer | char * | Buffer for scratch path - buffer_length | int | Length of buffer. + Parameter | Type | Description + --- | --- | --- + buffer | char * | Buffer for scratch path + buffer_length | int | Length of buffer. * **output:** (int) Returns the required size of the input buffer for the most recent message to fit completely * **see:** [br_version](#br_version) @@ -784,7 +784,7 @@ Returns the full path to the root of the SDK. * **function definition:** - const char *br_sdk_path() + const char *br_sdk_path() * **parameters:** None * **output:** (const char *) Returns the full path to the root of the SDK @@ -798,15 +798,15 @@ Retrieve the target and query inputs in the [BEE matrix](../../tutorials.md#the- * **function definition:** - void br_get_header(const char *matrix, const char **target_gallery, const char **query_gallery) + void br_get_header(const char *matrix, const char **target_gallery, const char **query_gallery) * **parameters:** - Parameter | Type | Description - --- | --- | --- - matrix | const char * | The [BEE matrix](../../tutorials.md#the-evaluation-harness) file to modify - target_gallery | const char ** | The matrix target - query_gallery | const char ** | The matrix query + Parameter | Type | Description + --- | --- | --- + matrix | const char * | The [BEE matrix](../../tutorials.md#the-evaluation-harness) file to modify + target_gallery | const char ** | The matrix target + query_gallery | const char ** | The matrix query * **output:** (void) * **set:** [br_set_header](#br_set_header) @@ -819,15 +819,15 @@ Update the target and query inputs in the [BEE matrix](../../tutorials.md#the-ev * **function definition:** - void br_set_header(const char *matrix, const char *target_gallery, const char *query_gallery) + void br_set_header(const char *matrix, const char *target_gallery, const char *query_gallery) * **parameters:** - Parameter | Type | Description - --- | --- | --- - matrix | const char * | The [BEE matrix](../../tutorials.md#the-evaluation-harness) file to modify - target_gallery | const char ** | The matrix target - query_gallery | const char ** | The matrix query + Parameter | Type | Description + --- | --- | --- + matrix | const char * | The [BEE matrix](../../tutorials.md#the-evaluation-harness) file to modify + target_gallery | const char ** | The matrix target + query_gallery | const char ** | The matrix query * **output:** (void) * **see:** [br_get_header](#br_get_header) @@ -840,14 +840,14 @@ Appends a provided value to the [global metadata](../cpp_api/context/context.md) * **function definition:** - void br_set_property(const char *key, const char *value) + void br_set_property(const char *key, const char *value) * **parameters:** - Parameter | Type | Description - --- | --- | --- - key | const char * | Key to append - value | const char * | Value to append + Parameter | Type | Description + --- | --- | --- + key | const char * | Key to append + value | const char * | Value to append * **output:** (void) @@ -859,7 +859,7 @@ Returns estimate of time remaining in the current process. * **function definition:** - int br_time_remaining() + int br_time_remaining() * **parameters:** None * **output:** (int) Returns an estimate of the time remaining @@ -873,14 +873,14 @@ Trains a provided model's [Transform](../cpp_api/transform/transform.md) and [Di * **function definiton:** - void br_train(const char *input, const char *model = "") + void br_train(const char *input, const char *model = "") * **parameters:** - Parameter | Type | Description - --- | --- | --- - input | const char * | The [Gallery](../cpp_api/gallery/gallery.md) to train on. - model | const char * | (Optional) String specifying the binary file to serialize training results to. The trained algorithm can be recovered by using this file as the algorithm. By default the trained algorithm will not be serialized to disk. + Parameter | Type | Description + --- | --- | --- + input | const char * | The [Gallery](../cpp_api/gallery/gallery.md) to train on. + model | const char * | (Optional) String specifying the binary file to serialize training results to. The trained algorithm can be recovered by using this file as the algorithm. By default the trained algorithm will not be serialized to disk. * **output:** (void) * **see:** [br_train_n](#br_train_n) @@ -893,15 +893,15 @@ Convenience function for training on multiple inputs * **function definition:** - void br_train_n(int num_inputs, const char *inputs[], const char *model = "") + void br_train_n(int num_inputs, const char *inputs[], const char *model = "") * **parameters:** - Parameter | Type | Description - --- | --- | --- - num_inputs | int | Size of **inputs** - inputs[] | const char * | An array of [galleries](../cpp_api/gallery/gallery.md) to train on. - model | const char * | (Optional) String specifying the binary file to serialize training results to. The trained algorithm can be recovered by using this file as the algorithm. By default the trained algorithm will not be serialized to disk. + Parameter | Type | Description + --- | --- | --- + num_inputs | int | Size of **inputs** + inputs[] | const char * | An array of [galleries](../cpp_api/gallery/gallery.md) to train on. + model | const char * | (Optional) String specifying the binary file to serialize training results to. The trained algorithm can be recovered by using this file as the algorithm. By default the trained algorithm will not be serialized to disk. * **output:** (void) * **see:** [br_train](#br_train) @@ -914,7 +914,7 @@ Get the current OpenBR version. * **function definition:** - const char *br_version() + const char *br_version() * **parameters:** None * **output:** (const char *) Returns the current OpenBR version @@ -928,13 +928,13 @@ For internal use via [ProcessWrapperTransform](../plugins/core.md#processwrapper * **function definition:** - void br_slave_process(const char * baseKey) + void br_slave_process(const char * baseKey) * **parameters:** - Parameter | Type | Description - --- | --- | --- - baseKey | const char * | base key for the slave process + Parameter | Type | Description + --- | --- | --- + baseKey | const char * | base key for the slave process * **output:** (void) @@ -946,14 +946,14 @@ Load an image from a string buffer. This is an easy way to pass an image in memo * **function definition:** - br_template br_load_img(const char *data, int len) + br_template br_load_img(const char *data, int len) * **parameters:** - Parameter | Type | Description - --- | --- | --- - data | const char * | The image buffer. - len | int | The length of the buffer. + Parameter | Type | Description + --- | --- | --- + data | const char * | The image buffer. + len | int | The length of the buffer. * **output:** ([br_template](typedefs.md#br_template) Returns a [br_template](typedefs.md#br_template) loaded with the provided image * **see:** [br_unload_img](#br_unload_img) @@ -966,13 +966,13 @@ Unload an image to a string buffer. This is an easy way to pass an image from op * **function definition:** - unsigned char* br_unload_img(br_template tmpl) + unsigned char* br_unload_img(br_template tmpl) * **parameters:** - Parameter | Type | Description - --- | --- | --- - tmpl | [br_template](typedefs.md#br_template) | Pointer to a [Template](../cpp_api/template/template.md) + Parameter | Type | Description + --- | --- | --- + tmpl | [br_template](typedefs.md#br_template) | Pointer to a [Template](../cpp_api/template/template.md) * **output:** (unsigned char*) Returns a buffer loaded with the image data from tmpl * **see:** [br_load_img](#br_load_img) @@ -985,7 +985,7 @@ Deserialize a [TemplateList](../cpp_api/templatelist/templatelist.md) from a buf * **function definition:** - br_template_list br_template_list_from_buffer(const char *buf, int len) + br_template_list br_template_list_from_buffer(const char *buf, int len) * **return type:** br_template_list * **parameters:** @@ -1005,13 +1005,13 @@ Free a [Template's](../cpp_api/template/template.md) memory. * **function definition:** - void br_free_template(br_template tmpl) + void br_free_template(br_template tmpl) * **parameters:** - Parameter | Type | Description - --- | --- | --- - tmpl | br_template | Pointer to the [Template](../cpp_api/template/template.md) to free. + Parameter | Type | Description + --- | --- | --- + tmpl | br_template | Pointer to the [Template](../cpp_api/template/template.md) to free. * **output:** (void) @@ -1023,13 +1023,13 @@ Free a [TemplateList's](../cpp_api/templatelist/templatelist.md) memory. * **function definition:** - void br_free_template_list(br_template_list tl) + void br_free_template_list(br_template_list tl) * **parameters:** - Parameter | Type | Description - --- | --- | --- - tl | [br_template_list](typedefs.md#br_template_list) | Pointer to the [TemplateList](../cpp_api/templatelist/templatelist.md) to free. + Parameter | Type | Description + --- | --- | --- + tl | [br_template_list](typedefs.md#br_template_list) | Pointer to the [TemplateList](../cpp_api/templatelist/templatelist.md) to free. * **output:** (void) @@ -1041,13 +1041,13 @@ Free a [Output's](../cpp_api/output/output.md) memory. * **function definition:** - void br_free_output(br_matrix_output output) + void br_free_output(br_matrix_output output) * **parameters:** - Parameter | Type | Description - --- | --- | --- - output | [br_matrix_output](typedefs.md#br_matrix_output) | Pointer to the[Output](../cpp_api/output/output.md) to free. + Parameter | Type | Description + --- | --- | --- + output | [br_matrix_output](typedefs.md#br_matrix_output) | Pointer to the[Output](../cpp_api/output/output.md) to free. * **output:** (void) @@ -1059,13 +1059,13 @@ Returns the number of rows in an image. * **function definition:** - int br_img_rows(br_template tmpl) + int br_img_rows(br_template tmpl) * **parameters:** - Parameter | Type | Description - --- | --- | --- - tmpl | [br_template](typedefs.md#br_template) | Pointer to a [Template](../cpp_api/template/template.md). + Parameter | Type | Description + --- | --- | --- + tmpl | [br_template](typedefs.md#br_template) | Pointer to a [Template](../cpp_api/template/template.md). * **output:** (int) Returns the number of rows in an image @@ -1077,13 +1077,13 @@ Returns the number of cols in an image. * **function definition:** - int br_img_cols(br_template tmpl) + int br_img_cols(br_template tmpl) * **parameters:** - Parameter | Type | Description - --- | --- | --- - tmpl | [br_template](typedefs.md#br_template) | Pointer to a [Template](../cpp_api/template/template.md). + Parameter | Type | Description + --- | --- | --- + tmpl | [br_template](typedefs.md#br_template) | Pointer to a [Template](../cpp_api/template/template.md). * **output:** (int) Returns the number of columns in an image @@ -1095,13 +1095,13 @@ Returns the number of channels in an image. * **function definition:** - int br_img_channels(br_template tmpl) + int br_img_channels(br_template tmpl) * **parameters:** - Parameter | Type | Description - --- | --- | --- - tmpl | [br_template](typedefs.md#br_template) | Pointer to a [Template](../cpp_api/template/template.md). + Parameter | Type | Description + --- | --- | --- + tmpl | [br_template](typedefs.md#br_template) | Pointer to a [Template](../cpp_api/template/template.md). * **output:** (int) Returns the number of channels in an image @@ -1113,13 +1113,13 @@ Checks if the image is empty. * **function definition:** - bool br_img_is_empty(br_template tmpl) + bool br_img_is_empty(br_template tmpl) * **parameters:** - Parameter | Type | Description - --- | --- | --- - tmpl | [br_template](typedefs.md#br_template) | Pointer to a [Template](../cpp_api/template/template.md). + Parameter | Type | Description + --- | --- | --- + tmpl | [br_template](typedefs.md#br_template) | Pointer to a [Template](../cpp_api/template/template.md). * **output:** (bool) Returns true if the image is empty, false otherwise. @@ -1131,15 +1131,15 @@ Get the name of the [file](../cpp_api/template/members.md#file) of a provided [T * **function definition:** - int br_get_filename(char * buffer, int buffer_length, br_template tmpl) + int br_get_filename(char * buffer, int buffer_length, br_template tmpl) * **parameters:** - Parameter | Type | Description - --- | --- | --- - buffer | char * | Buffer to hold the filename - buffer_length | int | Length of the buffer - tmpl | [br_template](typedefs.md#br_template) | Pointer to a [Template](../cpp_api/template/template.md). + Parameter | Type | Description + --- | --- | --- + buffer | char * | Buffer to hold the filename + buffer_length | int | Length of the buffer + tmpl | [br_template](typedefs.md#br_template) | Pointer to a [Template](../cpp_api/template/template.md). * **output:** (int) Returns the size of the buffer required to hold the entire file name. @@ -1151,14 +1151,14 @@ Set the name of the [file](../cpp_api/template/members.md#file) for a provided [ * **function definition:** - void br_set_filename(br_template tmpl, const char *filename) + void br_set_filename(br_template tmpl, const char *filename) * **parameters:** - Parameter | Type | Description - --- | --- | --- - tmpl | [br_template](typedefs.md#br_template) | Pointer to a [Template](../cpp_api/template/template.md). - filename | const char * | New filename for the template. + Parameter | Type | Description + --- | --- | --- + tmpl | [br_template](typedefs.md#br_template) | Pointer to a [Template](../cpp_api/template/template.md). + filename | const char * | New filename for the template. * **output:** (void) @@ -1170,16 +1170,16 @@ Get the [metadata](../cpp_api/file/members.md#m_metadata) value as a string for * **function definition:** - int br_get_metadata_string(char * buffer, int buffer_length, br_template tmpl, const char *key) + int br_get_metadata_string(char * buffer, int buffer_length, br_template tmpl, const char *key) * **parameters:** - Parameter | Type | Description - --- | --- | --- - buffer | char * | Buffer to hold the metadata string. - buffer_length | int | length of the buffer. - tmpl | [br_template](typedefs.md#br_template) | Pointer to a [Template](../cpp_api/template/template.md). - key | const char * | Key for the metadata lookup + Parameter | Type | Description + --- | --- | --- + buffer | char * | Buffer to hold the metadata string. + buffer_length | int | length of the buffer. + tmpl | [br_template](typedefs.md#br_template) | Pointer to a [Template](../cpp_api/template/template.md). + key | const char * | Key for the metadata lookup * **output:** (int) Returns the size of the buffer required to hold the entire metadata string @@ -1191,13 +1191,13 @@ Enroll a [Template](../cpp_api/template/template.md) from the C API! * **function definition:** - br_template_list br_enroll_template(br_template tmpl) + br_template_list br_enroll_template(br_template tmpl) * **parameters:** - Parameter | Type | Description - --- | --- | --- - tmpl | br_template | Pointer to a [Template](../cpp_api/template/template.md). + Parameter | Type | Description + --- | --- | --- + tmpl | br_template | Pointer to a [Template](../cpp_api/template/template.md). * **output:** ([br_template_list](typedefs.md#br_template_list)) Returns a pointer to a [TemplateList](../cpp_api/templatelist/templatelist.md) @@ -1209,13 +1209,13 @@ Enroll a [TemplateList](../cpp_api/templatelist/templatelist.md) from the C API! * **function definition:** - void br_enroll_template_list(br_template_list tl) + void br_enroll_template_list(br_template_list tl) * **parameters:** - Parameter | Type | Description - --- | --- | --- - tl | [br_template_list](typedefs.md#br_template_list) | Pointer to a [TemplateList](../cpp_api/templatelist/templatelist.md) + Parameter | Type | Description + --- | --- | --- + tl | [br_template_list](typedefs.md#br_template_list) | Pointer to a [TemplateList](../cpp_api/templatelist/templatelist.md) * **output:** (void) @@ -1227,14 +1227,14 @@ Compare [TemplateLists](../cpp_api/templatelist/templatelist.md) from the C API! * **function definition:** - br_matrix_output br_compare_template_lists(br_template_list target, br_template_list query) + br_matrix_output br_compare_template_lists(br_template_list target, br_template_list query) * **parameters:** - Parameter | Type | Description - --- | --- | --- - target | br_template_list | Pointer to a [TemplateList](../cpp_api/templatelist/templatelist.md) - query | br_template_list | Pointer to a [TemplateList](../cpp_api/templatelist/templatelist.md) + Parameter | Type | Description + --- | --- | --- + target | br_template_list | Pointer to a [TemplateList](../cpp_api/templatelist/templatelist.md) + query | br_template_list | Pointer to a [TemplateList](../cpp_api/templatelist/templatelist.md) * **output:** ([br_matrix_output](typedefs.md#br_matrix_output)) Returns a pointer to a [MatrixOutput](../cpp_api/matrixoutput/matrixoutput.md) @@ -1247,15 +1247,15 @@ Get a value in a provided [MatrixOutput](../cpp_api/matrixoutput/matrixoutput.md * **function definition:** - float br_get_matrix_output_at(br_matrix_output output, int row, int col) + float br_get_matrix_output_at(br_matrix_output output, int row, int col) * **parameters:** - Parameter | Type | Description - --- | --- | --- - output | br_matrix_output | Pointer to [MatrixOutput](../cpp_api/matrixoutput/matrixoutput.md) - row | int | Row index for lookup - col | int | Column index for lookup + Parameter | Type | Description + --- | --- | --- + output | br_matrix_output | Pointer to [MatrixOutput](../cpp_api/matrixoutput/matrixoutput.md) + row | int | Row index for lookup + col | int | Column index for lookup * **output:** (float) Returns the value of the [MatrixOutput](../cpp_api/matrixoutput/matrixoutput.md) at the provided indexes. @@ -1267,14 +1267,14 @@ Get a [Template](../cpp_api/template/template.md) from a [TemplateList](../cpp_a * **function definition:** - br_template br_get_template(br_template_list tl, int index) + br_template br_get_template(br_template_list tl, int index) * **parameters:** - Parameter | Type | Description - --- | --- | --- - tl | [br_template_list](typedefs.md#br_template_list) | Pointer to a [TemplateList](../cpp_api/templatelist/templatelist.md) - index | int | Index into the template list. Should be in the range [0,len(tl) - 1]. + Parameter | Type | Description + --- | --- | --- + tl | [br_template_list](typedefs.md#br_template_list) | Pointer to a [TemplateList](../cpp_api/templatelist/templatelist.md) + index | int | Index into the template list. Should be in the range [0,len(tl) - 1]. * **output:** ([br_template](typedefs.md#br_template)) Returns a pointer to a [Template](../cpp_api/template/template.md) @@ -1286,13 +1286,13 @@ Get the number of [Templates](../cpp_api/template/template.md) in a [TemplateLis * **function definition:** - int br_num_templates(br_template_list tl) + int br_num_templates(br_template_list tl) * **parameters:** - Parameter | Type | Description - --- | --- | --- - tl | [br_template_list](typedefs.md#br_template_list) | Pointer to a [TemplateList](../cpp_api/templatelist/templatelist.md) + Parameter | Type | Description + --- | --- | --- + tl | [br_template_list](typedefs.md#br_template_list) | Pointer to a [TemplateList](../cpp_api/templatelist/templatelist.md) * **output:** (int) Returns the size of the provided [TemplateList](../cpp_api/templatelist/templatelist.md) @@ -1304,13 +1304,13 @@ Initialize a [Gallery](../cpp_api/gallery/gallery.md) from a file. * **function definition:** - br_gallery br_make_gallery(const char *gallery) + br_gallery br_make_gallery(const char *gallery) * **parameters:** - Parameter | Type | Description - --- | --- | --- - gallery | const char * | String location of gallery on disk. + Parameter | Type | Description + --- | --- | --- + gallery | const char * | String location of gallery on disk. * **output:** ([br_gallery](typedefs.md#br_gallery)) Returns a pointer to a [Gallery](../cpp_api/gallery/gallery.md) that has been created from the provided file @@ -1322,13 +1322,13 @@ Read a [TemplateList](../cpp_api/templatelist/templatelist.md) from a [Gallery]( * **function definition:** - br_template_list br_load_from_gallery(br_gallery gallery) + br_template_list br_load_from_gallery(br_gallery gallery) * **parameters:** - Parameter | Type | Description - --- | --- | --- - gallery | [br_gallery](typedefs.md#br_gallery) | Pointer to a [Gallery](../cpp_api/gallery/gallery.md) + Parameter | Type | Description + --- | --- | --- + gallery | [br_gallery](typedefs.md#br_gallery) | Pointer to a [Gallery](../cpp_api/gallery/gallery.md) * **output:** ([br_template_list](typedefs.md#br_template_list)) Returns a pointer to a [TemplateList](../cpp_api/templatelist/templatelist.md) containing the data from the provided [Gallery](../cpp_api/gallery/gallery.md) @@ -1340,14 +1340,14 @@ Write a [Template](../cpp_api/template/template.md) to a [Gallery](../cpp_api/ga * **function definition:** - void br_add_template_to_gallery(br_gallery gallery, br_template tmpl) + void br_add_template_to_gallery(br_gallery gallery, br_template tmpl) * **parameters:** - Parameter | Type | Description - --- | --- | --- - gallery | [br_gallery](typedefs.md#br_gallery) | Pointer to a [Gallery](../cpp_api/gallery/gallery.md) - tmpl | [br_template](typedefs.md#br_template) | Pointer to a [Template](../cpp_api/template/template.md) + Parameter | Type | Description + --- | --- | --- + gallery | [br_gallery](typedefs.md#br_gallery) | Pointer to a [Gallery](../cpp_api/gallery/gallery.md) + tmpl | [br_template](typedefs.md#br_template) | Pointer to a [Template](../cpp_api/template/template.md) * **output:** (void) @@ -1359,14 +1359,14 @@ Write a [TemplateList](../cpp_api/templatelist/templatelist.md) to the [Gallery] * **function definition:** - void br_add_template_list_to_gallery(br_gallery gallery, br_template_list tl) + void br_add_template_list_to_gallery(br_gallery gallery, br_template_list tl) * **parameters:** - Parameter | Type | Description - --- | --- | --- - gallery | [br_gallery](typedefs.md#br_gallery) | Pointer to a [Gallery](../cpp_api/gallery/gallery.md) - tl | [br_template_list](typedefs.md#br_template_list) | Pointer to a [TemplateList](../cpp_api/templatelist/templatelist.md) + Parameter | Type | Description + --- | --- | --- + gallery | [br_gallery](typedefs.md#br_gallery) | Pointer to a [Gallery](../cpp_api/gallery/gallery.md) + tl | [br_template_list](typedefs.md#br_template_list) | Pointer to a [TemplateList](../cpp_api/templatelist/templatelist.md) * **output:** (void) @@ -1378,16 +1378,16 @@ Close a provided [Gallery](../cpp_api/gallery/gallery.md). * **function definition:** - void br_close_gallery(br_gallery gallery) + void br_close_gallery(br_gallery gallery) * **parameters:** - Parameter | Type | Description - --- | --- | --- - gallery | [br_gallery](typedefs.md#br_gallery) | Pointer to a [Gallery](../cpp_api/gallery/gallery.md) + Parameter | Type | Description + --- | --- | --- + gallery | [br_gallery](typedefs.md#br_gallery) | Pointer to a [Gallery](../cpp_api/gallery/gallery.md) * **output:** (void) [^1]: *Zhu et al.* - **A Rank-Order Distance based Clustering Algorithm for Face Tagging**, - CVPR 2011 + **A Rank-Order Distance based Clustering Algorithm for Face Tagging**, + CVPR 2011 diff --git a/docs/docs/api_docs/cl_api.md b/docs/docs/api_docs/cl_api.md index b07f81e..3e74b03 100644 --- a/docs/docs/api_docs/cl_api.md +++ b/docs/docs/api_docs/cl_api.md @@ -13,7 +13,7 @@ Shortcut | Definition Almost every command line process needs to specify an algorithm to work properly. Algorithms in OpenBR are described in detail [here](../tutorials.md#algorithms-in-openbr). To specify algorithms to the command line use the -algorithm flag like so: - -algorithm "AlgorithmString" + -algorithm "AlgorithmString" Make sure you use the quotes if your algorithm is longer than one plugin because special characters in OpenBR are also special characters (with very different meanings!) in Bash. @@ -25,7 +25,7 @@ Train a model * **arguments:** - -train ... [{model}] + -train ... [{model}] * **wraps:** [br_train_n](c_api/functions.md#br_train_n) @@ -35,7 +35,7 @@ Enroll a [Gallery](cpp_api/gallery/gallery.md) through an algorithm * **arguments:** - -enroll ... {output_gallery} + -enroll ... {output_gallery} * **wraps:** [br_enroll](c_api/functions.md#br_enroll) or [br_enroll_n](c_api/functions.md#br_enroll_n) depending on the input size @@ -45,7 +45,7 @@ Compare query [Templates](cpp_api/template/template.md) against a target [Galler * **arguments:** - -compare [{output}] + -compare [{output}] * **wraps:** [br_compare](c_api/functions.md#br_compare) @@ -55,7 +55,7 @@ DOCUMENT ME * **arguments:** - -pairwiseCompare [{output}] + -pairwiseCompare [{output}] * **wraps:** [br_pairwise_compare](c_api/functions.md#br_pairwise_compare) @@ -65,7 +65,7 @@ Evaluate a similarity matrix * **arguments:** - -eval [] [{csv}] [{matches}] + -eval [] [{csv}] [{matches}] * **wraps:** [br_eval](c_api/functions.md#br_eval) @@ -75,7 +75,7 @@ DOCUMENT ME * **arguments:** - -inplaceEval [{output}] + -inplaceEval [{output}] * **wraps:** [br_inplace_eval](c_api/functions.md#br_inplace_eval) @@ -98,7 +98,7 @@ Perform score level fusion on similarity matrices. * **arguments:** - -fuse ... (None|MinMax|ZScore|WScore) (Min|Max|Sum[W1:W2:...:Wn]|Replace|Difference|None) {simmat} + -fuse ... (None|MinMax|ZScore|WScore) (Min|Max|Sum[W1:W2:...:Wn]|Replace|Difference|None) {simmat} * **wraps:** [br_fuse](c_api/functions.md#br_fuse) @@ -108,7 +108,7 @@ Clusters one or more similarity matrices into a list of subjects * **arguments:** - -cluster ... {csv} + -cluster ... {csv} * **wraps:** [br_cluster](c_api/functions.md#br_cluster) @@ -118,7 +118,7 @@ Constructs a mask from target and query inputs * **arguments:** - -makeMask {mask} + -makeMask {mask} * **wraps:** [br_make_mask](c_api/functions.md#br_make_mask) @@ -128,7 +128,7 @@ Constructs a mask from target and query inputs considering the target and input * **arguments:** - -makePairwiseMask {mask} + -makePairwiseMask {mask} * **wraps:** [br_make_pairwise_mask](c_api/functions.md#br_make_pairwise_mask) @@ -138,7 +138,7 @@ Combines several equal-sized mask matrices. A comparison may not be simultaneous * **arguments:** - -combineMasks ... {mask} (And|Or) + -combineMasks ... {mask} (And|Or) * **wraps:** [br_combine_masks](c_api/functions.md#br_combine_masks) @@ -148,7 +148,7 @@ Concatenates a list of galleries into 1 gallery * **arguments:** - -cat ... {gallery} + -cat ... {gallery} * **wraps:** [br_cat](c_api/functions.md#br_cat) @@ -158,7 +158,7 @@ Convert a file to a different type. Files can only be converted to types within * **arguments:** - -convert (Format|Gallery|Output) {output_file} + -convert (Format|Gallery|Output) {output_file} * **wraps:** [br_convert](c_api/functions.md#br_convert) @@ -168,7 +168,7 @@ Evaluates and prints classification accuracy to terminal * **arguments:** - -evalClassification + -evalClassification * **wraps:** [br_eval_classification](c_api/functions.md#br_eval_classification) @@ -178,7 +178,7 @@ Evaluates and prints clustering accuracy to the terminal * **arguments:** - -evalClustering + -evalClustering * **wraps:** [br_eval_clustering](c_api/functions.md#br_eval_clustering) @@ -188,7 +188,7 @@ Evaluates and prints detection accuracy to terminal * **arguments:** - -evalDetection [{csv}] [{normalize}] [{minSize}] [{maxSize}] + -evalDetection [{csv}] [{normalize}] [{minSize}] [{maxSize}] * **wraps:** [br_eval_detection](c_api/functions.md#br_eval_detection) @@ -198,7 +198,7 @@ Evaluates and prints landmarking accuracy to terminal * **arguments:** - -evalLandmarking [{csv} [ ] [sample_index] [total_examples]] + -evalLandmarking [{csv} [ ] [sample_index] [total_examples]] * **wraps:** [br_eval_landmarking](c_api/functions.md#br_eval_landmarking) @@ -209,7 +209,7 @@ Evaluates regression accuracy to disk * **arguments:** - -evalRegression + -evalRegression * **wraps:** [br_eval_regression](c_api/functions.md#br_eval_regression) @@ -219,7 +219,7 @@ Evaluates the similarity matrix using the mask matrix. Function aborts if TAR @ * **arguments:** - -assertEval + -assertEval * **wraps:** [br_assert_eval](c_api/functions.md#br_assert_eval) @@ -229,7 +229,7 @@ Renders detection performance figures for a set of .csv files created by [-evalD * **arguments:** - -plotDetection ... {destination} + -plotDetection ... {destination} * **wraps:** [br_plot_detection](c_api/functions.md#br_plot_detection) @@ -239,7 +239,7 @@ Renders landmarking performance figures for a set of .csv files created by [-eva * **arguments:** - -plotLandmarking ... {destination} + -plotLandmarking ... {destination} * **wraps:** [br_plot_landmarking](c_api/functions.md#br_plot_landmarking) @@ -249,7 +249,7 @@ Renders metadata figures for a set of .csv files with specified columns * **arguments:** - -plotMetadata ... + -plotMetadata ... * **wraps:** [br_plot_metadata](c_api/functions.md#br_plot_metadata) @@ -259,7 +259,7 @@ A naive alternative to [-enroll](#enroll) * **arguments:** - -project {output_gallery} + -project {output_gallery} * **wraps:** [br_project](c_api/functions.md#br_project) @@ -269,7 +269,7 @@ Retrieve the target and query inputs in the [BEE matrix](../tutorials.md#the-eva * **arguments:** - -getHeader + -getHeader * **wraps:** [br_get_header](c_api/functions.md#br_get_header) @@ -279,7 +279,7 @@ Update the target and query inputs in the [BEE matrix](../tutorials.md#the-evalu * **arguments:** - -setHeader {} + -setHeader {} * **wraps:** [br_set_header](c_api/functions.md#br_set_header) @@ -289,7 +289,7 @@ Appends a provided value to the [global metadata](cpp_api/context/context.md) us * **arguments:** - - + - * **wraps:** [br_set_property](c_api/functions.md#br_set_property) @@ -302,7 +302,7 @@ Print command line API documentation to the terminal * **arguments:** - -help + -help * **wraps:** N/A @@ -312,7 +312,7 @@ If this flag is set OpenBR will enable GUI windows to be launched. It must be th * **arguments:** - br -gui + br -gui * **wraps:** N/A @@ -322,7 +322,7 @@ Returns names and parameters for the requested objects. Each object is newline s * **arguments:** - -objects [abstraction [implementation]] + -objects [abstraction [implementation]] * **wraps:** [br_objects](c_api/functions.md#br_objects) @@ -332,7 +332,7 @@ Get a string with the name, version, and copyright of the project. This string i * **arguments:** - -about + -about * **wraps:** [br_about](c_api/functions.md#br_about) @@ -342,7 +342,7 @@ Get the current OpenBR version * **arguments:** - -version + -version * **wraps:** [br_version](c_api/functions.md#br_version) @@ -352,7 +352,7 @@ For internal use via [ProcessWrapperTransform](plugins/core.md#processwrappertra * **arguments:** - -slave + -slave * **wraps:** [br_slave_process](c_api/functions.md#br_slave_process) @@ -362,7 +362,7 @@ DOCUMENT ME * **arguments:** - -daemon + -daemon * **wraps:** N/A @@ -372,6 +372,6 @@ Exit the application * **arguments:** - -exit + -exit * **wraps:** N/A diff --git a/docs/docs/api_docs/cpp_api/classifier/constructors.md b/docs/docs/api_docs/cpp_api/classifier/constructors.md index 0ca1a5a..b098412 100644 --- a/docs/docs/api_docs/cpp_api/classifier/constructors.md +++ b/docs/docs/api_docs/cpp_api/classifier/constructors.md @@ -1,3 +1,3 @@ Constructor / Destructor | Description --- | --- -virtual ~Classifier() | Default destructor. It doesn' do anything. \ No newline at end of file +virtual ~Classifier() | Default destructor. It doesn' do anything. diff --git a/docs/docs/api_docs/cpp_api/classifier/functions.md b/docs/docs/api_docs/cpp_api/classifier/functions.md index 9e4c943..8949c75 100644 --- a/docs/docs/api_docs/cpp_api/classifier/functions.md +++ b/docs/docs/api_docs/cpp_api/classifier/functions.md @@ -1,22 +1,22 @@ ## void train(const [QList][QList]<[Mat][Mat]> &images, const [QList][QList]<float> &labels) {: #train } -This is a pure, virtual function. Train the classifier using the provided images and labels. +This is a pure, virtual function. Train the classifier using the provided images and labels. * **function definition:** - virtual void train(const QList &images, const QList &labels) = 0 - + virtual void train(const QList &images, const QList &labels) = 0 + * **parameters:** - Parameter | Type | Descriptions - --- | --- | --- - images | const [QList][QList]<[Mat][Mat]> & | Training images - labels | const [QList][QList]<float> & | Training labels - + Parameter | Type | Descriptions + --- | --- | --- + images | const [QList][QList]<[Mat][Mat]> & | Training images + labels | const [QList][QList]<float> & | Training labels + * **output:** (void) * **example:** - // Create data for a 2-class classification problem + // Create data for a 2-class classification problem QList images = QList() << Template("training_pic1.jpg").m() << Template("training_pic2.jpg").m() << Template("training_pic3.jpg").m() @@ -29,24 +29,24 @@ This is a pure, virtual function. Train the classifier using the provided images ## float classify(const [Mat][Mat] &image) const {: #classify } -This is a pure virtual function. Classify a provided input image. +This is a pure virtual function. Classify a provided input image. * **function description:** - virtual float classify(const Mat &image) const = 0 - + virtual float classify(const Mat &image) const = 0 + * **parameters:** - - Parameter | Type | Description - --- | --- | --- - image | const [Mat][Mat] & | Input image to be classified - -* **output:** (float) Returns the classification value of the image. The value can be a confidence, a regression, or a class. In 2-class classification is it often a confidence which has been normalized such that 0 is the inflection point. Values below zero represent a negative classification and values above represent a positive classification. + + Parameter | Type | Description + --- | --- | --- + image | const [Mat][Mat] & | Input image to be classified + +* **output:** (float) Returns the classification value of the image. The value can be a confidence, a regression, or a class. In 2-class classification is it often a confidence which has been normalized such that 0 is the inflection point. Values below zero represent a negative classification and values above represent a positive classification. * **example:** - Classifier *classifier = Classifier::make("2ClassClassifier"); // assume classifier is already trained - - Template p1("pos_image1.jpg"); // positive sample - Template n1("neg_image1.jpg"); // negative sample - - classifier->classify(p1); // returns confidence > 0 - classifier->classify(n1); // returns confidence < 0 + Classifier *classifier = Classifier::make("2ClassClassifier"); // assume classifier is already trained + + Template p1("pos_image1.jpg"); // positive sample + Template n1("neg_image1.jpg"); // negative sample + + classifier->classify(p1); // returns confidence > 0 + classifier->classify(n1); // returns confidence < 0 diff --git a/docs/docs/api_docs/cpp_api/classifier/statics.md b/docs/docs/api_docs/cpp_api/classifier/statics.md index e6dec03..e87f628 100644 --- a/docs/docs/api_docs/cpp_api/classifier/statics.md +++ b/docs/docs/api_docs/cpp_api/classifier/statics.md @@ -18,4 +18,4 @@ Make a [Classifier](classifier.md) from a string. The string is passed to [Facto * **example:** Classifier *classifier = Classifier::make("Classifier(representation=Representation(property1=value1)"); - classifier->description(); // Returns "Classifier(representation=Representation(property1=value1))" \ No newline at end of file + classifier->description(); // Returns "Classifier(representation=Representation(property1=value1))" diff --git a/docs/docs/api_docs/cpp_api/compositetransform/constructors.md b/docs/docs/api_docs/cpp_api/compositetransform/constructors.md index 3d8d67a..a610b8d 100644 --- a/docs/docs/api_docs/cpp_api/compositetransform/constructors.md +++ b/docs/docs/api_docs/cpp_api/compositetransform/constructors.md @@ -1,3 +1,3 @@ Constructor | Description --- | --- -CompositeTransform() | Default constructor. Calls the [TimeVaryingTransform](../timevaryingtransform/timevaryingtransform.md) [constructor](../timevaryingtransform/constructors.md) with [independent](../transform/members.md#independent) set to false. \ No newline at end of file +CompositeTransform() | Default constructor. Calls the [TimeVaryingTransform](../timevaryingtransform/timevaryingtransform.md) [constructor](../timevaryingtransform/constructors.md) with [independent](../transform/members.md#independent) set to false. diff --git a/docs/docs/api_docs/cpp_api/compositetransform/functions.md b/docs/docs/api_docs/cpp_api/compositetransform/functions.md index 9d1dbb4..844d88e 100644 --- a/docs/docs/api_docs/cpp_api/compositetransform/functions.md +++ b/docs/docs/api_docs/cpp_api/compositetransform/functions.md @@ -27,7 +27,7 @@ If the transform is time varying call [timeInvariantAlias](../timevaryingtransfo * **function definition:** virtual void project(const Template &src, Template &dst) const - + * **parameters:** Parameter | Type | Description @@ -44,7 +44,7 @@ If the transform is time varying call [timeInvariantAlias](../timevaryingtransfo * **function definition:** virtual void project(const TemplateList &src, TemplateList &dst) const - + * **parameters:** Parameter | Type | Description @@ -118,4 +118,4 @@ Get a smart copy, meaning a copy only if one is required, of this transform --- | --- | --- newTransform | bool & | True if a new, simplified, transform was allocated inside this call, false otherwise -* **output:** ([Transform](../transform/transform.md) \*) Returns itself if [isTimeVarying](members.md#istimevarying) is false (no copy needed). newTransform is set to false in this case. If [isTimeVarying](members.md#istimevarying) is true, a new [CompositeTransform](compositetransform.md) is allocated and its children are set to the result of calling smartCopy on each of the old children. newTransform is true in this case. \ No newline at end of file +* **output:** ([Transform](../transform/transform.md) \*) Returns itself if [isTimeVarying](members.md#istimevarying) is false (no copy needed). newTransform is set to false in this case. If [isTimeVarying](members.md#istimevarying) is true, a new [CompositeTransform](compositetransform.md) is allocated and its children are set to the result of calling smartCopy on each of the old children. newTransform is true in this case. diff --git a/docs/docs/api_docs/cpp_api/compositetransform/members.md b/docs/docs/api_docs/cpp_api/compositetransform/members.md index 7710dbc..ae23870 100644 --- a/docs/docs/api_docs/cpp_api/compositetransform/members.md +++ b/docs/docs/api_docs/cpp_api/compositetransform/members.md @@ -1,3 +1,3 @@ Member | Type | Description --- | --- | --- -isTimeVarying | bool | True if any child transform is time varying, false otherwise \ No newline at end of file +isTimeVarying | bool | True if any child transform is time varying, false otherwise diff --git a/docs/docs/api_docs/cpp_api/distance/constructors.md b/docs/docs/api_docs/cpp_api/distance/constructors.md index 4a29813..ae1271c 100644 --- a/docs/docs/api_docs/cpp_api/distance/constructors.md +++ b/docs/docs/api_docs/cpp_api/distance/constructors.md @@ -1,3 +1,3 @@ Constructor / Destructor | Description --- | --- -virtual ~Distance() | The default destructor. It doesn't do anything. \ No newline at end of file +virtual ~Distance() | The default destructor. It doesn't do anything. diff --git a/docs/docs/api_docs/cpp_api/factory/macros.md b/docs/docs/api_docs/cpp_api/factory/macros.md index fc54c07..fbc9c30 100644 --- a/docs/docs/api_docs/cpp_api/factory/macros.md +++ b/docs/docs/api_docs/cpp_api/factory/macros.md @@ -23,5 +23,3 @@ A special macro to register plugins in the [Factory](factory.md)::[registry](mem }; BR_REGISTER(Abstraction, Implementation) - - diff --git a/docs/docs/api_docs/cpp_api/file/constructors.md b/docs/docs/api_docs/cpp_api/file/constructors.md index 9dcb954..eaeed0f 100644 --- a/docs/docs/api_docs/cpp_api/file/constructors.md +++ b/docs/docs/api_docs/cpp_api/file/constructors.md @@ -7,4 +7,3 @@ File(const [QString][QString] &file) | Initializes the file by calling the priva File(const [QString][QString] &file, const [QVariant][QVariant] &label) | Initializes the file by calling the private function init. Append label to the [metadata](members.md#m_metadata) using the key "Label". File(const char \*file) | Initializes the file with a c-style string. File(const [QVariantMap][QVariantMap] &metadata) | Sets [name](members.md#name) to false and sets the [file metadata](members.md#m_metadata) to metadata. - diff --git a/docs/docs/api_docs/cpp_api/file/file.md b/docs/docs/api_docs/cpp_api/file/file.md index d3f244a..9da2bb9 100644 --- a/docs/docs/api_docs/cpp_api/file/file.md +++ b/docs/docs/api_docs/cpp_api/file/file.md @@ -62,4 +62,4 @@ Rects | QList<Rect> | List of unnamed rects Age | float | Age used for demographic filtering Gender | QString | Subject gender Train | bool | The data is for training, as opposed to enrollment -_\* | \* | Reserved for internal use \ No newline at end of file +_\* | \* | Reserved for internal use diff --git a/docs/docs/api_docs/cpp_api/filegallery/functions.md b/docs/docs/api_docs/cpp_api/filegallery/functions.md index aa2d515..d287d15 100644 --- a/docs/docs/api_docs/cpp_api/filegallery/functions.md +++ b/docs/docs/api_docs/cpp_api/filegallery/functions.md @@ -3,8 +3,8 @@ Initialize the [FileGallery](filegallery.md). This sets [f](members.md#f) using the file name from [file](../object/members.md#file). It also calls [Gallery](../gallery/gallery.md)::[init](../object/functions.md#init). * **function definition:** - - void init() + + void init() * **parameters:** NONE * **output:** (void) @@ -14,8 +14,8 @@ Initialize the [FileGallery](filegallery.md). This sets [f](members.md#f) using Get the total size of the file. This is useful for estimating progress. * **function definition:** - - qint64 totalSize() + + qint64 totalSize() * **parameters:** NONE * **output:** (qint64) Returns the total size of the file in bytes @@ -26,7 +26,7 @@ Get the current index in the file. This is useful for reading and writing blocks * **function definition:** - qint64 position() + qint64 position() * **parameters:** NONE * **output:** (qint64) Returns the current position in the file @@ -37,8 +37,8 @@ Open [f](members.md#f) in read-only mode * **function definition:** - bool readOpen() - + bool readOpen() + * **parameters:** NONE * **output:** (bool) Returns true if the file was opened successfully, false otherwise @@ -48,7 +48,7 @@ Open [f](members.md#f) in write-only mode * **function definition:** - void writeOpen() + void writeOpen() * **parameters:** NONE -* **output:** (void) \ No newline at end of file +* **output:** (void) diff --git a/docs/docs/api_docs/cpp_api/format/statics.md b/docs/docs/api_docs/cpp_api/format/statics.md index 9963113..d8b0123 100644 --- a/docs/docs/api_docs/cpp_api/format/statics.md +++ b/docs/docs/api_docs/cpp_api/format/statics.md @@ -39,4 +39,3 @@ Write a template to disk at the provided file location. Template t("picture.jpg"); Format::write("new_pic_location.jpg", t); // Write t to "new_pic_location.jpg" - diff --git a/docs/docs/api_docs/cpp_api/initializer/functions.md b/docs/docs/api_docs/cpp_api/initializer/functions.md index c0a62dc..ee450d7 100644 --- a/docs/docs/api_docs/cpp_api/initializer/functions.md +++ b/docs/docs/api_docs/cpp_api/initializer/functions.md @@ -15,7 +15,7 @@ This is a virtual function. It is called once at the beginning of [finalize](../ * **function definition**: - virtual void finalize() const + virtual void finalize() const * **parameters:** NONE -* **output:** (void) \ No newline at end of file +* **output:** (void) diff --git a/docs/docs/api_docs/cpp_api/matrixoutput/functions.md b/docs/docs/api_docs/cpp_api/matrixoutput/functions.md index 01742b8..53e503e 100644 --- a/docs/docs/api_docs/cpp_api/matrixoutput/functions.md +++ b/docs/docs/api_docs/cpp_api/matrixoutput/functions.md @@ -4,25 +4,25 @@ Get a value in [data](members.md#data) as a string using a provided row and colu * **function definition:** - QString toString(int row, int column) const + QString toString(int row, int column) const * **parameters:** - Parameter | Type | Description - --- | --- | --- - row | int | Row index of value - column | int | Column index of value + Parameter | Type | Description + --- | --- | --- + row | int | Row index of value + column | int | Column index of value * **output:** ([QString][QString]) Returns the value stored at (row, column) as a string * **example:** - TemplateList targets = TemplateList() << Template("target1.jpg") << Template("target2.jpg") << Template("target3.jpg"); - TemplateList queries = TemplateList() << Template("query1.jpg") << Template("query2.jpg"); + TemplateList targets = TemplateList() << Template("target1.jpg") << Template("target2.jpg") << Template("target3.jpg"); + TemplateList queries = TemplateList() << Template("query1.jpg") << Template("query2.jpg"); - MatrixOutput *output = MatrixOutput::make(targets, queries); - output->set(10.0, 1, 2); - output->toString(1, 2); // Returns "10" - output->toString(2, 2); // ERROR: row index is out of range + MatrixOutput *output = MatrixOutput::make(targets, queries); + output->set(10.0, 1, 2); + output->toString(1, 2); // Returns "10" + output->toString(2, 2); // ERROR: row index is out of range ## void initialize(const [FileList](../filelist/filelist.md) &targetFiles, const [FileList](../filelist/filelist.md) &queryFiles) {: #initialize} @@ -30,14 +30,14 @@ Initialize the output. This function calls [initialize](../output/functions.md#i * **function definition:** - void initialize(const FileList &targetFiles, const FileList &queryFiles) + void initialize(const FileList &targetFiles, const FileList &queryFiles) * **parameters:** - Parameter | Type | Description - --- | --- | --- - targetFiles | const [FileList](../filelist/filelist.md) & | List of target files for initialization - queryFiles | const [FileList](../filelist/filelist.md) & | List of query files for initialization + Parameter | Type | Description + --- | --- | --- + targetFiles | const [FileList](../filelist/filelist.md) & | List of target files for initialization + queryFiles | const [FileList](../filelist/filelist.md) & | List of query files for initialization * **output:** (void) @@ -48,25 +48,25 @@ Set a value in [data](members.md#data) at the provided row and column indices. * **function definition:** - void set(float value, int i, int j) + void set(float value, int i, int j) * **parameters:** - Parameter | Type | Description - --- | --- | --- - value | float | Value to be set - i | int | Row index into [data](members.md#data) - j | int | Column index into [data](members.md#data) + Parameter | Type | Description + --- | --- | --- + value | float | Value to be set + i | int | Row index into [data](members.md#data) + j | int | Column index into [data](members.md#data) * **output:** (void) * **example:** - TemplateList targets = TemplateList() << Template("target1.jpg") << Template("target2.jpg") << Template("target3.jpg"); - TemplateList queries = TemplateList() << Template("query1.jpg") << Template("query2.jpg"); + TemplateList targets = TemplateList() << Template("target1.jpg") << Template("target2.jpg") << Template("target3.jpg"); + TemplateList queries = TemplateList() << Template("query1.jpg") << Template("query2.jpg"); - MatrixOutput *output = MatrixOutput::make(targets, queries); - output->set(6.0, 0, 1); - output->toString(0, 1); // Returns "6.0" + MatrixOutput *output = MatrixOutput::make(targets, queries); + output->set(6.0, 0, 1); + output->toString(0, 1); // Returns "6.0" - output->set(10.0, 1, 2); - output->toString(1, 2); // Returns "10.0" + output->set(10.0, 1, 2); + output->toString(1, 2); // Returns "10.0" diff --git a/docs/docs/api_docs/cpp_api/matrixoutput/statics.md b/docs/docs/api_docs/cpp_api/matrixoutput/statics.md index 605fc4f..cdd869c 100644 --- a/docs/docs/api_docs/cpp_api/matrixoutput/statics.md +++ b/docs/docs/api_docs/cpp_api/matrixoutput/statics.md @@ -4,19 +4,19 @@ Make an [MatrixOutput](matrixoutput.md) from lists of target and query files. Th * **function definition:** - static MatrixOutput *make(const FileList &targetFiles, const FileList &queryFiles) + static MatrixOutput *make(const FileList &targetFiles, const FileList &queryFiles) * **parameters:** - Parameter | Type | Description - --- | --- | --- - targetFiles | const [FileList](../filelist/filelist.md) & | List of files representing the target templates - queryFiles | const [FileList](../filelist/filelist.md) & | List of files representing the query templates + Parameter | Type | Description + --- | --- | --- + targetFiles | const [FileList](../filelist/filelist.md) & | List of files representing the target templates + queryFiles | const [FileList](../filelist/filelist.md) & | List of files representing the query templates * **output:** ([MatrixOutput](matrixoutput.md) \*) Returns a pointer to the first output in the linked list * **example:** - TemplateList targets = TemplateList() << Template("target1.jpg") << Template("target2.jpg") << Template("target3.jpg"); - TemplateList queries = TemplateList() << Template("query1.jpg") << Template("query2.jpg"); + TemplateList targets = TemplateList() << Template("target1.jpg") << Template("target2.jpg") << Template("target3.jpg"); + TemplateList queries = TemplateList() << Template("query1.jpg") << Template("query2.jpg"); - MatrixOutput *output = MatrixOutput::make(targets, queries); // returns a pointer to a MatrixOutput + MatrixOutput *output = MatrixOutput::make(targets, queries); // returns a pointer to a MatrixOutput diff --git a/docs/docs/api_docs/cpp_api/metadatatransform/functions.md b/docs/docs/api_docs/cpp_api/metadatatransform/functions.md index 9d05e71..9dafec6 100644 --- a/docs/docs/api_docs/cpp_api/metadatatransform/functions.md +++ b/docs/docs/api_docs/cpp_api/metadatatransform/functions.md @@ -16,37 +16,37 @@ This is a pure virtual function. It must be overloaded by all derived classes. P * **output:** (void) * **example:** - class IncrementPropertyTransform : public MetadataTransform - { - Q_OBJECT - Q_PROPERTY(QString key READ get_key WRITE set_key RESET reset_key STORED false) - BR_PROPERTY(QString, key, "") + class IncrementPropertyTransform : public MetadataTransform + { + Q_OBJECT + Q_PROPERTY(QString key READ get_key WRITE set_key RESET reset_key STORED false) + BR_PROPERTY(QString, key, "") - void projectMetadata(const File &src, File &dst) const - { - dst = src; - dst.set(key, src.get(key, 0) + 1); - } - }; - - BR_REGISTER(Transform, IncrementPropertyTransform) + void projectMetadata(const File &src, File &dst) const + { + dst = src; + dst.set(key, src.get(key, 0) + 1); + } + }; - MetadataTransform *m_transform = (MetadataTransform *)Transform::make("IncrementProperty(property1)", NULL); + BR_REGISTER(Transform, IncrementPropertyTransform) - File in("picture.jpg"), out; - in.set("property1", 10); + MetadataTransform *m_transform = (MetadataTransform *)Transform::make("IncrementProperty(property1)", NULL); - m_transform->projectMetadata(in, out); - out.flat(); // Returns "picture.jpg[property1=11]" + File in("picture.jpg"), out; + in.set("property1", 10); + + m_transform->projectMetadata(in, out); + out.flat(); // Returns "picture.jpg[property1=11]" ## void project(const [Template](../template/template.md) &src, [Template](../template/template.md) &dst) {: #project } -Project a [Template](../template/template.md) through the transform by passing its [metadata](../template/members.md#file) through [projectMetadata](#projectmetadata) and storing the result in dst. All matrices in src are passed unchanged to dst. +Project a [Template](../template/template.md) through the transform by passing its [metadata](../template/members.md#file) through [projectMetadata](#projectmetadata) and storing the result in dst. All matrices in src are passed unchanged to dst. * **function definition:** - void project(const Template &src, Template &dst) const + void project(const Template &src, Template &dst) const * **parameters:** @@ -55,4 +55,4 @@ Project a [Template](../template/template.md) through the transform by passing i src | const [Template](../template/template.md) & | Input Template. It is immutable dst | [Template](../template/template.md) & | Output Template. Should contain the modified data from the input template. -* **output:** (void) \ No newline at end of file +* **output:** (void) diff --git a/docs/docs/api_docs/cpp_api/metatransform/constructors.md b/docs/docs/api_docs/cpp_api/metatransform/constructors.md index 7c67f24..09f3a16 100644 --- a/docs/docs/api_docs/cpp_api/metatransform/constructors.md +++ b/docs/docs/api_docs/cpp_api/metatransform/constructors.md @@ -1,3 +1,3 @@ Constructor / Destructor | Description --- | --- -MetaTransform() | Construct a [MetaTransform](metatransform.md). This constructor calls the [Transform](../transform/transform.md) [constructor](../transform/constructors.md) with [independent](../transform/members.md#independent) set to false. \ No newline at end of file +MetaTransform() | Construct a [MetaTransform](metatransform.md). This constructor calls the [Transform](../transform/transform.md) [constructor](../transform/constructors.md) with [independent](../transform/members.md#independent) set to false. diff --git a/docs/docs/api_docs/cpp_api/object/macros.md b/docs/docs/api_docs/cpp_api/object/macros.md index 6d24db4..b311f84 100644 --- a/docs/docs/api_docs/cpp_api/object/macros.md +++ b/docs/docs/api_docs/cpp_api/object/macros.md @@ -29,4 +29,3 @@ This macro provides an extension to the [Qt Property System][Qt Property System] ... }; - diff --git a/docs/docs/api_docs/cpp_api/object/statics.md b/docs/docs/api_docs/cpp_api/object/statics.md index eaff696..db6e702 100644 --- a/docs/docs/api_docs/cpp_api/object/statics.md +++ b/docs/docs/api_docs/cpp_api/object/statics.md @@ -17,4 +17,3 @@ Split the provided string using the provided split character. Lexical scoping of * **example:** Object::parse("Transform1(p1=v1,p2=v2),Transform2(p1=v3,p2=v4)"); // returns ["Transform1(p1=v1,p2=v2)", "Transform2(p1=v3,p2=v4)"] - diff --git a/docs/docs/api_docs/cpp_api/output/functions.md b/docs/docs/api_docs/cpp_api/output/functions.md index c01e496..ae35092 100644 --- a/docs/docs/api_docs/cpp_api/output/functions.md +++ b/docs/docs/api_docs/cpp_api/output/functions.md @@ -4,23 +4,23 @@ This is a virtual function. Initialize the output with provided target and query * **function definition:** - virtual void initialize(const [FileList](../filelist/filelist.md) &targetFiles, const [FileList](../filelist/filelist.md) &queryFiles) + virtual void initialize(const [FileList](../filelist/filelist.md) &targetFiles, const [FileList](../filelist/filelist.md) &queryFiles) * **parameters:** - Parameter | Type | Description - --- | --- | --- - targetFiles | const [FileList](../filelist/filelist.md) & | Target files to initialize the Output with - queryFiles | const [FileList](../filelist/filelist.md) & | Query files to initialize the Output with + Parameter | Type | Description + --- | --- | --- + targetFiles | const [FileList](../filelist/filelist.md) & | Target files to initialize the Output with + queryFiles | const [FileList](../filelist/filelist.md) & | Query files to initialize the Output with * **output:** (void) * **example:** - TemplateList targets = TemplateList() << Template("target1.jpg") << Template("target2.jpg") << Template("target3.jpg"); - TemplateList queries = TemplateList() << Template("query1.jpg") << Template("query2.jpg"); + TemplateList targets = TemplateList() << Template("target1.jpg") << Template("target2.jpg") << Template("target3.jpg"); + TemplateList queries = TemplateList() << Template("query1.jpg") << Template("query2.jpg"); - Output *output = Factory::make("output.mtx"); - output->initialize(targets, queries); // This is the same as calling Output::make("output.mtx", targets, queries) + Output *output = Factory::make("output.mtx"); + output->initialize(targets, queries); // This is the same as calling Output::make("output.mtx", targets, queries) ## void setBlock(int rowBlock, int columnBlock) {: #setblock } @@ -28,14 +28,14 @@ This is a virtual function. Set the read offset of the Output. * **function definition:** - virtual void setBlock(int rowBlock, int columnBlock) + virtual void setBlock(int rowBlock, int columnBlock) * **parameters:** - Parameter | Type | Description - --- | --- | --- - rowBlock | int | Row position of the offset - columnBlock | int | Column position of the offset + Parameter | Type | Description + --- | --- | --- + rowBlock | int | Row position of the offset + columnBlock | int | Column position of the offset * **output:** (void) @@ -45,15 +45,15 @@ This is a virtual function. Set a value in the Output. **i** and **j** are *rela * **function definition:** - virtual void setRelative(float value, int i, int j) + virtual void setRelative(float value, int i, int j) * **parameters:** - Parameter | Type | Description - --- | --- | --- - value | float | Value to set in the output - i | int | Row value relative to the current block - j | int | Column value relative to the current block + Parameter | Type | Description + --- | --- | --- + value | float | Value to set in the output + i | int | Row value relative to the current block + j | int | Column value relative to the current block * **output:** (void) @@ -64,14 +64,14 @@ This is a pure virtual function. Set a value in the output. * **function definition:** - virtual void set(float value, int i, int j) = 0 + virtual void set(float value, int i, int j) = 0 * **parameters:** - Parameter | Type | Description - --- | --- | --- - value | float | Value to be inserted into the output - i | int | Row index to insert at - j | int | Column index to insert at + Parameter | Type | Description + --- | --- | --- + value | float | Value to be inserted into the output + i | int | Row index to insert at + j | int | Column index to insert at * **output:** (void) diff --git a/docs/docs/api_docs/cpp_api/output/members.md b/docs/docs/api_docs/cpp_api/output/members.md index dd644ac..24c9192 100644 --- a/docs/docs/api_docs/cpp_api/output/members.md +++ b/docs/docs/api_docs/cpp_api/output/members.md @@ -2,4 +2,4 @@ Member | Type | Description --- | --- | --- targetFiles | [FileList][../filelist/filelist.md] | List of files representing the target templates queryFiles | [FileList](../filelist/filelist.md) | List of files representing the query templates -selfSimilar | bool | True if targetFiles == queryFiles, false otherwise \ No newline at end of file +selfSimilar | bool | True if targetFiles == queryFiles, false otherwise diff --git a/docs/docs/api_docs/cpp_api/output/statics.md b/docs/docs/api_docs/cpp_api/output/statics.md index 021316d..fe604d9 100644 --- a/docs/docs/api_docs/cpp_api/output/statics.md +++ b/docs/docs/api_docs/cpp_api/output/statics.md @@ -4,21 +4,21 @@ Make an [Output](output.md) from a string and lists of target and query files. T * **function definition:** - static Output *make(const File &file, const FileList &targetFiles, const FileList &queryFiles) + static Output *make(const File &file, const FileList &targetFiles, const FileList &queryFiles) * **parameters:** - Parameter | Type | Description - --- | --- | --- - file | const [File](../file/file.md) & | File describing the output or outputs to construct - targetFiles | const [FileList](../filelist/filelist.md) & | List of files representing the target templates - queryFiles | const [FileList](../filelist/filelist.md) & | List of files representing the query templates + Parameter | Type | Description + --- | --- | --- + file | const [File](../file/file.md) & | File describing the output or outputs to construct + targetFiles | const [FileList](../filelist/filelist.md) & | List of files representing the target templates + queryFiles | const [FileList](../filelist/filelist.md) & | List of files representing the query templates * **output:** ([Output](output.md) \*) Returns a pointer to the first output in the linked list * **example:** - TemplateList targets = TemplateList() << Template("target1.jpg") << Template("target2.jpg") << Template("target3.jpg"); - TemplateList queries = TemplateList() << Template("query1.jpg") << Template("query2.jpg"); + TemplateList targets = TemplateList() << Template("target1.jpg") << Template("target2.jpg") << Template("target3.jpg"); + TemplateList queries = TemplateList() << Template("query1.jpg") << Template("query2.jpg"); - Output *output1 = Output::make("output.mtx", targets, queries); // returns a pointer to an Output at "output.mtx" - Output *output2 = Output::make("output1.mtx;output2.mtx", targets, queries); // returns a pointer to the output created with "output1.mtx" with a pointer to the output created with "output2.mtx" + Output *output1 = Output::make("output.mtx", targets, queries); // returns a pointer to an Output at "output.mtx" + Output *output2 = Output::make("output1.mtx;output2.mtx", targets, queries); // returns a pointer to the output created with "output1.mtx" with a pointer to the output created with "output2.mtx" diff --git a/docs/docs/api_docs/cpp_api/template/statics.md b/docs/docs/api_docs/cpp_api/template/statics.md index 3d351a6..21cd2be 100644 --- a/docs/docs/api_docs/cpp_api/template/statics.md +++ b/docs/docs/api_docs/cpp_api/template/statics.md @@ -54,4 +54,4 @@ Deserialize a template out.file; // returns "picture.jpg" out; // returns ["1"] - } \ No newline at end of file + } diff --git a/docs/docs/api_docs/cpp_api/template/template.md b/docs/docs/api_docs/cpp_api/template/template.md index ae9ef76..526e32b 100644 --- a/docs/docs/api_docs/cpp_api/template/template.md +++ b/docs/docs/api_docs/cpp_api/template/template.md @@ -19,4 +19,4 @@ in most cases templates have exactly one matrix in their list representing a sin In the cases where exactly one image is expected, the template provides the function m() as an idiom for treating it as a single matrix. Casting operators are also provided to pass the template into image processing functions expecting matrices. -Metadata related to the template that is computed during enrollment (ex. bounding boxes, eye locations, quality metrics, ...) should be assigned to the template's [File](members.md#file) member. \ No newline at end of file +Metadata related to the template that is computed during enrollment (ex. bounding boxes, eye locations, quality metrics, ...) should be assigned to the template's [File](members.md#file) member. diff --git a/docs/docs/api_docs/cpp_api/templatelist/statics.md b/docs/docs/api_docs/cpp_api/templatelist/statics.md index 085a881..8d8f170 100644 --- a/docs/docs/api_docs/cpp_api/templatelist/statics.md +++ b/docs/docs/api_docs/cpp_api/templatelist/statics.md @@ -63,4 +63,3 @@ Relabel the values associated with a given key in the [metadata](../file/members relabeled = TemplateList::relabel(tList, "Class", false); relabeled.files(); // returns [[Class=1, Label=0], [Class=10, Label=1], [Class=100, Label=2]] - diff --git a/docs/docs/api_docs/cpp_api/timevaryingtransform/constructors.md b/docs/docs/api_docs/cpp_api/timevaryingtransform/constructors.md index e8a6e5c..705e62c 100644 --- a/docs/docs/api_docs/cpp_api/timevaryingtransform/constructors.md +++ b/docs/docs/api_docs/cpp_api/timevaryingtransform/constructors.md @@ -1,3 +1,3 @@ Constructor | Description --- | --- -TimeVaryingTransform(bool independent = true, bool trainable = true) | Default constructor. Calls [Transform](../transform/transform.md) [constructor](../transform/constructors.md) with the given value of [independent](../transform/members.md#independent) and [trainable](../transform/members.md#trainable). It also initializes [timeInvariantAlias](members.md#timeinvariantalias). \ No newline at end of file +TimeVaryingTransform(bool independent = true, bool trainable = true) | Default constructor. Calls [Transform](../transform/transform.md) [constructor](../transform/constructors.md) with the given value of [independent](../transform/members.md#independent) and [trainable](../transform/members.md#trainable). It also initializes [timeInvariantAlias](members.md#timeinvariantalias). diff --git a/docs/docs/api_docs/cpp_api/timevaryingtransform/functions.md b/docs/docs/api_docs/cpp_api/timevaryingtransform/functions.md index 1536119..83b6923 100644 --- a/docs/docs/api_docs/cpp_api/timevaryingtransform/functions.md +++ b/docs/docs/api_docs/cpp_api/timevaryingtransform/functions.md @@ -4,7 +4,7 @@ This is a virtual function. Check if the transform is time varying. This always * **function definition:** - virtual bool timeVarying() const + virtual bool timeVarying() const * **parameters:** NONE * **output:** (bool) Returns true (the transform is always time varying) @@ -15,14 +15,14 @@ This is a virtual function. For [TimeVaryingTransforms](timevaryingtransform.md) * **function definition:** - virtual void project(const Template &src, Template &dst) const + virtual void project(const Template &src, Template &dst) const * **parameters:** - - Parameter | Type | Description - --- | --- | --- - src | const [Template](../template/template.md) & | The input template - dst | [Template](../template/template.md) & | The output template + + Parameter | Type | Description + --- | --- | --- + src | const [Template](../template/template.md) & | The input template + dst | [Template](../template/template.md) & | The output template * **output:** (void) @@ -32,14 +32,14 @@ This is a virtual function. For [TimeVaryingTransforms](timevaryingtransform.md) * **function definition:** - virtual void project(const TemplateList &src, TemplateList &dst) const + virtual void project(const TemplateList &src, TemplateList &dst) const * **parameters:** - - Parameter | Type | Description - --- | --- | --- - src | const [TemplateList](../templatelist/templatelist.md) & | The input template list - dst | [TemplateList](../templatelist/templatelist.md) & | The output template list + + Parameter | Type | Description + --- | --- | --- + src | const [TemplateList](../templatelist/templatelist.md) & | The input template list + dst | [TemplateList](../templatelist/templatelist.md) & | The output template list * **output:** (void) @@ -49,15 +49,15 @@ This is a virtual function. This function should never be called because it is u * **function definition:** - virtual void projectUpdate(const Template &src, Template &dst) + virtual void projectUpdate(const Template &src, Template &dst) * **parameters:** - Parameter | Type | Description - --- | --- | --- - src | const [Template](../template/template.md) & | The input template - dst | [Template](../template/template.md) & | The output template - + Parameter | Type | Description + --- | --- | --- + src | const [Template](../template/template.md) & | The input template + dst | [Template](../template/template.md) & | The output template + * **output:** (void) ## void projectUpdate(const [Template](../template/template.md) &src, [Template](../template/template.md) &dst) {: #projectupdate-1 } @@ -66,15 +66,15 @@ This is a virtual function. This function should never be called because it is u * **function definition:** - virtual void projectUpdate(const Template &src, Template &dst) + virtual void projectUpdate(const Template &src, Template &dst) * **parameters:** - Parameter | Type | Description - --- | --- | --- - src | const [Template](../template/template.md) & | The input template - dst | [Template](../template/template.md) & | The output template - + Parameter | Type | Description + --- | --- | --- + src | const [Template](../template/template.md) & | The input template + dst | [Template](../template/template.md) & | The output template + * **output:** (void) ## void projectUpdate(const [Template](../template/template.md) &src, [Template](../template/template.md) &dst) {: #projectupdate-1 } @@ -83,15 +83,15 @@ This is a virtual function. This function should never be called because it is u * **function definition:** - virtual void projectUpdate(const Template &src, Template &dst) + virtual void projectUpdate(const Template &src, Template &dst) * **parameters:** - Parameter | Type | Description - --- | --- | --- - src | const [Template](../template/template.md) & | The input template - dst | [Template](../template/template.md) & | The output template - + Parameter | Type | Description + --- | --- | --- + src | const [Template](../template/template.md) & | The input template + dst | [Template](../template/template.md) & | The output template + * **output:** (void) ## void projectUpdate(const [TemplateList](../templatelist/templatelist.md) &src, [TemplateList](../templatelist/templatelist.md) &dst) {: #projectupdate-2 } @@ -100,15 +100,15 @@ This is a virtual function. This is the non-const alternative to [project](../tr * **function definition:** - virtual void projectUpdate(const TemplateList &src, TemplateList &dst) + virtual void projectUpdate(const TemplateList &src, TemplateList &dst) * **parameters:** - Parameter | Type | Description - --- | --- | --- - src | const [TemplateList](../templatelist/templatelist.md) & | The input template list - dst | [TemplateList](../templatelist/templatelist.md) & | The output template list - + Parameter | Type | Description + --- | --- | --- + src | const [TemplateList](../templatelist/templatelist.md) & | The input template list + dst | [TemplateList](../templatelist/templatelist.md) & | The output template list + * **output:** (void) ## [Transform](../transform/transform.md) \*smartCopy(bool &newTransform) {: #smartcopy } @@ -117,12 +117,12 @@ This is a virtual function. Make a smart copy of the transform. * **function definition:** - virtual Transform *smartCopy(bool &newTransform) + virtual Transform *smartCopy(bool &newTransform) * **parameters:** - Parameter | Type | Description - --- | --- | --- - newTransform | bool & | True if a new, simplified, transform was allocated inside this call, false otherwise + Parameter | Type | Description + --- | --- | --- + newTransform | bool & | True if a new, simplified, transform was allocated inside this call, false otherwise -* **output:** ([Transform](../transform/transform.md) \*) Returns a copy of itself by default. newTransform is set to true in this case. \ No newline at end of file +* **output:** ([Transform](../transform/transform.md) \*) Returns a copy of itself by default. newTransform is set to true in this case. diff --git a/docs/docs/api_docs/cpp_api/timevaryingtransform/members.md b/docs/docs/api_docs/cpp_api/timevaryingtransform/members.md index f20dc9f..b7e3509 100644 --- a/docs/docs/api_docs/cpp_api/timevaryingtransform/members.md +++ b/docs/docs/api_docs/cpp_api/timevaryingtransform/members.md @@ -1,3 +1,3 @@ Members | Type | Description --- | --- | --- - timeInvariantAlias | TimeInvariantWrapperTransform | A special case helper class that ensures usually thread safe calls like [project](../transform/functions.md#project-1) can be called non-thread safe objects. In a very simplified description, this calls [projectUpdate](functions.md#projectupdate-1) instead of [project](functions.md#project-1) \ No newline at end of file + timeInvariantAlias | TimeInvariantWrapperTransform | A special case helper class that ensures usually thread safe calls like [project](../transform/functions.md#project-1) can be called non-thread safe objects. In a very simplified description, this calls [projectUpdate](functions.md#projectupdate-1) instead of [project](functions.md#project-1) diff --git a/docs/docs/api_docs/cpp_api/transform/transform.md b/docs/docs/api_docs/cpp_api/transform/transform.md index 69addf3..d08777a 100644 --- a/docs/docs/api_docs/cpp_api/transform/transform.md +++ b/docs/docs/api_docs/cpp_api/transform/transform.md @@ -11,4 +11,4 @@ See: * [Static Functions](statics.md) * [Functions](functions.md) -Transforms support the idea of *training* and *projecting*, whereby they are (optionally) given example images and are expected learn how to transform new instances into an alternative, hopefully more useful, basis for the recognition task at hand. Transforms can be chained together to support the declaration and use of arbitrary algorithms at run time. \ No newline at end of file +Transforms support the idea of *training* and *projecting*, whereby they are (optionally) given example images and are expected learn how to transform new instances into an alternative, hopefully more useful, basis for the recognition task at hand. Transforms can be chained together to support the declaration and use of arbitrary algorithms at run time. diff --git a/docs/docs/api_docs/cpp_api/untrainablemetadatatransform/constructors.md b/docs/docs/api_docs/cpp_api/untrainablemetadatatransform/constructors.md index c9fa680..8062896 100644 --- a/docs/docs/api_docs/cpp_api/untrainablemetadatatransform/constructors.md +++ b/docs/docs/api_docs/cpp_api/untrainablemetadatatransform/constructors.md @@ -1,3 +1,3 @@ Constructor / Destructor | Description --- | --- -UntrainableMetadataTransform() | Construct an [UntrainableMetadataTransform](untrainablemetadatatransform.md). This constructor calls the [MetadataTransform](../metadatatransform/metadatatransform.md) [constructor](../metadatatransform/constructors.md) with [trainable](../transform/members.md#trainable) set to false. \ No newline at end of file +UntrainableMetadataTransform() | Construct an [UntrainableMetadataTransform](untrainablemetadatatransform.md). This constructor calls the [MetadataTransform](../metadatatransform/metadatatransform.md) [constructor](../metadatatransform/constructors.md) with [trainable](../transform/members.md#trainable) set to false. diff --git a/docs/docs/api_docs/cpp_api/untrainablemetatransform/constructors.md b/docs/docs/api_docs/cpp_api/untrainablemetatransform/constructors.md index e969cb3..fda3d43 100644 --- a/docs/docs/api_docs/cpp_api/untrainablemetatransform/constructors.md +++ b/docs/docs/api_docs/cpp_api/untrainablemetatransform/constructors.md @@ -1,3 +1,3 @@ Constructor / Destructor | Description --- | --- -UntrainableMetaTransform() | Construct an [UntrainableMetaTransform](untrainablemetatransform.md). This constructor calls the [UntrainableTransform](../untrainabletransform/untrainabletransform.md) [constructor](../untrainabletransform/constructors.md) with [independent](../transform/members.md#independent) set to false. \ No newline at end of file +UntrainableMetaTransform() | Construct an [UntrainableMetaTransform](untrainablemetatransform.md). This constructor calls the [UntrainableTransform](../untrainabletransform/untrainabletransform.md) [constructor](../untrainabletransform/constructors.md) with [independent](../transform/members.md#independent) set to false. diff --git a/docs/docs/api_docs/cpp_api/untrainabletransform/constructors.md b/docs/docs/api_docs/cpp_api/untrainabletransform/constructors.md index dda03fe..bd47c06 100644 --- a/docs/docs/api_docs/cpp_api/untrainabletransform/constructors.md +++ b/docs/docs/api_docs/cpp_api/untrainabletransform/constructors.md @@ -1,3 +1,3 @@ Constructor / Destructor | Description --- | --- -UntrainableTransform(bool independent = true) | Construct an [UntrainableTransform](untrainabletransform.md). This constructor calls the [Transform](../transform/transform.md) [constructor](../transform/constructors.md) with the provided value for [independent](../transform/members.md#independent) and [trainable](../transform/members.md#trainable) set to false. \ No newline at end of file +UntrainableTransform(bool independent = true) | Construct an [UntrainableTransform](untrainabletransform.md). This constructor calls the [Transform](../transform/transform.md) [constructor](../transform/constructors.md) with the provided value for [independent](../transform/members.md#independent) and [trainable](../transform/members.md#trainable) set to false. diff --git a/docs/docs/api_docs/cpp_api/wrappertransform/constructors.md b/docs/docs/api_docs/cpp_api/wrappertransform/constructors.md index 6b7a6a0..64bbda6 100644 --- a/docs/docs/api_docs/cpp_api/wrappertransform/constructors.md +++ b/docs/docs/api_docs/cpp_api/wrappertransform/constructors.md @@ -1,3 +1,3 @@ Constructor | Description --- | --- -WrapperTransform(bool independent = true) | Default constructor. Calls [TimeVaryingTransform](../timevaryingtransform/timevaryingtransform.md) [constructor](../timevaryingtransform/constructors.md) with the given value for independent. \ No newline at end of file +WrapperTransform(bool independent = true) | Default constructor. Calls [TimeVaryingTransform](../timevaryingtransform/timevaryingtransform.md) [constructor](../timevaryingtransform/constructors.md) with the given value for independent. diff --git a/docs/docs/api_docs/cpp_api/wrappertransform/functions.md b/docs/docs/api_docs/cpp_api/wrappertransform/functions.md index 16fd68f..aaee9e9 100644 --- a/docs/docs/api_docs/cpp_api/wrappertransform/functions.md +++ b/docs/docs/api_docs/cpp_api/wrappertransform/functions.md @@ -4,8 +4,8 @@ Check whether the transform is timeVarying. * **function definition:** - bool timeVarying() const - + bool timeVarying() const + * **parameters:** NONE * **output:** (bool) Returns true if the [child transform](properties.md) is time varying, false otherwise @@ -15,13 +15,13 @@ Call train on the child transform * **function defintion:** - void train(const QList &data) + void train(const QList &data) * **parameters:** - Parameter | Type | Description - --- | --- | --- - data | const [QList][QList]<[TemplateList](../templatelist/templatelist.md)> & | The training data + Parameter | Type | Description + --- | --- | --- + data | const [QList][QList]<[TemplateList](../templatelist/templatelist.md)> & | The training data * **output:** (void) @@ -31,14 +31,14 @@ Call project on the child transform * **function definition:** - void project(const Template &src, Template &dst) const + void project(const Template &src, Template &dst) const * **parameters:** - Parameter | Type | Description - --- | --- | --- - src | const [Template](../template/template.md) & | The input template - dst | [Template](../template/template.md) & | The output template + Parameter | Type | Description + --- | --- | --- + src | const [Template](../template/template.md) & | The input template + dst | [Template](../template/template.md) & | The output template * **output:** (void) @@ -48,14 +48,14 @@ Call project on the child transform * **function definition:** - void project(const TemplateList &src, TemplateList &dst) const + void project(const TemplateList &src, TemplateList &dst) const * **parameters:** - Parameter | Type | Description - --- | --- | --- - src | const [TemplateList](../templatelist/templatelist.md) & | The input template list - dst | [TemplateList](../templatelist/templatelist.md) & | The output template list + Parameter | Type | Description + --- | --- | --- + src | const [TemplateList](../templatelist/templatelist.md) & | The input template list + dst | [TemplateList](../templatelist/templatelist.md) & | The output template list * **output:** (void) @@ -65,14 +65,14 @@ Call projectUpdate on the child transform * **function definition:** - void projectUpdate(const Template &src, Template &dst) + void projectUpdate(const Template &src, Template &dst) * **parameters:** - Parameter | Type | Description - --- | --- | --- - src | const [Template](../template/template.md) & | The input template - dst | [Template](../template/template.md) & | The output template + Parameter | Type | Description + --- | --- | --- + src | const [Template](../template/template.md) & | The input template + dst | [Template](../template/template.md) & | The output template * **output:** (void) @@ -82,24 +82,24 @@ Call projectUpdate on the child transform * **function definition:** - void projectUpdate(const TemplateList &src, TemplateList &dst) + void projectUpdate(const TemplateList &src, TemplateList &dst) * **parameters:** - Parameter | Type | Description - --- | --- | --- - src | const [TemplateList](../templatelist/templatelist.md) & | The input template list - dst | [TemplateList](../templatelist/templatelist.md) & | The output template list + Parameter | Type | Description + --- | --- | --- + src | const [TemplateList](../templatelist/templatelist.md) & | The input template list + dst | [TemplateList](../templatelist/templatelist.md) & | The output template list * **output:** (void) -## void init() {: #init } +## void init() {: #init } Initialize the transform. Sets [trainable](../transform/members.md#trainable) to match the child transform (if the child is trainable so is the wrapper) * **function definition:** - void init() + void init() * **parameters:** NONE * **output:** (void) @@ -110,13 +110,13 @@ This is a virtual function. Call finalize on the child transform * **function definition:** - virtual void finalize(TemplateList &output) - + virtual void finalize(TemplateList &output) + * **parameters:** - Parameter | Type | Description - --- | --- | --- - output | const [TemplateList](../templatelist/templatelist.md) & | The output to finalize + Parameter | Type | Description + --- | --- | --- + output | const [TemplateList](../templatelist/templatelist.md) & | The output to finalize * **output:** (void) @@ -126,13 +126,13 @@ This is a virtual function. Calls simplify on the child transform. * **function definition:** - virtual Transform *simplify(bool &newTransform) - + virtual Transform *simplify(bool &newTransform) + * **parameters:** - Parameter | Type | Description - --- | --- | --- - newTransform | bool & | True if a new, simplified, transform was allocated inside this call, false otherwise + Parameter | Type | Description + --- | --- | --- + newTransform | bool & | True if a new, simplified, transform was allocated inside this call, false otherwise * **output:** ([Transform](../transform/transform.md) \*) Returns itself if the child transform cannot be simplified. newTransform is set to false in this case. If the child can be simplified, a new WrapperTransform is allocated with the child transform set as the simplified version of the old child transform. newTransform is set to true in this case @@ -142,12 +142,12 @@ Get a smart copy, meaning a copy only if one is required, of this transform * **function definition:** - Transform *smartCopy(bool &newTransform) + Transform *smartCopy(bool &newTransform) * **parameters:** - Parameter | Type | Description - --- | --- | --- - newTransform | bool & | True if a new, simplified, transform was allocated inside this call, false otherwise + Parameter | Type | Description + --- | --- | --- + newTransform | bool & | True if a new, simplified, transform was allocated inside this call, false otherwise -* **output:** ([Transform](../transform/transform.md) \*) Returns itself if the child transform is not time varying (no copy needed). newTransform is set to false in this case. If the child is time varying make a copy by calling [smartCopy](../timevaryingtransform/functions.md#smartcopy) on the child. newTransform is set to true in this case. \ No newline at end of file +* **output:** ([Transform](../transform/transform.md) \*) Returns itself if the child transform is not time varying (no copy needed). newTransform is set to false in this case. If the child is time varying make a copy by calling [smartCopy](../timevaryingtransform/functions.md#smartcopy) on the child. newTransform is set to true in this case. diff --git a/docs/docs/api_docs/cpp_api/wrappertransform/properties.md b/docs/docs/api_docs/cpp_api/wrappertransform/properties.md index 2bfeb56..0ce085f 100644 --- a/docs/docs/api_docs/cpp_api/wrappertransform/properties.md +++ b/docs/docs/api_docs/cpp_api/wrappertransform/properties.md @@ -1,3 +1,3 @@ Property | Type | Description --- | --- | --- -transform | [Transform](../transform/transform.md) * | The child transform \ No newline at end of file +transform | [Transform](../transform/transform.md) * | The child transform diff --git a/docs/docs/contribute.md b/docs/docs/contribute.md index 6854a42..c678918 100644 --- a/docs/docs/contribute.md +++ b/docs/docs/contribute.md @@ -21,11 +21,11 @@ Some common mistakes that will stop your plugin from working! ### Documenting -Documenting your plugin is very important. OpenBR supports custom, doxygen-style, in-code comments to make documentation simple, clear, and easy. Comments should appear like +Documenting your plugin is very important. OpenBR supports custom, doxygen-style, in-code comments to make documentation simple, clear, and easy. Comments should appear like - /*! - * ... - */ + /*! + * ... + */ Comments are organized using tags, which are of the form \tag. There are a few **required** tags that all OpenBR transforms must have. @@ -39,14 +39,14 @@ Tag | Description The mimimum comment would look like this - /*! - * \ingroup abstraction group - * \brief A description of the plugin - * \author Your Name \cite Your Citation - * \br_property percentage float The percentage of something - * \br_property enum choice A choice with possible values: [choice1, choice2, choice3] - */ - + /*! + * \ingroup abstraction group + * \brief A description of the plugin + * \author Your Name \cite Your Citation + * \br_property percentage float The percentage of something + * \br_property enum choice A choice with possible values: [choice1, choice2, choice3] + */ + There are also a few **optional** tags to provide more information. Tag | Description @@ -58,18 +58,18 @@ Tag | Description Optional tags could look like this - /*! - * \br_link http://openbiometrics.org - * \br_paper Author1, Author2, Author3 - * Paper Title - * Conference. Year - * \br_related_plugin ExampleTransform ExampleDistance ExampleGallery - */ + /*! + * \br_link http://openbiometrics.org + * \br_paper Author1, Author2, Author3 + * Paper Title + * Conference. Year + * \br_related_plugin ExampleTransform ExampleDistance ExampleGallery + */ -Finally, OpenBR supports automatic linking for abstractions found in comments. For example, Transform will automatically become [Transform](api_docs/cpp_api/transform/transform.md). Plural words like Transforms will also be linked but possesives like Tranform's will not. +Finally, OpenBR supports automatic linking for abstractions found in comments. For example, Transform will automatically become [Transform](api_docs/cpp_api/transform/transform.md). Plural words like Transforms will also be linked but possesives like Tranform's will not. --- - + ## Contributing to the API You should contribute to the API if you want to add a new abstraction or extend an existing abstraction with new functionality. Please note, this occurs *very* *very* rarely. Our goal is to leave the core API as stable and consistent as possible and change only the surrounding plugins. If you believe your idea offers exciting new functionality or greatly increases efficiency please [open an issue](https://github.com/biometrics/openbr/issues) so that it can be discussed as a community. @@ -125,4 +125,4 @@ Use `static` function declarations whenever possible but `static` variables spar } ### Indentation -4 spaces, no tabs. \ No newline at end of file +4 spaces, no tabs. diff --git a/docs/docs/papers.md b/docs/docs/papers.md deleted file mode 100644 index fe5faa8..0000000 --- a/docs/docs/papers.md +++ /dev/null @@ -1,23 +0,0 @@ -# Related Publications - -Please consider adding your OpenBR-related publication to this list by [submitting a pull request!](https://github.com/biometrics/openbr/pulls). - ---- - -## 2015 - ---- - -## 2014 - ---- - -## 2013 - ---- - -## 2012 - ---- - -## 2011 diff --git a/docs/docs/tutorials.md b/docs/docs/tutorials.md index bab9b09..aed02af 100644 --- a/docs/docs/tutorials.md +++ b/docs/docs/tutorials.md @@ -82,23 +82,23 @@ One of the first steps when converting the template enrollment description into After operator expansion, the template enrollment description forms a tree, and the transform is constructed from this description starting recursively starting at the root of the tree: - Transform *transform = Factory::make("." + str); + Transform *transform = Factory::make("." + str); Let's use the algorithm in ```scripts/helloWorld.sh``` as an example. The algorithm is: - Open+Cvt(Gray)+Cascade(FrontalFace)+ASEFEyes+Affine(128,128,0.33,0.45)+CvtFloat+PCA(0.95):Dist(L2) + Open+Cvt(Gray)+Cascade(FrontalFace)+ASEFEyes+Affine(128,128,0.33,0.45)+CvtFloat+PCA(0.95):Dist(L2) So what is happening here? Let's expand this using our new knowledge of OpenBR's algorithm syntax. First, the algorithm will be split into enrollment and comparison portions at the **:**. So enrollment becomes- - Open+Cvt(Gray)+Cascade(FrontalFace)+ASEFEyes+Affine(128,128,0.33,0.45)+CvtFloat+PCA(0.95) + Open+Cvt(Gray)+Cascade(FrontalFace)+ASEFEyes+Affine(128,128,0.33,0.45)+CvtFloat+PCA(0.95) and comparison is- - Dist(L2) + Dist(L2) On the enrollment side the **+'s** are converted into a [PipeTransform](api_docs/plugins/core.md#pipetransform) with the other plugins as children. Enrollment is transformed to - Pipe(transforms=[Open,Cvt(Gray),Cascade(FrontalFace),ASEFEyes,Affine(128,128,0.33,0.45,CvtFloat,PCA(0.95)]) + Pipe(transforms=[Open,Cvt(Gray),Cascade(FrontalFace),ASEFEyes,Affine(128,128,0.33,0.45,CvtFloat,PCA(0.95)]) If you want all the tedious details about what exactly this algoritm does, then you should read the [project](api_docs/cpp_api/transform/functions.md#project-1) function implemented by each of these plugins. The brief explanation is that it *reads the image from disk, converts it to grayscale, runs the face detector, runs the eye detector on any detected faces, uses the eye locations to normalize the face for rotation and scale, converts to floating point format, and then embeds it in a PCA subspaced trained on face images*. @@ -133,48 +133,48 @@ This tutorial gives an example on how to perform face recognition in OpenBR. Ope To start, lets run face recognition from the command line. Open the terminal and enter - $ br -algorithm FaceRecognition \ - -compare ../data/MEDS/img/S354-01-t10_01.jpg ../data/MEDS/img/S354-02-t10_01.jpg \ - -compare ../data/MEDS/img/S354-01-t10_01.jpg ../data/MEDS/img/S386-04-t10_01.jpg + $ br -algorithm FaceRecognition \ + -compare ../data/MEDS/img/S354-01-t10_01.jpg ../data/MEDS/img/S354-02-t10_01.jpg \ + -compare ../data/MEDS/img/S354-01-t10_01.jpg ../data/MEDS/img/S386-04-t10_01.jpg Easy enough? You should see results printed to terminal that look like - $ Set algorithm to FaceRecognition - $ Loading /usr/local/share/openbr/models/algorithms/FaceRecognition - $ Loading /usr/local/share/openbr/models/transforms//FaceRecognitionExtraction - $ Loading /usr/local/share/openbr/models/transforms//FaceRecognitionEmbedding - $ Loading /usr/local/share/openbr/models/transforms//FaceRecognitionQuantization - $Comparing ../data/MEDS/img/S354-01-t10_01.jpg and ../data/MEDS/img/S354-02-t10_01.jpg - $ Enrolling ../data/MEDS/img/S354-01-t10_01.jpg to S354-01-t10_01r7Rv4W.mem - $ 100.00% ELAPSED=00:00:00 REMAINING=00:00:00 COUNT=1 - $ 100.00% ELAPSED=00:00:00 REMAINING=00:00:00 COUNT=1 - $ 1.8812 - $ Comparing ../data/MEDS/img/S354-01-t10_01.jpg and ../data/MEDS/img/S386-04-t10_01.jpg - $ Enrolling ../data/MEDS/img/S354-01-t10_01.jpg to S354-01-t10_01r7Rv4W.mem - $ 100.00% ELAPSED=00:00:00 REMAINING=00:00:00 COUNT=1 - $ 100.00% ELAPSED=00:00:00 REMAINING=00:00:00 COUNT=1 - $ 0.571219 + $ Set algorithm to FaceRecognition + $ Loading /usr/local/share/openbr/models/algorithms/FaceRecognition + $ Loading /usr/local/share/openbr/models/transforms//FaceRecognitionExtraction + $ Loading /usr/local/share/openbr/models/transforms//FaceRecognitionEmbedding + $ Loading /usr/local/share/openbr/models/transforms//FaceRecognitionQuantization + $Comparing ../data/MEDS/img/S354-01-t10_01.jpg and ../data/MEDS/img/S354-02-t10_01.jpg + $ Enrolling ../data/MEDS/img/S354-01-t10_01.jpg to S354-01-t10_01r7Rv4W.mem + $ 100.00% ELAPSED=00:00:00 REMAINING=00:00:00 COUNT=1 + $ 100.00% ELAPSED=00:00:00 REMAINING=00:00:00 COUNT=1 + $ 1.8812 + $ Comparing ../data/MEDS/img/S354-01-t10_01.jpg and ../data/MEDS/img/S386-04-t10_01.jpg + $ Enrolling ../data/MEDS/img/S354-01-t10_01.jpg to S354-01-t10_01r7Rv4W.mem + $ 100.00% ELAPSED=00:00:00 REMAINING=00:00:00 COUNT=1 + $ 100.00% ELAPSED=00:00:00 REMAINING=00:00:00 COUNT=1 + $ 0.571219 So what is 'FaceRecognition'? It's an abbrieviation to make running the algorithm easier. All of the algorithm abbreviations are located in ```openbr/plugins/core/algorithms.cpp```, please see the previous tutorial for an introduction to OpenBR's algorithm grammar. It also possible to perform face recognition evaluation (**note:** this requires [R][R] to be installed)- - $ br -algorithm FaceRecognition -path ../data/MEDS/img/ \ - -enroll ../data/MEDS/sigset/MEDS_frontal_target.xml target.gal \ - -enroll ../data/MEDS/sigset/MEDS_frontal_query.xml query.gal \ - -compare target.gal query.gal scores.mtx \ - -makeMask ../data/MEDS/sigset/MEDS_frontal_target.xml ../data/MEDS/sigset/MEDS_frontal_query.xml MEDS.mask \ - -eval scores.mtx MEDS.mask Algorithm_Dataset/FaceRecognition_MEDS.csv \ - -plot Algorithm_Dataset/FaceRecognition_MEDS.csv MEDS + $ br -algorithm FaceRecognition -path ../data/MEDS/img/ \ + -enroll ../data/MEDS/sigset/MEDS_frontal_target.xml target.gal \ + -enroll ../data/MEDS/sigset/MEDS_frontal_query.xml query.gal \ + -compare target.gal query.gal scores.mtx \ + -makeMask ../data/MEDS/sigset/MEDS_frontal_target.xml ../data/MEDS/sigset/MEDS_frontal_query.xml MEDS.mask \ + -eval scores.mtx MEDS.mask Algorithm_Dataset/FaceRecognition_MEDS.csv \ + -plot Algorithm_Dataset/FaceRecognition_MEDS.csv MEDS face recognition search- - $ br -algorithm FaceRecognition -enrollAll -enroll ../data/MEDS/img 'meds.gal;meds.csv[separator=;]' - $ br -algorithm FaceRecognition -compare meds.gal ../data/MEDS/img/S001-01-t10_01.jpg match_scores.csv + $ br -algorithm FaceRecognition -enrollAll -enroll ../data/MEDS/img 'meds.gal;meds.csv[separator=;]' + $ br -algorithm FaceRecognition -compare meds.gal ../data/MEDS/img/S001-01-t10_01.jpg match_scores.csv and face recognition training- - $ br -algorithm 'Open+Cvt(Gray)+Cascade(FrontalFace)+ASEFEyes+Affine(128,128,0.33,0.45)+(Grid(10,10)+SIFTDescriptor(12)+ByRow)/(Blur(1.1)+Gamma(0.2)+DoG(1,2)+ContrastEq(0.1,10)+LBP(1,2)+RectRegions(8,8,6,6)+Hist(59))+PCA(0.95)+Normalize(L2)+Dup(12)+RndSubspace(0.05,1)+LDA(0.98)+Cat+PCA(0.95)+Normalize(L1)+Quantize:NegativeLogPlusOne(ByteL1)' -train ../data/ATT/img FaceRecognitionATT + $ br -algorithm 'Open+Cvt(Gray)+Cascade(FrontalFace)+ASEFEyes+Affine(128,128,0.33,0.45)+(Grid(10,10)+SIFTDescriptor(12)+ByRow)/(Blur(1.1)+Gamma(0.2)+DoG(1,2)+ContrastEq(0.1,10)+LBP(1,2)+RectRegions(8,8,6,6)+Hist(59))+PCA(0.95)+Normalize(L2)+Dup(12)+RndSubspace(0.05,1)+LDA(0.98)+Cat+PCA(0.95)+Normalize(L1)+Quantize:NegativeLogPlusOne(ByteL1)' -train ../data/ATT/img FaceRecognitionATT all right from the command line! The entire command line API is documented [here](api_docs/cl_api.md). It is a powerful tool for creating and testing new algorithms. @@ -182,38 +182,38 @@ The command line isn't perfect for all situations however. So OpenBR exposes a [ Our main function starts with- - br::Context::initialize(argc, argv) + br::Context::initialize(argc, argv) This is the first step in any OpenBR application, it initializes the global context. - QSharedPointer transform = br::Transform::fromAlgorithm("FaceRecognition"); + QSharedPointer transform = br::Transform::fromAlgorithm("FaceRecognition"); QSharedPointer distance = br::Distance::fromAlgorithm("FaceRecognition"); Here, we split our algorithm into *enrollment* ([Transform](api_docs/cpp_api/transform/transform.md)::[fromAlgorithm](api_docs/cpp_api/transform/statics.md#fromalgorithm)) and *comparison* ([Distance](api_docs/cpp_api/distance/distance.md)::[fromAlgorithm](api_docs/cpp_api/distance/statics.md#fromalgorithm)) - br::Template queryA("../data/MEDS/img/S354-01-t10_01.jpg"); + br::Template queryA("../data/MEDS/img/S354-01-t10_01.jpg"); br::Template queryB("../data/MEDS/img/S382-08-t10_01.jpg"); br::Template target("../data/MEDS/img/S354-02-t10_01.jpg"); These lines create our [Templates](api_docs/cpp_api/template/template.md) for enrollment. They are just images loaded from disk. For this example queryA is the same person (different picture) as target and queryB is a different person. - queryA >> *transform; + queryA >> *transform; queryB >> *transform; target >> *transform; And now we enroll them! **>>** is a convienience operator for enrolling [Templates](api_docs/cpp_api/template/template.md) in [Transforms](api_docs/cpp_api/transform/transform.md). The enrollment is done in-place, which means the output overwrites the input. Our [Templates](api_docs/cpp_api/template/template.md) now store the results of enrollment. - float comparisonA = distance->compare(target, queryA); + float comparisonA = distance->compare(target, queryA); float comparisonB = distance->compare(target, queryB); Compare our query [Templates](api_docs/cpp_api/template/template.md) against the target [Template](api_docs/cpp_api/template/template.md). The result is a float. - printf("Genuine match score: %.3f\n", comparisonA); + printf("Genuine match score: %.3f\n", comparisonA); printf("Impostor match score: %.3f\n", comparisonB); Print out our results. You can see that comparisonA (between queryA and target) has a higher score then comparisonB, which is exactly what we expect! - br::Context::finalize(); + br::Context::finalize(); The last line in any OpenBR application has to be call to finalize. This shuts down OpenBR. @@ -251,8 +251,8 @@ The source code to run gender estimation as an application is in ```app/examples [^1]: *Matthew Turk and Alex Pentland.* - **Eigenfaces for recognition.** - Journal of Cognitive Neuroscience, 71-86, 1991 + **Eigenfaces for recognition.** + Journal of Cognitive Neuroscience, 71-86, 1991 [^2]: *B. Klare.* - **Spectrally sampled structural subspace features (4SF).** - In Michigan State University Technical Report, MSUCSE-11-16, 2011 + **Spectrally sampled structural subspace features (4SF).** + In Michigan State University Technical Report, MSUCSE-11-16, 2011 diff --git a/docs/scripts/check_format_cpp.py b/docs/scripts/check_format_cpp.py deleted file mode 100644 index e69de29..0000000 --- a/docs/scripts/check_format_cpp.py +++ /dev/null diff --git a/docs/scripts/generate_api_class_doc.py b/docs/scripts/generate_api_class_doc.py deleted file mode 100644 index c096570..0000000 --- a/docs/scripts/generate_api_class_doc.py +++ /dev/null @@ -1,187 +0,0 @@ -# This script is intended to take an API-style class from OpenBR and output -# structured Markdown text in the OpenBR documentation format. The class details -# should then be filled in. - -import sys -import re - -def find_name_parent(content): - name_re = re.compile('class(.*?):') - name = name_re.search(content).group()[:-1].strip().split(' ')[-1] - - parent_re = re.compile('public.*') - parent = parent_re.search(content).group().strip().split(' ')[-1] - - return name, parent - -def find_properties(content): - properties = [] - - property_re = re.compile('Q_PROPERTY\((.*?)\)') - it = property_re.finditer(content) - for prop in it: - prop_type = prop.group()[11:-1].split(' ')[0] - prop_name = prop.group()[11:-1].split(' ')[1] - properties.append((prop_name, prop_type)) - - return properties - -def find_members(content): - members = [] - - member_re = re.compile('(\w+(<\w+>)*)\s(\w+);') - it = member_re.finditer(content) - for member in it: - member_type = member.group()[:-1].strip().split(' ')[0] - member_name = member.group()[:-1].strip().split(' ')[1] - members.append((member_name, member_type)) - - return members - -def find_constructors(name, content): - constructors = [] - - constructor_re = re.compile('(.*)' + name + '\(\)') - it = constructor_re.finditer(content) - for constructor in it: - constructors.append(constructor.group().strip()) - - return constructors - -def find_functions(content): - functions = [] - - function_re = re.compile('(.*)[^PROPERTY]\(.*\).*;') - it = function_re.finditer(content) - for func in it: - function = {} - - function['Full'] = func.group()[:-1].strip() #don't include semi colon - - func_split = func.group().strip().split(' ') - if func_split[0] == "static": - function['Type'] = 'static' - function['Return'] = func_split[1] - function['Name'] = func_split[2].split('(')[0] - elif func_split[0] == "virtual": - function['Type'] = 'virtual' - function['Return'] = func_split[1] - function['Name'] = func_split[2].split('(')[0] - else: - function['Type'] = 'normal' - function['Return'] = func_split[0] - function['Name'] = func_split[1].split('(')[0] - - args = [] - - args_list = func.group()[func.group().find('(')+1:func.group().find(')')].split(',') - for arg in args_list: - arg = arg.strip() - split_idx = arg.rfind(' ') - if arg[split_idx:].strip()[0] == '*' or arg[split_idx:].strip()[0] == '&': - split_idx += 2 - - args.append((arg[split_idx:].strip(), arg[:split_idx].strip())) - - function['Args'] = args - - functions.append(function) - - return functions - -def parse(content): - name, parent = find_name_parent(content) - properties = find_properties(content) - members = find_members(content) - constructors = find_constructors(name, content) - functions = find_functions(content) - - return name, parent, properties, members, constructors, functions - -def function_builder(name, function): - markdown = "" - - markdown += "### " + function["Full"] + " {: #" + name.lower() + "-function-" + function['Name'].lower() + "}\n\n" - markdown += "DOCUMENT ME\n\n" - - markdown += "* **function definition:**\n\n" - markdown += "\t\t" + function['Full'] + "\n\n" - - markdown += "* **parameters:**" - if len(function['Args']) == 0: - markdown += " NONE\n" - else: - markdown += "\n\n" - markdown += "\tParameter | Type | Description\n" - markdown += "\t--- | --- | ---\n" - for arg in function['Args']: - markdown += "\t" + arg[0] + " | " + arg[1] + " | DOCUMENT ME\n" - markdown += "\n" - - markdown += "* **output:** (" + function['Return'] + ") DOCUMENT ME\n\n\n" - - return markdown - -def format_md(name, parent, properties, members, constructors, functions): - markdown = "" - - markdown += "# " + name + "\n\n" - markdown += "Inherits from [" + parent + "](#" + parent.lower() + ")\n\n" - - markdown += "## Properties {: #" + name.lower() + "-properties }\n\n" - if len(properties) == 0: - markdown += "NONE\n\n" - else: - markdown += "Property | Type | Description\n" - markdown += "--- | --- | ---\n" - for prop in properties: - markdown += '' - markdown += prop[0] + " | " + prop[1] + " | DOCUMENT ME\n" - markdown += "\n" - - markdown += "## Members {: #" + name.lower() + "-members }\n\n" - if len(members) == 0: - markdown += "NONE\n\n" - else: - markdown += "Member | Type | Description\n" - markdown += "--- | --- | ---\n" - for member in members: - markdown += '' - markdown += member[0] + " | " + member[1] + " | DOCUMENT ME\n" - markdown += "\n" - - markdown += "## Constructors {: #" + name.lower() + "-constructors }\n\n" - if len(constructors) == 0: - markdown += "NONE\n\n" - else: - markdown += "Constructor \| Destructor | Description\n" - markdown += "--- | ---\n" - for constructor in constructors: - markdown += constructor + " | DOCUMENT ME\n" - markdown += "\n" - - markdown += "## Static Functions {: #" + name.lower() + "-static-functions }\n\n" - for function in functions: - if function['Type'] == 'static': - markdown += function_builder(name, function) - - markdown += "## Functions {: #" + name.lower() + "-functions }\n\n" - for function in functions: - if not function['Type'] == 'static': - markdown += function_builder(name, function) - - return markdown - -def main(): - if len(sys.argv) != 3: - print 'Inputs => class documentation' - sys.exit(1) - - class_file = open(sys.argv[1], 'r') - doc_file = open(sys.argv[2], 'w+') - - name, parent, properties, members, constructors, functions = parse(class_file.read()) - - doc_file.write(format_md(name, parent, properties, members, constructors, functions)) - -main() diff --git a/docs/scripts/generate_plugin_docs.py b/docs/scripts/generate_plugin_docs.py index 1bba1f3..af26065 100644 --- a/docs/scripts/generate_plugin_docs.py +++ b/docs/scripts/generate_plugin_docs.py @@ -95,7 +95,7 @@ def parseLinks(links): if len(links) > 1: output += "\n\n" for link in links: - output += "\t* [" + link + "](" + link + ")\n" + output += " * [" + link + "](" + link + ")\n" output += "\n" else: output += " [" + links[0] + "](" + links[0] + ")\n" @@ -117,11 +117,11 @@ def parsePapers(papers): if len(info) >= 3: other = info[2].strip() - output += "\t" + str(i+1) + ". *" + authors + "*\n" + output += " " + str(i+1) + ". *" + authors + "*\n" if title: - output += "\t **" + title + "**\n" + output += " **" + title + "**\n" if other: - output += "\t " + other + "\n" + output += " " + other + "\n" output += "\n" return output @@ -148,8 +148,8 @@ def parseProperties(properties): return "* **properties:** None\n\n" output = "* **properties:**\n\n" - output += "\tProperty | Type | Description\n" - output += "\t--- | --- | ---\n" + output += " Property | Type | Description\n" + output += " --- | --- | ---\n" for prop in properties: split = prop.split(' ') ty = split[0] @@ -172,7 +172,7 @@ def parseProperties(properties): desc = before.strip() + table + after.strip() table_match = table_regex.search(desc) - output += "\t" + name + " | " + ty + " | " + desc + "\n" + output += " " + name + " | " + ty + " | " + desc + "\n" return output