Description
Named as such, this package is a command-line ASCII art generator written in Python. There is a variety of parameters which are detailed below.
Installation
With Python installed, install the package from PyPI with the following command:
python -m pip install ascii-art-cli
This package is not to be confused with ascii_art or other various ASCII art packages.
Usage
This is a command-line program, and can be executed as follows:
ascii-art [-h] [--width WIDTH] [--height HEIGHT] [--chars CHARS] [--font FONT] [--invert] [--normalize] input
Positional arguments:
input Path to image from which ASCII art will be generated
Optional arguments:
-h, --help show this help message and exit
--width WIDTH Character width of ASCII art
--height HEIGHT Character height of ASCII art
--chars CHARS String containing characters to be seen in ASCII art
--font FONT Font for calculating the character weights
--invert Whether the ASCII output color is inverted
--normalize Whether the weights of the provided ASCII characters are normalized
Example:
ascii-art examples/images/einstein.jpg --width 100 --height 50 --font "Courier" --invert --normalize
,;+;;+;;;,?;?;;;,,,,,,;,;',,'',;%S;;;%SS%SSSSSSSSSSSSSSSSSSSSSSSSS%%%%%%??%%%%;'S+.. . .
+;;;?;+;,++;;,,,,,;,,,,,,,,,';+%S,,%S%SS#SSSSSS####S#S##S##SSSSSSS%S%%%%%%%S%SS+'%'.
?+;;,;+;;,;+;;;,,,,;,,,','',;%%%',S%S%SSSSSS#SSSS#SSSSS####SSS#SSSSS%S%%S%%%%S%%%;;'. ..
%+;%+;?++;;,,;,,,,,,',,',,;+,%?;'?;%SSSSS#SSSSS##SS######@##SSSS#SSSS%S%S%%%%%S%%'%'' .... .
?????;;??;;;+,,+,,,,''',;+;;;;;',%%%SSS#######S###########SSS##SSSSSSS%SS%%%%SSS%?',;, . ...
?+;??++;;+;;;,,,,,''',,;%?%%,,''%,%SSSS#######S#####@#######SSS%#SSSSSS%%%%%%SSSS%;?.'''. .
;?%;;;+;;+;,,,,,,''',;S?;,',;,'+,S%?%SSS#@###SS########@#SSSS#SSSSSSSS%SS%%%%S%S%S?%' .' .
???;;;++,;+;,;',''',%S'?;,+,,?.;?%S%%SSS#@############S###SSSSSSSSSSSSSSSS%%SSSSS%+,,.. ', .
??+?;;%++;;,,,,,,;';%',,;;;';%';%'.',+,SSS###SSS##SSS%,',SS%S#%SSSSSSSSSSS%SS%SS%%%,;,. .'
%;+;?+;+;;;+,,,,,''?''?;?+,;%?.''.'',%SS##S#SSS##SSSSSS?;,;%??SSSSSSSSSSSSSSSSSSS%?%;'+'..'.
S????;;;;;;;;;,'',,%,;+,%?,,%;'%;;%%%%SSS##@SSS##SS###SSSSSSSSSSSSS%SSSSSS%SSSSSS%?+;,''.'.'
?,?+;;?;;;,,;,,,'+,''.%%;,,?%+.;?SSSSS%SSS#S#@###@####S##SSSSSSSS%SSSSSSSSSSSSS%%%????'',. .'.. .
,S;,;;??;;;;,',,''',.,,%;'';%,.%%SS%%%S%%SS####@@#SS#SS#SSSS#SSSSSSSSSSSSSS%SSS%%%%,;?;+., .
%%?;;+%;;;+,,,',.,...,;;,',;?',%SS%%%??SS?%S#@@###SSSS%%+,;%SS#SSS%SSSSSSSSSSSSSSS%%,,+?;,,. .
S?%;+;+;,,,,,';'.'.'',%,,,'+%''?S%,,?+?S%%,?S#@#S#SSSSS?+%%%+%SSSS%SSSSSSSSSSSSSSS%%%;?;%%' .
S,+,;;;+,,,,''......',%''',;?',%?,'##;,?;S?'S@##SSS%%%;';.,S%%SSSS%SSSSS%SSSSSSSSS%S?;%;%;,S. .
%%?;+,;,;,''.'......''%',',%,';%%'+S...;#%%'S#SSS%SS%?#S...,?%%SSS%SSS%S%SSSSSSSS%+%%?;;%%;,';
,+?;;,;,,''''.... ..',?,'''%'';%S,;%,'%%;%,%SSSSS%#S%SSS...S%SSSSSSSSSS%SSSSSSS%S%%%??%?;+;;..,.
,%';,,;,''''......';.';.',.;'';%,;''%?S;SS'%SSSSS%SS%%%?%%%?+%SSSSSSSSS%%%SSSS%%%%%?%;?%%;,++ ;
%%',';;,',''....'.., ;%.''.;.,+,?%?,%%%%%,,%SSSSSSSS?%S%%%%%%%S%%SSS%SSS%%SSSS%%%%%%%%%,%;;,;;
S%',,'.;''''...,.....;,'''.'.,%;%%%%%%%%?';SSS%SSSSSSS%%SSSSSS%%SSSS%SS%%%%S%%%%;;;%%%%%+S?'+,' '
%;..''''','....'....,.,'.'...?%%%SSSS%SS''%SS%%%SSSS#SS#SSSSSSSS%%S%%%S%%%%%%%??S%',+%%%%?%+'+.. .
%,. ...''.''...'...;'',..S...,%SSSSSSSS%'%SSSS%?%SSS###SSSSSSSSSSSSS%%%%%%%%%%;%%S;%;;%%%%%%%?,. '
+' ....''......'.?,''...,...%S#SS?SSS%,+SSSS%%%%SS#SS#S@#SSSS##SSS%%%%%%++;%?%SS%;?;.%%SSS%%?;''..
?. . .........'.''.....'...%SSSS%SS%S,SS##SSS%?%S##SS########SSSSS%%%%%+;%;SSSSSS.%%%%SSS%;%%',.
,. ... ........'... ...'''...;#SS%SS%#';SS##@SS%%%%SS@@#S####S##SSS%%+%%?;,%%SSSS%%S%S.%SSSS%%S+'.
.... .. . .........'..'...'..+%S%%%S#S,,%S#@#SS%SS%%SS@#####S##SS#SS?;%%%;;%S#SSS%SS%S%;SSSS%?S%' .
?, .... .... ....'.......,..;?%%SS##',',SSSSS%SSSS?S#S##@#S#S#SSSSS%;%%?%++%%%SS%%SS%%;S#SS,%S%;.'.
,,.... . .. .. .........,,..++;%S##SS?'.;%%%;#S@%%%SSSS####SSSSS+SS%?%%?%;%S#%S%S%SS%%+SSSS;;S%?.
%;.. .... .. ... ..%'+S''..+%;SSSS%%?SSSS#SS#%S%SSSS#S%S#SSSSSSSSS+?%+%%;SSS%S;SSS%S;S#SSS?+S;''.
;, %#... .S. ..... .. '''..%S;%SSSSSSS#S#S%SS#SSSS%SSSSSSSSSSSSSSS%%%%%%,SSS?;??%S%%%SSSSS,,%, '..
', ......... ... . .,''..%S;S%S%SS@@SSSS%S##S#S#SSSSSSSSSSSSSSSS+%%?%?+SSS%,%%%?%+SS%S%%,%; ' ..
,' . . . ....... .....'...;S,%,?SS%S#%S#SS#SSSS##%SSSSS+SSSSSSSS%;%%%%+%SS%??.'S%%%%;;SS%,'......
' ...#. .. . .. .....'...,%;%?;;%%%SS#SSSS%S#%%%S%SSSSSSSSSSSSS%,S%%%;.S%?' ..;S;,%.'%,. .......
' . . ...... .... .........'%;%%?,',,?;%;%++S%,,%,?S%#SS%SSSSSSSS%?%S%%%' .'. .;'.........
. .. . ... ...............%%%SS;,.'.,'?';,,+SS,'+,;'SSSSSSSSSSS%;SS%+,' . ...........
.. .. ....... ..........%%'SSS%,,,?;%%?%%%%%;%,..;;SSS#SSSSSS%,SS%+' . . ......'....'
. ..... ...............+%;SSS?.%S%%S%S%%%%%?''++%%?SSSSSSSS?SS%, . ... .....'..',,
. . . .......'........%S,SS#%.%%%%%%%S%S%?,,%SS#%?SS%SSSSS,S%, .. ..... .......'',,
.......................%S?##S.S#%S%S%%;SS;%%%%SSS%SS%SSSS+SS. ... ....'. ''+,'
. . ... ........'........'S+S#S.;SS%%;%%+#,,+?%S#SS%S%%SSSS%S . . ... .......',+,';
..'..................;SS#S.+S#SS%;;%S;,,%SSS#SSS?S#S%,%. . . .... ..... .,'+,,',
',,''''..........'......S'#S.'%@S%%?;%%';%S%SSSSSS;SS%+. . . . . . .. . ....,,;,';,,
. ,,,,,,','............'....'SSS,.%SS+%%%S;%S%SS##SS#SS#S?... .. . .... ..... ',;,,';,',
,,,',,,,,'''..........'''....%,SS.;%S%%?S%;%SS#S###SS%SS'.. .. . . . . . .'',++,;,;;,
,,,,,,,,,,,',.'.........''''....'?S%.?%?S%?,SS#SSS###SSSS.... ... .. ..... .. ...';+%?,;,'','
. ,,,;,,,,,,,,,,,'''...''''''''''.....?S..%%%%%S##SSSS#S#S%........ . ....... ..,,,,',;,;'''.
',,,,,,,,,,',,,,,','....'''''''''......%%..;+;SS@S#SSSSSS,.................... ... ''',,,',;;+',..
,,,,,;,,,,,',,;,,,'''.''.'''''''''......%%+,%####S####S%............ ........... .'',;;;'+,;';''..
,;,,,;,,,,,,;,,,;,,''.'''''''''..''......?%SSSSSS#SSS%............ ....'........ ..,,,,',,%;,'''..'
By default, the command will output the generated ASCII art to the console. If instead you would like to output to a file, feel free to use the redirection > operator. More info on that here.
Feel free to check out the docs for more information on how to use this package.
License
This software is released under the terms of MIT license.
Metadata
Release files for ascii-art-cli 1.4.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| ascii-art-cli-1.4.0.tar.gz | 7.6 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| ascii_art_cli-1.4.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 15.0 kB
Release files / ascii-art-cli-1.4.0.tar.gz
| Download URL | ascii-art-cli-1.4.0.tar.gz |
|---|---|
| Size | 7.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
3a09271c0b2b549c00b59358c421e3160be18fe8d93dea9d809931f945bac633
|
|
BLAKE2b-256 checksum How to use checksums |
edaa679a08a912ff19021b337bf02eb9381ad8450a1b6b15bcc9e6bca1888ea6
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.1.4 CPython/3.7.10 Linux/5.4.0-1041-azure
|
Release files / ascii_art_cli-1.4.0-py3-none-any.whl
| Download URL | ascii_art_cli-1.4.0-py3-none-any.whl |
|---|---|
| Size | 7.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
ef28204719dc715b1ff92345ffaf9f9f90e7cd3649bbffd61de88c406cdcfcf1
|
|
BLAKE2b-256 checksum How to use checksums |
efca388851c8bdf668b37bd2c10b03aabf381dbbd9f0bf7238017132e793fb8c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.1.4 CPython/3.7.10 Linux/5.4.0-1041-azure
|
Security for ascii-art-cli 1.4.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.