pub fn try_init<P: AsRef<Path>>(path: P) -> Result<(), ProfilingError>
Initialize the profiler and set output path.