Failure mechanics of snow layers through image analysis