Saravanan666/pypi-org huggingface dataset:
Package: color-it
ColorItA simple library to add color to your output.Have you ever wanted to print Colors to the console? I certainly have. There comes a time when you realize it is a necessity. That's why I created ColorIt. ColorIt is a super simple way to print color to the console.How it worksInterally, the library creates custom ANSI sequences with RGB values. This means there are 16 million colors that can be used withcolorit!InstallationTo installcolorit. Runpip install color-iton Windows, orpip3 install color-iton macOS and Linux, from there it can be imported withimport coloritHow to use itTo use ColorIt:fromcoloritimport*# Use this to ensure that ColorIt will be usable by certain command line interfacesinit_colorit()# Foregroundprint(color("This text is red",Colors.red))print(color("This text is orange",Colors.orange))print(color("This text is yellow",Colors.yellow))print(color("This text is green",Colors.green))print(color("This text is blue",Colors.blue))print(color("This text is purple",Colors.purple))print(color("This text is white",Colors.white))# Backgroundprint(background("This text has a background that is red",Colors.red))print(background("This text has a background that is orange",Colors.orange))print(background("This text has a background that is yellow",Colors.yellow))print(background("This text has a background that is green",Colors.green))print(background("This text has a background that is blue",Colors.blue))print(background("This text has a background that is purple",Colors.purple))print(background("This text has a background that is white",Colors.white))# Customprint(color("This color has a custom grey text color",(150,150,150)))print(background("This color has a custom grey background",(150,150,150)))# Combinationprint(background(color("This text is blue with a white background",Colors.blue),Colors.white))# If you are using Windows Command Line, this is so that it doesn't close immediatelyinput()As output you get:If you would like to try this for yoyr self, you can downloaddemo.pyand try it out.And that's it. That's really all there is to it.Additional Note:init_colorit()clears the console, so put this somewhere in your code before printing output.Release LogReleased the first version of ColorIt (v1.0.0)Added a licenseSupport me on patreon!Here is the link to my patreon page:https://www.patreon.com/supermazingcoder:D
Package: colorix
colorixColorix (which stands for 'Color Exchange') is a Python3 module designed for working with colors; specifically color conversion, utilities, and more.InstallationThe easiest way to installcolorixis through PIP.pip install colorixorpip3 install colorixBefore installing, ensure your Python version is 3.6 or above.UsageNOTE: Results produced by colorix are not guaranteed to be accurateCurrently,colorixsupports 3 color spaces; RGB, CMYK, and HEX.The following example demonstrates the standard use ofcolorix.fromcoloriximportRGB# Import the RGB classrgb=(12,34,56)# Set our valuesmy_result=RGB(*rgb).toCMYK().raw# Get our valuesprint(my_result)# Print them>>>(79,39,0,78)cmyk=my_result# Set our valuesmy_result=CMYK(*cmyk).toRGB().raw# Get our valuesprint(my_result)# Print them>>(12,34,56)
Package: colorize
Give some color to your (remote) TTY!!VERSIONDOWNLOADSTESTSCOVERAGEWHEELAnd it is free. Checkout theSource code.Installation and UsageTwo options: to install it in your system/project:pip install colorizeAnd you can use it with:python -m colorize -hNow, you have two ways to use it:Rendering the outputJust execute:$ command to execute | python -m colorizeIf you need to render both the stdout and the stderr:$ command to execute |& python -m colorizeThis method works well with too long outputsAs runnerOther way to use it:$ python -m colorize command to executeThis method can do disgusting things with too long outputs.OptionsYou can change the output format with the argument-for--format. It uses the same format thatlogging, so you can use any of its special variables, like:%(asctime)s, to show the time.%(message)s, to show the message itself.%(msecs)d, to show the relative time.Any other output format allowed by logging.You can combine them as you wish. Example:$ python -m colorize -- echo foo
foo
$ python -m colorize -f "%(asctime)s - %(levelname).2s: %(message)s" -- echo foo
05-29 08:43:09 - IN: foo
$ python -m colorize -f "%(levelname).2s %(asctime)s - %(message)s" -- echo foo
IN 05-29 08:44:17 - fooDefault date format is%m-%d %H:%M:%S, but you can change it with--date-format:$ python -m colorize -f "%(asctime)s" --date-format="%H:%M:%S" -- echo foo
08:44:17
$ python -m colorize -f "%(asctime)s" --date-format="%H %M %S" -- echo foo
08 44 17Configuration FileIt will find a configuration file in the current directory, in the home directory or in the default path directory. The first one found will be used. So, it will search for:./.colorize.conf$HOME/.configuration/colorize/colorize.conf/etc/colorize/colorize.confThe format for this file is very easy: it is a CSV file with next fields:# regular expression to highlight (quoted) , bold output , foreground color , background color
  "^=+$"                                   , 1           , white            ,
  "^=+$"                                   , true        , white            , black
  "^=+$"                                   , 0           , red              , white
  "^=+$"                                   , false       , brown            , magentaFor example, you can configure it to colorize thego testoutput:"^PASS", 1, white, green
