mirror of
https://github.com/nerfstudio-project/nerfstudio.git
synced 2026-12-07 00:09:14 +08:00
Check is metashape xml is present (#1044)
This commit is contained in:
1 parent
6c805b6d33
commit
666b43a577
1 file changed
+5
@@ -546,6 +546,11 @@ class ProcessMetashape:
|
|||||||
def main(self) -> None:
|
def main(self) -> None:
|
||||||
"""Process images into a nerfstudio dataset."""
|
"""Process images into a nerfstudio dataset."""
|
||||||
|
|
||||||
|
if self.xml.suffix != ".xml":
|
||||||
|
raise ValueError(f"XML file {self.xml} must have a .xml extension")
|
||||||
|
if not self.xml.exists:
|
||||||
|
raise ValueError(f"XML file {self.xml} doesn't exist")
|
||||||
|
|
||||||
self.output_dir.mkdir(parents=True, exist_ok=True)
|
self.output_dir.mkdir(parents=True, exist_ok=True)
|
||||||
image_dir = self.output_dir / "images"
|
image_dir = self.output_dir / "images"
|
||||||
image_dir.mkdir(parents=True, exist_ok=True)
|
image_dir.mkdir(parents=True, exist_ok=True)
|
||||||
|
|||||||
Reference in new issue
Block a user