You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: advanced-train-loop.rs
    path of file: ./repos/dfdx/dfdx/examples
    
    the code of the file until where you have to start completion: /// This advanced example shows how to work with dfdx in a generic
/// training setting.
use dfdx::prelude::*;

/// Our generic training function. Works with any model/optimizer/loss function!
fn classification_train<
    // The input to our network, si
    
fn main() {
    let dev = AutoDevice::default();

    type Model = LinearConstConfig<10, 2>;
    type Dtype = f32;
    let mut model = dev.build_module::<Dtype>(Model::default());
    let mut opt = dfdx::nn::optim::Sgd::new(&model, Default::default());

    // just some random data
    let mut data = Vec::new();
    for _ in 0..100 {
        let inp = dev.sample_normal::<Rank2<5, 10>>();
        let lbl = dev.tensor([[0.0, 1.0]; 5]);
        data.push((inp, lbl));
    }

    classification_train(
        &mut model,
        &mut opt,
        cross_entropy_with_logits_loss,
        data.into_iter(),
        1,
    )
    .unwrap();
}