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: mesh.rs
    path of file: ./repos/amethyst/amethyst_gltf/src/importer
    
    the code of the file until where you have to start completion: use std::{iter::repeat, ops::Range};

use amethyst_assets::error::Error;
use amethyst_core::math::{zero, Vector3};
use amethyst_rendy::{
    rendy::me
    
fn calculate_normals(positions: &[Position], indices: &Indices) -> Vec<Normal> {
    let mut normals = vec![zero::<Vector3<f32>>(); positions.len()];
    let num_faces = indices.len().unwrap_or_else(|| positions.len()) / 3;
    for face in 0..num_faces {
        let i0 = indices.map(face, 0);
        let i1 = indices.map(face, 1);
        let i2 = indices.map(face, 2);
        let a = Vector3::from(positions[i0].0);
        let b = Vector3::from(positions[i1].0);
        let c = Vector3::from(positions[i2].0);
        let n = (b - a).cross(&(c - a));
        normals[i0] += n;
        normals[i1] += n;
        normals[i2] += n;
    }
    normals
        .into_iter()
        .map(|n| Normal(n.normalize().into()))
        .collect::<Vec<_>>()
}