Updated on 2022-02-22 GMT+08:00

Initializing

This API is used to construct a hard example filter.

  • API calling

    hilens.HardSample(threshold_one, threshold_two, filter_type)

  • Parameter description
    Table 1 Parameters

    Parameter

    Mandatory

    Type

    Description

    threshold_one

    Yes

    float

    Threshold. The value varies depending on the value of filter_type.

    threshold_two

    Yes

    float

    Threshold. The value varies depending on the value of filter_type.

    filter_type

    Yes

    int

    Type of a hard example filter. Possible values are 0, 1, and 2, which correspond to CrossEntropyFilter, IBT, and CSF, respectively. For details, see Introduction to Hard Example Upload.

    • If the value is 0, threshold_one corresponds to threshold_cross_entropy of CrossEntropyFilter, and threshold_two can be any value.
    • If the value is 1, threshold_one and threshold_two correspond to box_threshold and img_threshold of IBT, respectively.
    • If the value is 2, threshold_one and threshold_two correspond to box_threshold_low and box_threshold_up of CSF, respectively.
  • Return value

    A hard example filter. If the construction fails, an exception is thrown.