joelibaceta / video-to-ascii Goto Github PK
View Code? Open in Web Editor NEWIt is a simple python package to play videos in the terminal using characters as pixels
License: MIT License
It is a simple python package to play videos in the terminal using characters as pixels
License: MIT License
Collecting video-to-ascii
Using cached video_to_ascii-1.2.8.tar.gz (6.0 kB)
ERROR: Command errored out with exit status 1:
command: /usr/bin/python3 -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-bzdptpyj/video-to-ascii/setup.py'"'"'; __file__='"'"'/tmp/pip-install-bzdptpyj/video-to-ascii/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-pip-egg-info-nxhmzkc9
cwd: /tmp/pip-install-bzdptpyj/video-to-ascii/
Complete output (7 lines):
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/tmp/pip-install-bzdptpyj/video-to-ascii/setup.py", line 17, in <module>
install_package('opencv-python')
File "/tmp/pip-install-bzdptpyj/video-to-ascii/setup.py", line 10, in install_package
main.main(['install', package])
AttributeError: 'function' object has no attribute 'main'
----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
I try to install pyaudio after normal installation and use the - a option, but the screen flashes
alsa lib PCM. C: 8424: (SND_ pcm_ recover) underrun occurred
Hi, I run this program to watch some video on macOS. But I encounter problem: AttributeError: module 'time' has no attribute 'clock'.
After I search that, I know: time.clock() has been removed in Python3.8.
I have checked the related line of file, and replace it with time.process_time(). Then it works well. Maybe need to use other API on other OS.
After Installing the package, When i want to see a video with audio (-a) it gives the error ModuleNotFoundError: No module named 'pyaudio'
I installed the package:
pip3 install video-to-ascii --install-option="--with-audio"
Used it :
video-to-ascii -f rickroll.mp4 --strategy filled-ascii -a
It gives error. I also ran it with no audio and it worked
Screenshots
I've pip installed opencv-python and video-to-ascii in my PC, which runs Windows 10, Chinese simplified version.
However, I constantly encouter the ValueError when I try to run "video-to-ascii -f filepath" command in terminal.
Following is a screenshot about my commands.
How can I solve this trackback? Thanks.
Describe the bug
Crash on Python3.8+ due to time.clock() in render_strategy/ascii_strategy.py
on Python3.8+ time.clock()
should be replaced bytime.perf_counter()
or otherelse
stackoverflow link about that
To Reproduce
Steps to reproduce the behavior:
Traceback (most recent call last):
File "/Users/xxx/Downloads/AE/./venv/bin/video-to-ascii", line 8, in <module>
sys.exit(main())
File "/Users/xxx/Downloads/AE/venv/lib/python3.9/site-packages/video_to_ascii/cli.py", line 21, in main
player.play(ARGS.file, strategy=ARGS.strategy, output=ARGS.output, play_audio=ARGS.with_audio)
File "/Users/xxx/Downloads/AE/venv/lib/python3.9/site-packages/video_to_ascii/player.py", line 23, in play
engine.play(output)
File "/Users/xxx/Downloads/AE/venv/lib/python3.9/site-packages/video_to_ascii/video_engine.py", line 36, in play
self.render_strategy.render(self.read_buffer,
File "/Users/xxx/Downloads/AE/venv/lib/python3.9/site-packages/video_to_ascii/render_strategy/ascii_strategy.py", line 120, in render
t0 = time.clock()
AttributeError: module 'time' has no attribute 'clock'
Expected behavior
Hope support python3.9.9
Desktop (please complete the following information):
Im getting this error after trying to install it on kali linux wsl2 or windows normally.
Defaulting to user installation because normal site-packages is not writeable
Collecting video-to-ascii
Downloading video_to_ascii-1.3.0.tar.gz (6.9 kB)
Preparing metadata (setup.py) ... error
error: subprocess-exited-with-error
× python setup.py egg_info did not run successfully.
│ exit code: 1
╰─> [15 lines of output]
Traceback (most recent call last):
File "/tmp/pip-install-k19bynbv/video-to-ascii_168962df3c8d49358f05e874508b0ea7/setup.py", line 11, in install_package
main.main(['install', package])
AttributeError: 'function' object has no attribute 'main'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "<string>", line 2, in <module>
File "<pip-setuptools-caller>", line 34, in <module>
File "/tmp/pip-install-k19bynbv/video-to-ascii_168962df3c8d49358f05e874508b0ea7/setup.py", line 21, in <module>
install_package('opencv-python')
File "/tmp/pip-install-k19bynbv/video-to-ascii_168962df3c8d49358f05e874508b0ea7/setup.py", line 14, in install_package
__main__._main(['install', package])
AttributeError: module 'pip.__main__' has no attribute '_main'
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed
× Encountered error while generating package metadata.
╰─> See above for output.
note: This is an issue with the package mentioned above, not pip.
hint: See above for details.
Why set up three character lists to represent density?And How to calculate density?
root@mail:/disk1# video-to-ascii -f wild.mp4
Traceback (most recent call last):
File "/usr/local/bin/video-to-ascii", line 11, in
sys.exit(main())
File "/usr/local/lib/python3.6/dist-packages/video_to_ascii/cli.py", line 21, in main
player.play(ARGS.file, strategy=ARGS.strategy, output=ARGS.output, play_audio=ARGS.with_audio)
File "/usr/local/lib/python3.6/dist-packages/video_to_ascii/player.py", line 23, in play
engine.play(output)
File "/usr/local/lib/python3.6/dist-packages/video_to_ascii/video_engine.py", line 38, in play
with_audio=self.with_audio)
File "/usr/local/lib/python3.6/dist-packages/video_to_ascii/render_strategy/ascii_strategy.py", line 113, in render
time_delta = 1./fps
ZeroDivisionError: float division by zero
The README.md file references CONTRIBUTING.md but this file doesn't exist. Is it supposed to, or should the reference be removed?
Due to global reach of this project we need to translate our readme to main spoken languages as:
We suggest use the format readme_es.md
for naming the translated file .
Hi,
First of all congratulations for your awesome work.
To simplify the process of select the apropiate color for a asii character,
Wouldn't be better if the process change the bit-color depth of the image to 8 instead to match from 16, 32. This could be achieved by opencv.
It'll generate wrappers for Windows as well.
https://setuptools.readthedocs.io/en/latest/setuptools.html#automatic-script-creation
I was unable to install the package. I found that the setup.py has a mistake in it.
I fixed it here, please approve this request at : #80
When I try to run the command (video-to-ascii -f video.mp4) it just responds with
echo -en '�[2J' echo -en '�[2J'
It doesn't play the video and just says that.
Installing on macos Mojave using the system pip and python yields the following error on execution:
❯ video-to-ascii
/usr/local/bin/video-to-ascii: line 3: import: command not found
from: can't read /var/mail/video_to_ascii
/usr/local/bin/video-to-ascii: line 6: syntax error near unexpected token `('
/usr/local/bin/video-to-ascii: line 6: `CLI_DESC = ("It is a simple python package to play videos in the terminal"'
On a closer look, it's because the file bin/video-to-ascii is missing the !
from the shebang line, which should read like so:
#!/usr/bin/env python
Furthermore, you'll also want to include a line like this:
# coding=utf-8
Otherwise, I get this error:
258 ❯ video-to-ascii
File "/usr/local/lib/python2.7/bin/video-to-ascii", line 9
SyntaxError: Non-ASCII character '\xf0' in file /usr/local/lib/python2.7/bin/video-to-ascii on line 9, but no encoding declared; see http://python.org/dev/peps/pep-0263/ for details
How to solve this Problem?
i used pip not pip3 to install opencv-python and video-to-ascii because it is not work
Traceback (most recent call last):
File "/home/andre/anaconda3/bin/video-to-ascii", line 10, in
sys.exit(main())
File "/home/andre/anaconda3/lib/python3.7/site-packages/video_to_ascii/cli.py", line 21, in main
player.play(ARGS.file, strategy=ARGS.strategy, output=ARGS.output, play_audio=ARGS.with_audio)
File "/home/andre/anaconda3/lib/python3.7/site-packages/video_to_ascii/player.py", line 23, in play
engine.play(output)
File "/home/andre/anaconda3/lib/python3.7/site-packages/video_to_ascii/video_engine.py", line 38, in play
with_audio=self.with_audio)
File "/home/andre/anaconda3/lib/python3.7/site-packages/video_to_ascii/render_strategy/ascii_strategy.py", line 113, in render
time_delta = 1./fps
ZeroDivisionError: float division by zero
I'm trying to run video-to-ascii
on Python 3.8 and encounter the following error:
Traceback (most recent call last):
File "/home/biazzotto/python/video-to-ascii/.venv/bin/video-to-ascii", line 8, in <module>
sys.exit(main())
File "/home/biazzotto/python/video-to-ascii/.venv/lib/python3.8/site-packages/video_to_ascii/cli.py", line 21, in main
player.play(ARGS.file, strategy=ARGS.strategy, output=ARGS.output, play_audio=ARGS.with_audio)
File "/home/biazzotto/python/video-to-ascii/.venv/lib/python3.8/site-packages/video_to_ascii/player.py", line 23, in play
engine.play(output)
File "/home/biazzotto/python/video-to-ascii/.venv/lib/python3.8/site-packages/video_to_ascii/video_engine.py", line 36, in play
self.render_strategy.render(self.read_buffer,
File "/home/biazzotto/python/video-to-ascii/.venv/lib/python3.8/site-packages/video_to_ascii/render_strategy/ascii_strategy.py", line 120, in render
t0 = time.clock()
AttributeError: module 'time' has no attribute 'clock'
Python version: 3.8.2 (from Ubuntu 20.04 LTS)
video-to-ascii version: 1.2.8
This is caused by removing time.clock()
function in Python 3.8, as warned here: Deprecated since version 3.3, will be removed in version 3.8: The behaviour of this function depends on the platform: use perf_counter() or process_time() instead, depending on your requirements, to have a well defined behaviour.
.
Hello! "ALSA lib pcm.c:8545:(snd_pcm_recover) underrun occurred" error. It plays, but the sound is very laggy. Tried restarting pulseaudio but didn't help. I tried "aconnect -x", the sound became a little better (faster), but the same error also lags. The error occurs at the bottom of the video. Collected using a script, with audio support. Debian, bullseye.
Traceback (most recent call last): File "c:\users\carl-\appdata\local\programs\python\python38-32\lib\runpy.py", line 194, in _run_module_as_main return _run_code(code, main_globals, None, File "c:\users\carl-\appdata\local\programs\python\python38-32\lib\runpy.py", line 87, in _run_code exec(code, run_globals) File "C:\Users\carl-\AppData\Local\Programs\Python\Python38-32\Scripts\video-to-ascii.exe\__main__.py", line 4, in <module> File "c:\users\carl-\appdata\local\programs\python\python38-32\lib\site-packages\video_to_ascii\cli.py", line 3, in <module> from . import player File "c:\users\carl-\appdata\local\programs\python\python38-32\lib\site-packages\video_to_ascii\player.py", line 4, in <module> from . import video_engine as ve File "c:\users\carl-\appdata\local\programs\python\python38-32\lib\site-packages\video_to_ascii\video_engine.py", line 3, in <module> import cv2 ModuleNotFoundError: No module named 'cv2'
Windows 10 32bit
Python 3.8
In some installations, the user gets an error message when try to run the command video-to-ascii
Traceback (most recent call last):
File "/usr/local/bin/video-to-ascii", line 4, in <module>
import video_to_ascii
File "/usr/local/lib/python3.7/site-packages/video_to_ascii/__init__.py", line 4, in <module>
from image_processor import processor
ModuleNotFoundError: No module named 'image_processor'
Some incompatibilities do not allow this tool to run correctly on windows. I will list some of them:
stty size
command is used to obtain the terminal's size, which generates the unknown command error in windows.I get the following error:
Traceback (most recent call last):
File "/home/tavi/.local/bin/video-to-ascii", line 33, in
sys.exit(load_entry_point('video-to-ascii==1.3.0', 'console_scripts', 'video-to-ascii')())
File "/home/tavi/.local/lib/python3.10/site-packages/video_to_ascii/cli.py", line 21, in main
player.play(ARGS.file, strategy=ARGS.strategy, output=ARGS.output, play_audio=ARGS.with_audio)
File "/home/tavi/.local/lib/python3.10/site-packages/video_to_ascii/player.py", line 23, in play
engine.play(output)
File "/home/tavi/.local/lib/python3.10/site-packages/video_to_ascii/video_engine.py", line 36, in play
self.render_strategy.render(self.read_buffer,
File "/home/tavi/.local/lib/python3.10/site-packages/video_to_ascii/render_strategy/ascii_strategy.py", line 126, in render
stream.write(data)
File "/usr/lib/python3.10/site-packages/pyaudio.py", line 585, in write
pa.write_stream(self._stream, frames, num_frames,
SystemError: PY_SSIZE_T_CLEAN macro must be defined for '#' formats
OS: ArcoLinuxL (Arch Linux)
pip3 install ./video-to-ascii Processing ./video-to-ascii Complete output from command python setup.py egg_info: Traceback (most recent call last): File "<string>", line 1, in <module> File "/tmp/pip-req-build-irufanr_/setup.py", line 17, in <module> install_package('opencv-python') File "/tmp/pip-req-build-irufanr_/setup.py", line 10, in install_package main.main(['install', package]) AttributeError: 'function' object has no attribute 'main'
I get the same thing using pip3 install video-to-ascii
I think there is an error in the code.
pip3 install video-to-ascii --install-option="--with-audio"
/usr/lib/python3/dist-packages/pip/commands/install.py:212: UserWarning: Disabling all use of wheels due to the use of --build-options / --global-options / --install-options.
cmdoptions.check_install_build_global(options)
Collecting video-to-ascii
Downloading https://files.pythonhosted.org/packages/69/76/421fff0085dda88307ddb8bf31f4c99de815e707aaca28dae4a44330555f/video_to_ascii-1.2.6.tar.gz
Complete output from command python setup.py egg_info:
Traceback (most recent call last):
File "", line 1, in
File "/tmp/pip-build-wb40_x50/video-to-ascii/setup.py", line 16, in
install_package('opencv-python')
File "/tmp/pip-build-wb40_x50/video-to-ascii/setup.py", line 8, in install_package
from pip._internal import main as pip
ModuleNotFoundError: No module named 'pip._internal'
----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build-wb40_x50/video-to-ascii/
File "/usr/local/bin/video-to-ascii", line 8
SyntaxError: Non-ASCII character '\xf0' in file /usr/local/bin/video-to-ascii on line 8, but no encoding declared;
AttributeError: 'NoneType' object has no attribute 'shape'
Describe the bug
Error when trying to play video.
When I run the command, it prints:
Traceback (most recent call last):
File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.8_3.8.2544.0_x64__qbz5n2kfra8p0\lib\runpy.py", line 194, in _run_module_as_main
return _run_code(code, main_globals, None,
File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.8_3.8.2544.0_x64__qbz5n2kfra8p0\lib\runpy.py", line 87, in _run_code
exec(code, run_globals)
File "C:\Users\...\PycharmProjects\badApple\venv\Scripts\video-to-ascii.exe\__main__.py", line 7, in <module>
File "c:\users\...\pycharmprojects\badapple\venv\lib\site-packages\video_to_ascii\cli.py", line 21, in main
player.play(ARGS.file, strategy=ARGS.strategy, output=ARGS.output, play_audio=ARGS.with_audio)
File "c:\users\...\pycharmprojects\badapple\venv\lib\site-packages\video_to_ascii\player.py", line 23, in play
engine.play(output)
File "c:\users\...\pycharmprojects\badapple\venv\lib\site-packages\video_to_ascii\video_engine.py", line 36, in play
self.render_strategy.render(self.read_buffer,
File "c:\users\...\pycharmprojects\badapple\venv\lib\site-packages\video_to_ascii\render_strategy\ascii_strategy.py", line 120, in render
t0 = time.clock()
AttributeError: module 'time' has no attribute 'clock'
I have all required modules installed
To Reproduce
Steps to reproduce the behavior:
Expected behavior
The video should play.
Desktop (please complete the following information):
Is your feature request related to a problem? Please describe.
To me, this utility is amazing, and very easy to use. I also want to use it for other projects, and I think if there is an option for exporting frames, it will be easier to use the ASCII outputs in different projects.
Describe the solution you'd like
Maybe some parameter like --export or -e
which takes a folder and exports colorless ASCII output by creating text files for each frame.
For example, if --export testfolder/testsubfolder
passed, the program can create testfolder/testsubfolder/0.txt for frame 1 and write the first frame's ASCII output. Then it creates testfolder/testsubfolder/1.txt for frame 2 and so on.
Describe alternatives you've considered
Maybe editing bash output to create something like this.
Hi, I saw the video on Linkedin I think is really cool! Thanks!
I was trying to running this with Phyton like:
python -m video_to_ascii.cli
And the following error is printed:
File "/usr/local/Cellar/python@2/2.7.15_1/Frameworks/Python.framework/Versions/2.7/lib/python2.7/runpy.py", line 174, in _run_module_as_main "__main__", fname, loader, pkg_name) File "/usr/local/Cellar/python@2/2.7.15_1/Frameworks/Python.framework/Versions/2.7/lib/python2.7/runpy.py", line 72, in _run_code exec code in run_globals File "/Users/benjaminaguilar/Documents/work/videoToAscii/video_to_ascii/cli.py", line 3, in <module> from . import player File "video_to_ascii/player.py", line 4, in <module> from . import video_engine as ve File "video_to_ascii/video_engine.py", line 4, in <module> from . import render_strategy as re File "video_to_ascii/render_strategy/__init__.py", line 1, in <module> from . import ascii_bw_strategy as bw File "video_to_ascii/render_strategy/ascii_bw_strategy.py", line 5, in <module> from . import ascii_strategy as strategy File "video_to_ascii/render_strategy/ascii_strategy.py", line 158 SyntaxError: Non-ASCII character '\xe2' in file video_to_ascii/render_strategy/ascii_strategy.py on line 158, but no encoding declared; see http://python.org/dev/peps/pep-0263/ for details
I am in OSX, and I have installed opencv and xtercolor
pip install opencv-contrib-python
pip install xtermcolor
The command was supposed to do audio, but fails. but when I do regular mode, it works just fine
here is the error message:
Traceback (most recent call last):
File "/usr/local/bin/video-to-ascii", line 33, in
sys.exit(load_entry_point('video-to-ascii==1.3.0', 'console_scripts', 'video-to-ascii')())
File "/usr/local/lib/python3.10/dist-packages/video_to_ascii-1.3.0-py3.10.egg/video_to_ascii/cli.py", line 21, in main
File "/usr/local/lib/python3.10/dist-packages/video_to_ascii-1.3.0-py3.10.egg/video_to_ascii/player.py", line 19, in play
File "/home/user/.local/lib/python3.10/site-packages/ffmpeg/_run.py", line 313, in run
process = run_async(
File "/home/user/.local/lib/python3.10/site-packages/ffmpeg/_run.py", line 284, in run_async
return subprocess.Popen(
File "/usr/lib/python3.10/subprocess.py", line 971, in init
self._execute_child(args, executable, preexec_fn, close_fds,
File "/usr/lib/python3.10/subprocess.py", line 1847, in _execute_child
raise child_exception_type(errno_num, err_msg, err_filename)
FileNotFoundError: [Errno 2] No such file or directory: 'ffmpeg'
My OS is Kali Linux.
My Bowser is Firefox.
My python version is 3.10
The python looked like it was trying to open ffmpeg file via subprocess
Is your feature request related to a problem? Please describe.
No problem per se, just a feature request or rather a suggestion.
Describe the solution you'd like
I want the generated ASCII video/animation to play repeatedly, in my case indefinitely i.e. looping until I press e.g. ctrl + c.
Describe alternatives you've considered
I've helped myself with
while true; do video-to-ascii -f myVid.mp4; done
but there's a flash of black between loops.
Additional context
Not sure when the ASCII is generated, but if its not on the fly for each frame, there would be potential here to cache it.
Feel free to close if you dont think this feature would be useful or the like.
I can't figure out where the dimensions for the output file are coming from, and I'd love to be able to change those parameters.
Describe the bug
The pip command throws error and does not install the module
the error is following
Collecting video-to-ascii
Using cached video_to_ascii-1.3.0.tar.gz (6.9 kB)
Preparing metadata (setup.py) ... error
error: subprocess-exited-with-error
× python setup.py egg_info did not run successfully.
│ exit code: 1
╰─> [15 lines of output]
Traceback (most recent call last):
File "C:\Users\ahmed\AppData\Local\Temp\pip-install-9apno99s\video-to-ascii_e8b3c15ce1a440489be86a409ed5aee6\setup.py", line 11, in install_package
main.main(['install', package])
AttributeError: 'function' object has no attribute 'main'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "<string>", line 2, in <module>
File "<pip-setuptools-caller>", line 34, in <module>
File "C:\Users\ahmed\AppData\Local\Temp\pip-install-9apno99s\video-to-ascii_e8b3c15ce1a440489be86a409ed5aee6\setup.py", line 21, in <module>
install_package('opencv-python')
File "C:\Users\ahmed\AppData\Local\Temp\pip-install-9apno99s\video-to-ascii_e8b3c15ce1a440489be86a409ed5aee6\setup.py", line 14, in install_package
__main__._main(['install', package])
AttributeError: module 'pip.__main__' has no attribute '_main'
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed
× Encountered error while generating package metadata.
╰─> See above for output.
note: This is an issue with the package mentioned above, not pip.
hint: See above for details.
Desktop (Windows)
Hi ! In love of your work I would like to use it !
I tried to install it but fail with this error that I don't get :
Is there something I could do to fix it ?
Does this come of my computer or is it a well known bug ? If I can help I'll be happpy !
pip3 install video-to-ascii --install-option="--with-audio"
/usr/lib/python3/dist-packages/pip/commands/install.py:212: UserWarning: Disabling all use of wheels due to the use of --build-options / --global-options / --install-options.
cmdoptions.check_install_build_global(options)
Collecting video-to-ascii
Using cached https://files.pythonhosted.org/packages/42/36/b3ba2181793646f6c32234527ab51e74905a10139273a1056cf717367504/video_to_ascii-1.3.0.tar.gz
Complete output from command python setup.py egg_info:
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/tmp/pip-build-fp1jbfaw/video-to-ascii/setup.py", line 21, in <module>
install_package('opencv-python')
File "/tmp/pip-build-fp1jbfaw/video-to-ascii/setup.py", line 10, in install_package
from pip._internal import main
ModuleNotFoundError: No module named 'pip._internal
----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build-fp1jbfaw/video-to-ascii
This is a Good First Issue
to fix the following typos
./video_to_ascii/cli.py:8: usefull ==> useful
./video_to_ascii/render_strategy/ascii_strategy.py:72: correcly ==> correctly
./video_to_ascii/render_strategy/ascii_strategy.py:72: builded ==> built
./video_to_ascii/render_strategy/image_processor.py:1: usefull ==> useful
./video_to_ascii/render_strategy/image_processor.py:14: apropiate ==> appropriate
./video_to_ascii/render_strategy/image_processor.py:23: apropiate ==> appropriate
./video_to_ascii/render_strategy/image_processor.py:57: brighness ==> brightness
./bin/video-to-ascii:6: usefull ==> useful
I got 'AttributeError: module 'time' has no attribute 'clock''. A simple google search let me to believe the 'time.clock()' function has been removed and replace by another.
https://stackoverflow.com/questions/58569361/attributeerror-module-time-has-no-attribute-clock-in-python-3-8
Hi, it works much well (without audio).
Just wonder if there is the option to adjust the playing speed?
i have an error when i download the module and i open cmd i put video-to-ascii -f video.mp4 but is not working
this is the error:
ascii_strategy.py", line 121, in render
rows, cols = os.popen('stty size', 'r').read().split()
ValueError: not enough values to unpack (expected 2, got 0)
D:>pip3 install video-to-ascii --install-option="--with-audio"
c:\users\footb\appdata\local\programs\python\python38\lib\site-packages\pip_internal\commands\install.py:230: UserWarning: Disabling all use of wheels due to the use of --build-option / --global-option / --install-option.
cmdoptions.check_install_build_global(options)
Collecting video-to-ascii
Using cached video_to_ascii-1.2.9.tar.gz (6.1 kB)
Collecting xtermcolor
Using cached xtermcolor-1.3.tar.gz (3.8 kB)
Collecting ffmpeg-python
Using cached ffmpeg-python-0.2.0.tar.gz (21 kB)
Collecting future
Using cached future-0.18.2.tar.gz (829 kB)
Skipping wheel build for video-to-ascii, due to binaries being disabled for it.
Skipping wheel build for ffmpeg-python, due to binaries being disabled for it.
Skipping wheel build for future, due to binaries being disabled for it.
Skipping wheel build for xtermcolor, due to binaries being disabled for it.
Installing collected packages: future, xtermcolor, ffmpeg-python, video-to-ascii
Running setup.py install for future ... error
ERROR: Command errored out with exit status 1:
command: 'c:\users\footb\appdata\local\programs\python\python38\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\Users\footb\AppData\Local\Temp\pip-install-t_3_1qvw\future_95a3c7a8272d4d5ebfe5d44600f86280\setup.py'"'"'; file='"'"'C:\Users\footb\AppData\Local\Temp\pip-install-t_3_1qvw\future_95a3c7a8272d4d5ebfe5d44600f86280\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(file);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' install --record 'C:\Users\footb\AppData\Local\Temp\pip-record-cg0z8f53\install-record.txt' --single-version-externally-managed --compile --install-headers 'c:\users\footb\appdata\local\programs\python\python38\Include\future' --with-audio
cwd: C:\Users\footb\AppData\Local\Temp\pip-install-t_3_1qvw\future_95a3c7a8272d4d5ebfe5d44600f86280
Complete output (6 lines):
usage: setup.py [global_opts] cmd1 [cmd1_opts] [cmd2 [cmd2_opts] ...]
or: setup.py --help [cmd1 cmd2 ...]
or: setup.py --help-commands
or: setup.py cmd --help
error: option --with-audio not recognized
----------------------------------------
ERROR: Command errored out with exit status 1: 'c:\users\footb\appdata\local\programs\python\python38\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\Users\footb\AppData\Local\Temp\pip-install-t_3_1qvw\future_95a3c7a8272d4d5ebfe5d44600f86280\setup.py'"'"'; file='"'"'C:\Users\footb\AppData\Local\Temp\pip-install-t_3_1qvw\future_95a3c7a8272d4d5ebfe5d44600f86280\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(file);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' install --record 'C:\Users\footb\AppData\Local\Temp\pip-record-cg0z8f53\install-record.txt' --single-version-externally-managed --compile --install-headers 'c:\users\footb\appdata\local\programs\python\python38\Include\future' --with-audio Check the logs for full command output.
running this through linux terminal and the video portion is working great, however audio is choppy, will cut out for a microsecond pretty frequently and drifts out of sync pretty heavily the longer the video is.
the bottom of the linux terminal also complains about under runnage through lib pcm?
Alternative: trunk the video width.
File "bin/video-to-ascii", line 4
d from video_to_ascii import player
^
SyntaxError: invalid syntax
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.