Struct crfsuite_sys::tag_crfsuite_trainer [] [src]

#[repr(C)]
pub struct tag_crfsuite_trainer { pub internal: *mut c_void, pub nref: c_int, pub addref: Option<unsafe extern "C" fn(trainer: *mut crfsuite_trainer_t) -> c_int>, pub release: Option<unsafe extern "C" fn(trainer: *mut crfsuite_trainer_t) -> c_int>, pub params: Option<unsafe extern "C" fn(trainer: *mut crfsuite_trainer_t) -> *mut crfsuite_params_t>, pub set_message_callback: Option<unsafe extern "C" fn(trainer: *mut crfsuite_trainer_t, user: *mut c_void, cbm: crfsuite_logging_callback)>, pub train: Option<unsafe extern "C" fn(trainer: *mut crfsuite_trainer_t, data: *const crfsuite_data_t, filename: *const c_char, holdout: c_int) -> c_int>, }

CRFSuite trainer interface.

Fields

Pointer to the internal data (internal use only).

Reference counter (internal use only).

Increment the reference counter.

trainer The pointer to this trainer instance.

Returns the reference count after this increment.

Decrement the reference counter.

trainer The pointer to this trainer instance.

Returns the reference count after this operation.

Obtain the pointer to crfsuite_params_t interface.

trainer The pointer to this trainer instance.

Returns crfsuite_params_t* The pointer to crfsuite_params_t.

Set the callback function and user-defined data.

  • trainer The pointer to this trainer instance.
  • user The pointer to the user-defined data.
  • cbm The pointer to the callback function.

Start a training process.

  • trainer The pointer to this trainer instance.
  • data The poiinter to the data set.
  • filename The filename to which the trainer stores the model. If an empty string is specified, this function does not sture the model to a file.
  • holdout The holdout group.

Returns the status code.

Trait Implementations

impl Debug for tag_crfsuite_trainer
[src]

[src]

Formats the value using the given formatter. Read more

impl Copy for tag_crfsuite_trainer
[src]

impl Clone for tag_crfsuite_trainer
[src]

[src]

Returns a copy of the value. Read more

1.0.0
[src]

Performs copy-assignment from source. Read more

Auto Trait Implementations