cannot convert svo to avi

Dear community,

I am trying to convert some svo files to avi. I have been trying to do it using the “” file provided in the zed-sdk. It works perfectly on the sample svo files made available by stereolabs. However, I have an error when I try with my own videos.

My videos were collected in 2020 using Zed Mini and can be played on zed player with no error. I think that this is an indication that the files are not corrupted. I tried anyway to repair the svo file using “ZED SVOEditor.exe”. But again, the repaired files cannot be converted to avi.

I explain the steps I follow together with the outputs I receive below. I also attach a sample short video for enabling reproduction.

I use this command in anaconda prompt:

python --mode 0 --input_svo_file output_trawl.svo --output_avi_file output_trawl_avi.avi

After I run the command, it waits for a while and the loading bar suddenly pops as 100% (i.e. without showing the progress at all). After that, an avi file is generated. But it is just an 18kb file with no information at all.

My zed-sdk version: 4.1.1
Link to my sample svo file: output_trawl.svo - Google Drive
Any suggestions are highly appreciated.

Hi @ercan,

Welcome to the Stereolabs forums :slight_smile:

We provide the equivalent sample in C++, would it be possible for you to test it as well? To see if the problem is localized only to the python sample.

Hi @mattrouss
I haven’t used C++ for a while and do not have any required tools (e.g. cmake or visual studio) intalled on my computer right now. I may end up spending many hours just to setup a working environment for C++ on my device.
I already provided a link to a sample video of mine. Would you mind trying it on behalf of me if you have the C++ ready on your computer?
As an extra information, I tried on one of my colleagues computer (with python) but the still having the same problem.

I have verified that the export fails with both python and cpp version of the sample exporter, producing an ~18kb avi file. both work correctly with a zed2i svo captured locally.

According to info from @multicore-manticore, there seems to be two options:
1- My svo file is corrupted in a strange way that it cannot be converted to avi.
I think this option is less likely to be true because it can be played with no problem by stereolab’s player. In addition, some of my existing files were converted into avi soon after it was collected in 2020 by a former colleague.

2- The current verision of zed-sdk cannot perform conversion on the old svo files
I am not sure how come it may be possible… but since some svo files were already converted earlier, I suspect that there is a backward compatibility issue in the zed-sdk versions.

Do you have any suggestions or ideas @mattrouss ?

Have just tested with SDK 3.7.7 with the same results.

as a workaround, you could perhaps play the svo files in zed explorer and do a screen capture of the video from there?

Hi @ercan,

I have taken a look and it appears that the issue is with the SVO itself, as I have tried to open it using the different tools and samples of the ZED SDK and they all return END_OF_SVO_FILE straight after opening it, which is not expected behavior. I will continue looking into why these files appear to be corrupted

Can you please share the version in which the SVO was recorded, as well as the platform? Does this happen on all SVOs you have recorded in 2020?

Also thank you @multicore-manticore for the additional testing, this has helped to troubleshoot.

Hi @mattrouss
I have the same impression that the file is corrupted for some reason. However, there are some evidences refuting this. For example, the file can be played with no problem in the svo player. In addition, all the options of ZED_EVOEditor.exe can be used for the file. It seems like it is only the conversion to avi codes that cannot be used. That is what makes the issue odd.
I checked the file with -inf option of the ZED_EVOEditor.exe, and here is the output:

ZED_SVOEditor.exe -inf output_trawl.svo
-inf option detected
SVO Infos : SVO v 1
Image Size : [ 1280 x 720 ]
Framerate : 60
Number of Frames : 999
ZED Serial Number : 12811826
Compression mode : " H265 Lossy (GPU) compression"
Product : ZED-M
Sensors Fw version : 517
Camera Fw version : 1523

It looks like it is not possible the extract the zed-sdk version from the file itself. Do you know if that is possible?
We think that it was zed-sdk version 3 (but cannot remember the minor version) that was used during recording of the videos.
Now I am planning to check the release dates of the legacy zed-sdk versions and install them one by one to check if it helps. But it may take some time.
I would love to hear if you make any progress on this.

Good idea @multicore-manticore. However, I would like to keep this in my mind as the latest option bercause I need the original data for making detailed analysis.


We are still unsure as to why the SVO is corrupted. Thank you for the additional information, I will relay to our tech team to find a way to recover the file.

Hi @mattrouss
Thanks for your help, I will be looking forward to hearing some update from your side.
In the meantime, I tried the conversion process with some older versions of zedsdk-python api.

I successfully set up an environment for zedsdk-python 3.8.2 (cuda 11.7). But the result was the same. Then I wanted to try with older versions. I installed zedsdk-python 3.1.2 (cuda 10.2). I followed the steps given here and run the command python This is the output of the command:

(base) C:\Program Files (x86)\ZED SDK>python
CUDA 10.2
Platform win
ZED 3.2
Python 3.9
Downloading python package from ...

->Please make sure numpy is installed
python3 -m pip install cython
python3 -m pip install numpy
File saved into pyzed-3.2-cp39-cp39-win_amd64.whl
To install it run :
python3 -m pip install pyzed-3.2-cp39-cp39-win_amd64.whl

Next, I tried to execute the .whl file as suggested at the output just above. But the installation fails at this point and I cannot proceed anymore.

(base) C:\Program Files (x86)\ZED SDK>python -m pip install pyzed-3.2-cp39-cp39-win_amd64.whl
Processing c:\program files (x86)\zed sdk\pyzed-3.2-cp39-cp39-win_amd64.whl
ERROR: Wheel ‘pyzed’ located at C:\Program Files (x86)\ZED SDK\pyzed-3.2-cp39-cp39-win_amd64.whl is invalid.

The problem is still alive and I appreciate any kind of recommendations

Hello @ercan,

Thank you for trying different SDK versions. It seems there is an issue with the installation, can you verify that you are using version 3.1.2? The python logs are suggesting you have installed the ZED SDK 3.2