eth-ait / aitviewer

A set of tools to visualize and interact with sequences of 3D data.
MIT License
581 stars 52 forks source link

AttributeError: 'FFmpegWriter' object has no attribute '_proc' #49

Closed Kohki0401 closed 4 months ago

Kohki0401 commented 8 months ago

I faced below error when I use aitviewer. I set smplx_models but I could not find out the solutions...

C.update_conf({"smplx_models": "./data/SMPLX/"})

-------------------------------------------------------------- error log --------------------------------------------------------------- /home/datasynthesizer/miniconda3/envs/ROMP/lib/python3.9/site-packages/aitviewer/viewer.py:1889: RuntimeWarning: divide by zero encountered in double_scalars az_delta = np.radians(rotation_degrees) / frames Rendering frames: 0it [00:00, ?it/s] Traceback (most recent call last): File "/home/datasynthesizer/Documents/IA_data/InstantAvatar/scripts/visualize-SMPL.py", line 141, in viewer.save_video(video_dir=f"{args.path}/output.mp4", output_fps=args.fps) File "/home/datasynthesizer/miniconda3/envs/ROMP/lib/python3.9/site-packages/aitviewer/headless.py", line 38, in save_video self.export_video( File "/home/datasynthesizer/miniconda3/envs/ROMP/lib/python3.9/site-packages/aitviewer/viewer.py", line 1957, in export_video writer.close() File "/home/datasynthesizer/miniconda3/envs/ROMP/lib/python3.9/site-packages/skvideo/io/ffmpeg.py", line 432, in close if self._proc is None: # pragma: no cover AttributeError: 'FFmpegWriter' object has no attribute '_proc'

ramenguy99 commented 8 months ago

Hi, this seems to be a problem with ffmpeg or the skvideo library. I have found a similar issue reported here: https://github.com/kekeblom/StrayVisualizer/issues/5 can you check if ffmpeg is installed on your system by running ffmpeg --version as they suggest there?

Kohki0401 commented 8 months ago

Sure, I installed. here is a log. probably it happened by ffmpeg and skvideo version. is it possible to shart it?

-------------------------------------------------------------- log --------------------------------------------------------------- ffmpeg version 4.4.2-0ubuntu0.22.04.1 Copyright (c) 2000-2021 the FFmpeg developers built with gcc 11 (Ubuntu 11.2.0-19ubuntu1) configuration: --prefix=/usr --extra-version=0ubuntu0.22.04.1 --toolchain=hardened --libdir=/usr/lib/x86_64-linux-gnu --incdir=/usr/include/x86_64-linux-gnu --arch=amd64 --enable-gpl --disable-stripping --enable-gnutls --enable-ladspa --enable-libaom --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libcdio --enable-libcodec2 --enable-libdav1d --enable-libflite --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-libgme --enable-libgsm --enable-libjack --enable-libmp3lame --enable-libmysofa --enable-libopenjpeg --enable-libopenmpt --enable-libopus --enable-libpulse --enable-librabbitmq --enable-librubberband --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libsrt --enable-libssh --enable-libtheora --enable-libtwolame --enable-libvidstab --enable-libvorbis --enable-libvpx --enable-libwebp --enable-libx265 --enable-libxml2 --enable-libxvid --enable-libzimg --enable-libzmq --enable-libzvbi --enable-lv2 --enable-omx --enable-openal --enable-opencl --enable-opengl --enable-sdl2 --enable-pocketsphinx --enable-librsvg --enable-libmfx --enable-libdc1394 --enable-libdrm --enable-libiec61883 --enable-chromaprint --enable-frei0r --enable-libx264 --enable-shared libavutil 56. 70.100 / 56. 70.100 libavcodec 58.134.100 / 58.134.100 libavformat 58. 76.100 / 58. 76.100 libavdevice 58. 13.100 / 58. 13.100 libavfilter 7.110.100 / 7.110.100 libswscale 5. 9.100 / 5. 9.100 libswresample 3. 9.100 / 3. 9.100 libpostproc 55. 9.100 / 55. 9.100

ramenguy99 commented 8 months ago

Hi, the ffmpeg version looks good. From a closer look at the error message the problem might be something else. It looks like you are trying to render a video with 0 frames, which might explain the error from skvideo. Can you share the python script that is producing the error?

kaufManu commented 4 months ago

Closing due to inactivity, feel free to open again if required.