SpectacularAI / sdk-examples

Spectacular AI SDK examples
Apache License 2.0
216 stars 34 forks source link

The sdk problem is not writing the file, I can't figure out why( #126

Closed Lindsaydoodle closed 8 months ago

Lindsaydoodle commented 9 months ago

image As you can see, the script does not write finished at the end. And only the images subfolder appears in the folder and that's it(

H-tr commented 9 months ago

same here

oseiskar commented 9 months ago

Thank you for reporting. That is a sign of the tool failing and for some reason, the error message is not shown. We'll check.

In the meantime: Does this happen with all recordings and also without --preview3d? How about other SDK versions, e.g., pip install spectacularAI==1.26.2?

kaatrasa commented 9 months ago

I was able to reproduce the issue, and there will be a fix in the next patch release.

For now, could you either use previous version of spectacularAI pypi package or make sure that the sai-cli output directory is using the same disk as the Python's tempfile.mkdtemp(); On Windows it was C: drive for me.

Lindsaydoodle commented 9 months ago

Yes, everything is on the same disk С:\ sai-cli process \data --preview3d \done

kaatrasa commented 9 months ago

Alright, it is possible that you are running into a separate issue then.

The source code for the sai-cli process tool is publicly available here: https://github.com/SpectacularAI/sdk/blob/main/python/cli/process/process.py and it already includes the fix I mentioned. If you want to test it, just run python process.py \data --preview3d \done

Debugging is a little hard currently, because it looks like the Python script is crashing, but it doesn't print any stacktrace on Windows (we will try to add the stacktrace for next release).

H-tr commented 9 months ago

Hi, thanks for your reply. I tried using python process.py \data --preview3d \done as you suggest. it worked! However, the pointcloud seems not in the correct format. I got this error:

RPly: Unexpected end of file
RPly: Error reading 'x' of 'vertex' number 29406
[Open3D WARNING] Read PLY failed: unable to read file: /mnt/d/Datasets/gs-recon/yunnan_gardan/sparse_pc.ply
RPly: Unexpected end of file
RPly: Error reading 'x' of 'vertex' number 29406
[Open3D WARNING] Read PLY failed: unable to read file: /mnt/d/Datasets/gs-recon/yunnan_gardan/sparse_pc.ply

As I checked your ply file, I found it is just like the txt file. Do you think save it using plyfile or open3d is a better idea? Should I open a new issue for it?

oseiskar commented 9 months ago

That is an unrelated issue and you can open a new ticket. That is related to the Nerfstudio file formats changing between versions 0.9 and 1.0. Support for new format will be released with our next SDK version and code related to this has already been merged to the main branch of the sdk repository.

Do you get that error from Nerftsudio or some other tool? Note that PLY files have two subtypes, ASCII and binary, and all tools do not support both formats.

H-tr commented 9 months ago

I got the error from nerfstudio. Thanks for ur reply, I'll try later.

kaatrasa commented 9 months ago

Release 1.29.0 is now public, if you update the pypi package pip install spectacularai[full] --force then you can use the sai-cli tool again.