The state of granular media can be represented by a persistence diagram. This representation provides an interesting insight into the physical properties of the granular media as demonstrated on a system undergoing compression. Time evolution of the system can be seen as a curve in the space of persistence diagrams. Different notions of distance in this space provide a useful tool for understanding the dynamic. In particular the compressed systems (viewed as a discrete dynamical system) exhibit a few different regimes where dynamics changes from fast to slow. Dependence of the system on its previous state is strongly affected by the sampling rate. We conclude the talk by addressing the problem of determining the 'appropriate' sampling rate.