The forces are exerted on every atom. The stress is exerted on the cell lattice. The average of stress is usually taken over the diagonal terms (i.e., sigma_11, sigma_22, sigma_33). This average of stress gives the pressure on the cell lattice.
After the geometry optimization, the forces on atoms and the stress on cell should converge to a threshold value (specified by the user in the geometry optimization).
"How to calculate the average vale of forces and stress."
So, your question is hard to be understood.