[pnm] Improve parameter handling for Grid.NumPores and use same type

5 jobs for !2800 with feature/porenetwork-numpores-parameter
latest merge request