build lattice