One way is create a 3D scene in ArcGIS Pro and add your DSM as an elevation layer. Create an empty line feature class that is z-aware, and begin digitizing your path. Use the Elevation tools on the Edit tab to specify a z-value for the path as you draw (the DSM).