Ion beam profiling from the interaction with a freestanding 2D layer