"^ok", 1, white, green
"^FAIL", 1, white, red
"^--- FAIL:", 1, white, redAvailable colors:blackwhiteredgreenbluebrowngraymagentacyanAnd that’s all.Example to simulate colordiffTo emulate colordiff, just use this configuration file:"^>.*",                0, blue
"^<.*",                0, red
"^\d+,?\d*c\d+,?\d*$", 0, magentaThat’s enough :D
Package: colorizelatextables
ColorizeLaTexTables: small script to get color coded latex tables from csv files or pandas DataFramesCreate latex tables that are colored based on rank.InstallationInstall via pip:pip install colorizelatextablesDependenciesOnly necessary dependency is pandas, seaborn is recommended for color palettes:pip install pandas
pip install seabornUsage:You can either use the script or use the moduleScriptcolorize_table.py examples/BigTable.csv bigtable.texYou can also use seaborn palette names if you have seaborncolorize_table.py --palette "GnBu_r" examples/BigTable.csv bigtable.texOptions:usage: colorize_table.py [-h] [-a] [--precision PRECISION] [-n NRANKS]
                         [--colors COLORS] [--palette PALETTE] [-f]
                         [--seperator SEPERATOR] [--columnwise]
                         inputpath [outputpath]

positional arguments:
  inputpath             the path to the .csv table
  outputpath            the path where you want the.tex file

optional arguments:
  -h, --help            show this help message and exit
  -a, --ascending       highlight from smallest to largest, default is
                        descending
  --precision PRECISION
                        decimal precision,default is 3
  -n NRANKS, --nranks NRANKS
                        number of ranks to highlight
  --colors COLORS       rgb_codes as list of float triples. if you have
                        seaborn it is recommended to use the --palette option
  --palette PALETTE     seaborn color palette name
  -f, --full            creates a complete .tex document, rather than only the
                        tabular statement
  --seperator SEPERATOR
                        seperator of csv, comma is default
  --columnwise          calculate columnwise rank rather than rowwise rankModulefromcolorizelatextablesimportto_colorized_latextable_string,defined_colors=to_colorized_latex(df,sns.color_palette("GnBu_d",n_colors=3))You can also provide additional keyword arguments that are passed to pandasto_latex()function, e.g.table_string,defined_colors=to_colorized_latex(df,sns.color_palette("GnBu_d",n_colors=3),column_format="|c|c|c|c|c|c|c|c|c|")
