Raise error if file doesn't exist
- Dominant language
- C++
- Stars
- 14k
- Forks
- 2.6k
- Avg merge
- 5d 18h
- Merged PRs (30d)
- 6
Description
**Describe the bug**
Currently `read_pinhole_camera_intrinsic` doesn't raise an error if the file doesn't exist. Instead, it loads default values (array of zeros). This may lead to unexpected errors.
**To Reproduce**
Steps to reproduce the behavior:
1.Make sure that there is no intrinsics.json in run directory.
2. `intrinsic = o3d.io.read_pinhole_camera_intrinsic("intrinsics.json")`
3. intrinsic parameters will be filled with zeros.
**Expected behavior**
Raise an error if the file doesn't exist.
**Environment (please complete the following information):**
- Operating system: Ubuntu 20
- Python version: Python 3.8
- Open3D version: open3d-0.11.2
- Is this remote workstation?: no
- How did you install Open3D?: (e.g. pip, conda, build from source) pip
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.