Function gbdt::input::infer

source · []
pub fn infer(file_name: &str) -> InputFormat
Expand description

Function used for input file type inference. This can help recognize the file format. If the file is in csv type, this function also helps to check whether the csv file has header.

Example

use gbdt::input::infer;
let train_file = "dataset/iris/train.txt";
let fmt = infer(train_file);
println!("{}", fmt.to_string());