We present an analysis of Spitzer-IRS spectroscopic maps of the L1157 protostellar outflow in the H2 pure-rotational lines from S(0) to S(7). The aim of this work is to derive the physical conditions pertaining to the warm molecular gas and study their variations within the flow. The mid-IR H2 emission follows the morphology of the precessing flow, with peaks correlated with individual CO clumps and H2 2.12{mu}m ro-vibrational emission. More diffuse emission delineating the CO cavities is detected only in the low-laying transitions, with J(lower) less or equal to 2. The H2 line images have been used to construct 2D maps of N(H2), H2 ortho-to-para ratio and temperature spectral index beta, in the assumption of a gas temperature stratification where the H2 column density varies as T^(beta). Variations of these parameters are observed along the flow. In particular, the ortho-to-para ratio ranges from 0.6 to 2.8, highlighting the presence of regions subject to recent shocks where the ortho-to-para ratio has not had time yet to reach the equilibrium value. Near-IR spectroscopic data on ro-vibrational H2 emission have been combined with the mid-IR data and used to derive additional shock parameters in the brightest blue- and red-shifted emission knots. A high abundance of atomic hydrogen (H/H2 about 0.1-0.3) is implied by the observed H2 column densities, assuming n(H2) values as derived by independent SiO observations. The presence of a high fraction of atomic hydrogen, indicates that a partially-dissociative shock component should be considered for the H2 excitation in these localized regions. However, planar shock models, either of C- or J-type, are not able to consistently reproduce all the physical parameters derived from our analysis of the H2 emission. Globally, H2 emission contributes to about 50% of the total shock radiated energy in the L1157 outflow.