Package: colorizelib
Colorize.pyWhat is it and what is it forColorize.pyis a very simple to use and understand python library. It allows you to color text in the terminal.
This library is inspired by thepycolorlibraryinstalationpipinstallcolorizelibFunctionsFunctionDescriptioncolorize(text, foreground, style, background)Colorize the text with the foreground, style and backgroundcolorize_foreground(text, foreground)Colorize the text with the foregroundcolorize_style(text, style)Colorize the text with the stylecolorize_background(text, background)Colorize the text with the backgroundcolorize_rainbow(text, mode_type)Colorize the text with a rainbowget_color_list()Get the list of all colorsget_color_name(color)Get the name of the color by numberget_color_number(color)Get the number of the color by nameExemplesfromcolorizeimportcolorizeprint(colorize.colorize("Hello World",foreground="red",style="bold",background="blue"))fromcolorizeimportcolorizeprint(colorize.colorize("Hello World",foreground="blue"))fromcolorizeimportcolorizeprint(colorize.colorize_style("Hello World","bold"))fromcolorizeimportcolorizeprint(colorize.colorize_rainbow("Hello World","foreground"))ContributorsHow to ContributingOpen pull request 😎
Package: colorize-package
Image ColorizerThis package provides tools to colorize images using deep learning models.InstallationClone this repository and run:pipinstall.UsageTo use the Image Colorizer, import it in your Python script and provide the paths for the model and images:fromimage_colorizerimportImageColorizermodel_path='path_to_your_model.pkl'input_path='path_to_your_input_image.jpg'output_path='path_to_save_colorized_image.jpg'colorizer=ImageColorizer(model_path)colorizer.colorize(input_path,output_path)
Package: colorize-pinyin
search for chinese pinyin and wrap it with HTML.colorize pinyinsearch for chinese pinyin and wrap it with HTML.module provides some useful functions for working with Chinese pinyin,
“phonetic system for transcribing the Mandarin pronunciations of
Chinese characters into the Latin alphabet” (c)wikipedia.usage sample>>> colorized_HTML_string_from_string('nǐ hǎo')
'<span class="pinYinWrapper"><span class="t3">nǐ</span> <span class="t3">hǎo</span></span>'>>> ranges_of_pinyin_in_string('nǐ hǎo')
[Range(location=0, length=2), Range(location=3, length=3)]  # == [(0, 2), (3, 3)]requirementslxmlis only required if you want to work with DOM.  but it does not listed in requirements because if you want to use them, surely you already havelxmlon the board; for other cases we don’t need additional third-party libs.functions that designed to work withlxmlmarked with[*].functionsmodify given DOM by replacing children text nodes containing pinyin with
wrapper element:colorize_DOM[*]undo colorize:uncolorize_DOM[*]detect and wrap pinyin with HTML in plain text string:colorized_HTML_string_from_stringdo the same, but returns a wrapper – DOM element:colorized_HTML_element_from_string[*]searching for pinyin in string of text:ranges_of_pinyin_in_stringfinding out what tone has some pinyin word:determine_toneremove tones (diacritics) from pinyin string:lowercase_string_by_removing_pinyin_tonesconstantsPINYIN_LIST– specially sorted list of all possible pinyin words.PINYIN_LIST_BY_LEN– same asPINYIN_LISTbut grouped by len descending.PINYIN_WRAPPER_CLASS– default class used by[un]colorize_DOM.classesRange– 2-named-tuple with[0]location and[1]length.
Package: colorize.py
colorize.pyThere is at least oneexisting toolto perform automatic syntax highlighting
of code and output ANSI escape sequences.  Unfortunately, to the best of the
author’s knowledge, there is no existing tool for highlighting lines of log
files that contain a particular pattern.  Vim’smatchand2matchare
close, but a little kludgy to use.The purpose of this tool is to colorize lines matching a particular pattern, to
make it easier to highlight relevant lines in a log file, when poring over such
files with your coworker or manager.UsageAssume we have a file with the following contents:This is an interesting line with some awesome content.
unrelated line
unrelated line
unrelated line
foobar
Different topic of interest
unrelated lineThen we can run the following commands to see some of effects we want:colorize.py -h
colorize.py -l
colorize.py -f 'This is an interesting line=Blue' Input.log
colorize.py -f 'This is an interesting line=Blue' -f 'Different topic=Red' Input.log

# Note that we must run less in raw node to see the colors.
colorize.py -f 'This is an interesting line=Blue' | less -R
Package: colorizon
An easy to use library for putting colors into the terminal written in Python.InstallingPython 3.8 or higher is required# Linux/macOSpython3-mpipinstall-Ucolorizon# Windowspy-3-mpipinstall-UcolorizonOr install from GitHub:$gitclonehttps://github.com/FelipeSavazii/Colorizon$cdColorizon$python3-mpipinstall-UQuick Examplefromcolorizon.backgroundsimportBackgroundsfromcolorizon.colorsimportColorsfromcolorizon.formattingsimportFormattingsprint(Backgrounds().black('Hello, World!'))print(Colors().pink('I love you, Ariana Grande.'))print(Formattings().bold('Excuse me, i love you!'))DocumentationAttributes for Backgrounds():Backgrounds().black(text).red(text).green(text).orange(text).blue(text).purple(text).cyan(text).lightcyan(text)Attributes for Colors():Colors().black(text).red(text).green(text).orange(text).blue(text).purple(text).cyan(text).lightgray(text).darkgray(text).lightred(text).lightgreen(text).yellow(text).lightblue(text).pink(text).lightcyan(text)Attributes for Formattings():Formattings().normal().bold(text).disable(text).underline(text).reverse(text).strikethrough(text).invisible(text)LinksDocumentation: Coming soonOfficial Discord Server
Package: color-latam
Libreria transformadora de textoUna libreria que cambia el color del texto en español en el terminalComenzando 🚀instalar la libreriapip install color_latam*Modo de usoEjemplo:example.pyimport color_latam

palabra = input("Ingresa una palabra: ")
resultado = color.rojo(palabra)
resul = color.verde(palabra)


print(resultado)
print("---")
print(resul)
Package: color-log
颜色日志使用说明fromcolor_logimportLoggerlog=Logger()log.info('message')log.error('message')linux系统使用tail -F -s10 -n20 logs/log | perl -pe 's/(INFO)|(WARNING)|(ERROR)/\e[1;34m$1\e[0m\e[1;33m$2\e[0m\e[1;31m$3\e[0m/g'实时监控日志变化
Package: colorlog-jawide
colorlogexamplefromcolorlogimportlogginglogging.basicConfig(level=logging.DEBUG)logging.debug("jawide")logging.info("jawide")logging.warning("jawide")logging.error("jawide")logging.critical("jawide")setuppipinstallcolorlog-jawidecustomfromcolorlogimportinit,Config,LogLevel,Color,Fore,Back,Styleimportlogginginit(logging,Config({LogLevel.DEBUG:Color(Fore.GREEN,Style.BRIGHT),LogLevel.CRITICAL:Color(Fore.YELLOW,Back.RED,Style.NORMAL)}))logging.basicConfig(level=logging.DEBUG)logging.debug("jawide")logging.info("jawide")logging.warning("jawide")logging.error("jawide")logging.critical("jawide")buildrm-r./build./dist
pythonsetup.pysdistbdist_wheeltest uploadpython-mtwineupload--repositorytestpypidist/*test pippython-mpipinstall--index-urlhttps://test.pypi.org/simple/--no-depscolorlog-jawideuploadpython-mtwineuploaddist/*
Package: colorlog-python
ColorLogColorLogis a lightweight logger that makes logging to the terminal easy and pretty for python.This is self-made & self-used module for coloring logging infomation. Welcome any contributions if you would like!TODOAuto-inlineAdd requirementsUpload to PyPIInstallationFontThe recommended font isMesloLGS NF.Install from PyPITODOpipinstallcolorlog-pythonUsageTo usecolorlog, just import the pre-instantiatedloggerinto your code.fromcolorlogimportloggerlogger.debug("prompt:",your_args)logger.info("prompt:",your_args)logger.warning("prompt:",your_args)logger.success("prompt:",your_args)logger.error("prompt:",your_args)For other detailed APIs please check the code!
Package: colorlookup
This package provides an API for looking up hex, rgb, hsv, or hsl values of
W3C-recognized colors. The Color class, when initialized with a valid
identifier, will have as its attributes components of the various color model
representations.Example:To retrieve the numeric representations of the color brown as defined by
the W3C:>>> from colorlookup import Color
>>>
>>> brown = Color('brown')
>>>
>>> print(brown)
Color: Brown
hex: #a52a2a
rgb: (165, 42, 42)
>>>
>>> brown.hex
'#a52a2a'
>>> brown.rgb
(165, 42, 42)
>>> brown.r
165
>>> brown.g
42
>>> brown.b
42
>>> brown.rgb_f
(0.65, 0.16, 0.16)
>>> brown.r_f
0.65
>>> brown.g_f
0.16
>>> brown.b_f
0.6
>>> brown.hsl_sat
0.59
>>> brown.hsl_light
0.41
>>> brown.hsv_sat
0.75
>>> brown.hsv_val
0.65
Package: colorls
c*lsUses colour and pipes output to less, with a sensible prompt.Each command is equivalent to:-cls      ls -FC
clls     ls -lF --time-style=long-iso
cllls    ls -lF --time-style=full-iso
cals     ls -FCA
calls    ls -lFA --time-style=long-iso
callls   ls -lFA --time-style=full-iso
csls     sudo ls -FC
cslls    sudo ls -lF --time-style=long-iso
csllls   sudo ls -lF --time-style=full-iso
csals    sudo ls -FCA
csalls   sudo ls -lFA --time-style=long-iso
csallls  sudo ls -lFA --time-style=full-isoInstallationRunpip3 -VIf you get aCommand not founderror, runsudo apt install python3-pipand redo from startIf yourpipmajor version is less than 9, runpip3 install -U pip && hash -rRunpip3 install colorlsTO-DOLINK_COL_WIDTH(what does this mean??)Fix inum handlingCheck for numeric owner/groupUsetype -a python3andunset VIRTUAL_ENVwhen in a venv to break out of itDevelopmentPackage dependencies are handled bypipenv.
It is assumed thatpipenvwill manage the installation of all concrete
dependency versions.  setup.py reads the dependency info from Pipfile
via thepipenvpacakge.Before you can build the package, you will have to havemakeinstalled.  You can then runmake setupto create aVirtualenv(the.venvsubdirectory where packages and metadata will be installed)
and then. .venv/bin/activateto activate it.Then you can runpip install pipenv wheeland then use a build
process such as:-make build
make dist
# ... test .whl file now ...
make releaseCreditsThis package was created withCookiecutterand theaudreyr/cookiecutter-pypackageproject template.
Package: color-ls
colorlsPure Python implementation of ls command with colors and icons. Inspired fromcolorls. RequiresNerd Fontsfor icon/glyphs.Installationpip install color-lsUsageusage: lx [-h] [-1] [-a] [-B] [-d] [-f] [-F] [-I PATTERN] [-l] [-n] [-R] [--report] [-t [DEPTH]] [--version] [--si] FILE

positional arguments:
  FILE                  List information about the FILEs (the current directory by default).

optional arguments:
  -h, --help            show this help message and exit
  -1                    list items on individual lines
  -a, --all             do not ignore entires starting with .
  -B, --ignore-backups  do not list implied entires ending with ~
  -d, --directory       list directories themselves, not their contents
  -f, --file            list files only, not directories
  -F, --classify        append indicator (one of */=>@|) to entries
  -I PATTERN, --ignore PATTERN
                        do not list implied entries matching shell PATTERN
  -l, --long            use a long listing format
  -n, --numeric-uid-gid
                        like -l, but list numeric user and group IDs
  -R, --recursive       list subdirectories recursively
  --report              brief report about number of files and directories
  -t [DEPTH], --tree [DEPTH]
                        max tree depth
  --version             display current version number and exit
  --si                  display file size in SI unitsRequirementsPython 3.8 or higherNerd FontsLicenseMIT
Package: colormap
Please see :http://colormap.readthedocs.io/for an up-to-date documentation.version:Python 3.8, 3.9, 3.10, 3.11contributions:Please joinhttps://github.com/cokelaer/colormapissues:Please usehttps://github.com/cokelaer/colormap/issuesnotebook:Please seehttps://github.com/cokelaer/colormap/tree/master/notebooksWhat is it ?colormappackage provides simple utilities to convert colors between
RGB, HEX, HLS, HUV and a class to easily build colormaps for matplotlib. All
matplotlib colormaps and some R colormaps are available altogether. The
plot_colormap method (see below) is handy to quickly pick up a colormaps and
the test_colormap is useful to see test a new colormap.Installationpip install colormapExampleCreate your own colormap from red to green colors with intermediate color as
whitish (diverging map from red to green):c = Colormap()
mycmap = c.cmap( {'red':[1,1,0], 'green':[0,1,.39], 'blue':[0,1,0]})
cmap = c.test_colormap(mycmap)Even simpler if the colormap is linear:c = Colormap()
mycmap = c.cmap_linear('red', 'white', 'green(w3c)')
cmap = c.test_colormap(mycmap)check out the available colormaps:c = Colormap()
c.plot_colormap('diverging')See online documentation for details:http://colormap.readthedocs.io/changelogVersionDescription1.0.6Fix a matplotlib deprecationFix RTD documentation1.0.5remove Python3.6 and added Python3.10 to CI actionFix issue in setup reported inhttps://github.com/cokelaer/colormap/pull/14add requirements in MANIFESTapplied black on all files
Package: colormap2d
2D Colormapmatplotlibprovidesmany colormapsthat map scalars to colors. However, it does not provide such colormaps for 2D vectors. Representing 2D vectors as colors may be helpful when dealing with complex numbers or 2D coordinates. This library provides 2 colormaps for this purpose including a cyclic one.Installationpipinstallcolormap2dUsageimportnumpyasnpimportcolormap2dsome_2d_vectors=np.random.rand(5,2)# Random 2D vectors between 0 and 1:# array([[0.91270668, 0.60020465],#        [0.51569033, 0.79642031],#        [0.36533928, 0.31441287],#        [0.41346207, 0.45163162],#        [0.99135696, 0.05691322]])colormap2d.pinwheel(some_2d_vectors)# RGBA float values between 0 and 1 (default)# array([[0.69019608, 0.6627451 , 0.24705882, 1.        ],#        [0.25490196, 0.74509804, 0.82352941, 1.        ],#        [0.41960784, 0.2       , 0.79215686, 1.        ],#        [0.18823529, 0.29803922, 0.20392157, 1.        ],#        [0.24705882, 0.24705882, 0.66666667, 1.        ]])colormap2d.pinwheel(some_2d_vectors,mode="RGB",dtype=np.uint8)# RGB integers between 0 and 255:# array([[166, 179,  50],#        [ 50,  66,  94],#        [ 63,  98, 212],#        [ 66,  66, 196],#        [222, 199, 169]], dtype=uint8)Behind the sceneThe colormap data has been created using Self-Organizing Maps.
Package: colormapize
AboutThis is a small package to easily generate colormaps from images which was
built as a fun hack and shouldnotbe used to generate colormaps for
serious visualization work since there is no guarantee that the colormaps
made will be e.g. perceptually uniform.InstallingTo install:pip install colormapizeUsingTo use, run:colormapize your_image.jpg colormap_namewherecolormap_nameis what you want to call your colormap, for example:colormapize your_image.jpg kittensThis should open a Matplotlib window. Click once to define the start of a path
and click again to define the end of the path. You can then use the + and - keys
to add more samples along the path. If you are not happy with the path, just
click twice again to define a new path. Once you are happy with it, press
‘enter’ or ‘c’ and you will see a preview of the colormap on the right of the
image, and the colormap will also be saved to e.g.``cmap_kittens.py``. You can
continue to redefine the path until you are happy with it, and the file will be
overwritten every time you press ‘enter’ or ‘c’. Close the window once you are
done.To use, make sure the colormap file (e.g.cmap_kittens.py) is in the same
directory as the directory where you want to make plots, and you can then use it
as follows in other scripts:import colormap_kittens

...

plt.imshow(mydata, cmap='kittens')