Module Expr Str Import alias Import alias identifier Import alias identifier Import alias ImportFrom alias FunctionDef arguments args NameParam defaults body Assign NameStore Call AttributeLoad Call AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr With AttributeLoad NameLoad attr body Assign NameStore IfExp CompareLt AttributeLoad NameLoad attr Str AttributeLoad NameLoad attr AttributeLoad AttributeLoad NameLoad attr attr Expr Call AttributeLoad NameLoad attr NameLoad keyword Str decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Str Assign NameStore Str Assign NameStore Call AttributeLoad NameLoad attr keyword NameLoad Expr Call AttributeLoad NameLoad attr Str keyword Str keyword Call AttributeLoad NameLoad attr keyword Str keyword Str Expr Call AttributeLoad NameLoad attr Str keyword Str keyword Call AttributeLoad NameLoad attr keyword Str Expr Call AttributeLoad NameLoad attr Str keyword Str keyword Call AttributeLoad NameLoad attr Str keyword Str keyword Str Expr Call AttributeLoad NameLoad attr Str keyword Str keyword Str keyword Str Expr Call AttributeLoad NameLoad attr Str keyword Str keyword Call AttributeLoad NameLoad attr keyword Str Expr Call AttributeLoad NameLoad attr Str keyword Str keyword Call AttributeLoad NameLoad attr keyword Str Expr Call AttributeLoad NameLoad attr Str keyword NameLoad keyword Num keyword Str keyword Str Expr Call AttributeLoad NameLoad attr Str keyword NameLoad keyword Num keyword Str keyword Str Expr Call AttributeLoad NameLoad attr Str keyword NameLoad keyword Num keyword Str keyword Str Expr Call AttributeLoad NameLoad attr Str keyword NameLoad keyword Num keyword Str keyword Str Expr Call AttributeLoad NameLoad attr Str keyword Str keyword Str Expr Call AttributeLoad NameLoad attr Str keyword Str keyword Str keyword NameLoad keyword Str keyword Str Assign NameStore Call AttributeLoad NameLoad attr NameLoad If BoolOpAnd AttributeLoad NameLoad attr AttributeLoad NameLoad attr body Raise Call NameLoad Str With AttributeLoad NameLoad attr body Assign AttributeStore NameLoad attr Call AttributeLoad AttributeLoad NameLoad attr attr If AttributeLoad NameLoad attr body With AttributeLoad NameLoad attr body Assign AttributeStore NameLoad attr Call NameLoad Call NameLoad AttributeLoad NameLoad attr Call AttributeLoad AttributeLoad NameLoad attr attr If AttributeLoad NameLoad attr body Assign AttributeStore NameLoad attr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Assign NameStore AttributeLoad NameLoad attr If AttributeLoad NameLoad attr body Assign NameStore Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr NameLoad If AttributeLoad NameLoad attr body Assign NameStore Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr NameLoad Return NameLoad decorator_list If CompareEq NameLoad Str body Expr Call NameLoad Call NameLoad SubscriptLoad AttributeLoad NameLoad attr Slice Num
N/A N/A Command-line tool to generate word clouds
Usage::
    $ cat word.txt | wordcloud_cli.py

    $ wordcloud_cli.py --text=words.txt --stopwords=stopwords.txt
 N/A argparse N/A wordcloud wc N/A numpy np N/A sys PIL Image main N/A N/A args N/A N/A N/A wordcloud N/A N/A N/A N/A wc WordCloud stopwords N/A args stopwords mask N/A args mask width N/A args width height N/A args height font_path N/A args font_path margin N/A args margin relative_scaling N/A args relative_scaling color_func N/A args color_func background_color N/A args background_color generate N/A args text N/A image N/A N/A wordcloud to_image N/A N/A args imagefile N/A N/A out N/A N/A N/A sys version 3 N/A args imagefile N/A N/A args imagefile buffer N/A N/A N/A image save out format png N/A parse_args N/A N/A arguments N/A N/A N/A prog python wordcloud_cli.py N/A description A simple command line interface for wordcloud module. N/A parser N/A N/A argparse ArgumentParser description description N/A N/A N/A parser add_argument --text metavar file type N/A N/A argparse FileType default - help specify file of words to build the word cloud (default: stdin) N/A N/A N/A parser add_argument --stopwords metavar file type N/A N/A argparse FileType help specify file of stopwords (containing one word per line) to remove from the given text after parsing N/A N/A N/A parser add_argument --imagefile metavar file type N/A N/A argparse FileType w default - help file the completed PNG image should be written to (default: stdout) N/A N/A N/A parser add_argument --fontfile metavar path dest font_path help path to font file you wish to use (default: DroidSansMono) N/A N/A N/A parser add_argument --mask metavar file type N/A N/A argparse FileType help mask to use for the image form N/A N/A N/A parser add_argument --colormask metavar file type N/A N/A argparse FileType help color mask to use for image coloring N/A N/A N/A parser add_argument --relative_scaling type float default 0 metavar rs help  scaling of words by frequency (0 - 1) N/A N/A N/A parser add_argument --margin type int default 2 metavar width help spacing to leave around words N/A N/A N/A parser add_argument --width type int default 400 metavar width help define output image width N/A N/A N/A parser add_argument --height type int default 200 metavar height help define output image height N/A N/A N/A parser add_argument --color metavar color help use given color as coloring for the image - accepts any value from PIL.ImageColor.getcolor N/A N/A N/A parser add_argument --background metavar color default black type str dest background_color help use given color as background color for the image - accepts any value from PIL.ImageColor.getcolor N/A args N/A N/A parser parse_args arguments N/A N/A N/A args colormask N/A args color N/A N/A N/A ValueError specify either a color mask or a color function N/A N/A args text N/A N/A N/A args text N/A N/A N/A args text read N/A N/A args stopwords N/A N/A N/A args stopwords N/A N/A N/A args stopwords N/A set N/A map N/A str strip N/A N/A N/A args stopwords readlines N/A N/A args mask N/A N/A N/A args mask N/A N/A np array N/A N/A Image open N/A args mask N/A color_func N/A wc random_color_func N/A N/A args colormask N/A N/A image N/A N/A np array N/A N/A Image open N/A args colormask N/A color_func N/A N/A wc ImageColorGenerator image N/A N/A args color N/A N/A color_func N/A N/A wc get_single_color_func N/A args color N/A N/A args color_func color_func N/A args N/A N/A N/A __name__ __main__ N/A N/A N/A main N/A parse_args N/A N/A sys argv N/A 1