You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
with open("path/to/svo.svo", "rb") as svo_file_obj:
init_params = sl.InitParameters()
init_params.set_from_svo_file(svo_file_obj)
My request is to modify set_from_svo_file() to accept file objects, not just paths to files.
Use-Case
This is extremely useful when SVO files are stored remotely. For example, I record SVO files on a computationally limited device, then save the SVO files to S3. Many Python libraries (including Numpy, Pandas, and PyAV) can read/write files directly from S3 like so
import fsspec
fs = fsspec.filesystem("filecache", target_protocol="s3")
with fs.open("s3://bucket/path/to/numpy/archive.npz", "rb") as numpy_archive:
numpy_data = np.load(npz)
This is very convenient in two ways:
I (the user) don't have to download files I need ahead of time
Numpy maintainers don't have to write any s3 specific code. They add ~5 lines to the start of their functions involving files and suddenly they support every blob store under the sun.
I currently download SVO files before processing them, but I work with all other files (mp4, csv, ...) directly in s3.
Anything else?
I don't think SVO streaming solves my problem, since S3 servers aren't going to run ZED-specific code.
The text was updated successfully, but these errors were encountered:
Preliminary Checks
Proposal
Currently, pyzed functions involving files require a path to a file physically on disk. For example, the following code is valid:
However, this chunk of code is not
My request is to modify set_from_svo_file() to accept file objects, not just paths to files.
Use-Case
This is extremely useful when SVO files are stored remotely. For example, I record SVO files on a computationally limited device, then save the SVO files to S3. Many Python libraries (including Numpy, Pandas, and PyAV) can read/write files directly from S3 like so
This is very convenient in two ways:
I currently download SVO files before processing them, but I work with all other files (mp4, csv, ...) directly in s3.
Anything else?
I don't think SVO streaming solves my problem, since S3 servers aren't going to run ZED-specific code.
The text was updated successfully, but these errors were encountered: