Git Product home page Git Product logo

word_cloud_fa's Introduction

WordCloudFa

Downloads

This module is an easy-to-use wrapper for word_cloud module.

The original module doesn't support Farsi Texts. But by using WordCloudFa you can generate word clouds from texts those are including Persian and English words.

This module is not only a wrapper, but it adds some features to the original module.

How to Install

For installing this module on other operating systems, you can simply run

pip install wordcloud-fa.

This module tested on python 3

WordCloudFa depends on numpy and pillow.

Also you should have Hazm module. Normally, all of them will install automatically when you install this module using pip as described at the beginning of this section.

To save the wordcloud into a file, matplotlib can also be installed.

Attention

You need to have python-dev for python3 on your system. If you don't have it, you can install it on operating systems those using apt as the package manager (Like Ubuntu) by this command:

sudo apt-get install python3-dev

And you can install it on operating systems those using yum as the package manager (like RedHat, Fedora and ...) you can use the following command:

sudo yum install python3-devel

How to Use

For creating a word cloud from a text, first you should import the class into your code:

from wordcloud_fa import WordCloudFa

you can create an instance of this class like:

wordcloud = WordCloudFa()

You can pass different parameters to the constructor. For see full documents of them, you can see WordCloud Documentations

There are three parameters that are not in the original class.

First one is persian_normalize. If you pass this parameter with True value, your data will normalize by using Hazm normalizer. It's recommended to always pass this parameter. That will replace arabic letters with persian ones and do some other stuff. The default value of this parameter is False.

wordcloud = WordCloudFa(persian_normalize=True)

the second parameter is include_numbers that is not in the published original module. If you set this parameter to False, all Persian, Arabic and English numbers will remove from your data.

The default value of this parameter is True

wordcloud = WordCloudFa(include_numbers=False)

Common problem Hint:

The last and very important parameter is: no_reshape. The default value of the parameter is False. But if you see that the letters of the words in Farsi texts are separated in your local system, you should pass True value to this parameter.

wordcloud = WordCloudFa(no_reshape=True)

Generating Word Cloud from Text

for generating word cloud from a string, you can simply call generate method of you instance:

wordcloud = WordCloudFa(persian_normalize=True)
wc = wordcloud.generate(text)
image = wc.to_image()
image.show()
image.save('wordcloud.png')

Generating Word Cloud from Frequencies

You can generate a word cloud from frequencies. You can use the output of process_text method as frequencies. Also you can use any dictionary like this.

wordcloud = WordCloudFa()
frequencies = wordcloud.process_text(text)
wc = wordcloud.generate_from_frequencies(frequencies)

generate_from_frequencies method in this module will exclude stopwords. But the original module will not exclude them when you are using this method. Also you can use Persian words as keys in frequencies dict without any problem.

Working with Stopwords

Stopwords are the words that we don't want to consider. If you dan't pass any stopword, the default words in the stopwords file will consider as stopwords.

You don't want to use them at all and you want to choose your stopwords? you can simply set stopwords parameter when you are creating an instance from WordCloudFa and pass a set of words into it.

stop_words = set(['کلمه‌ی اول', 'کلمه‌ی دوم'])
wc = WordCloudFa(stopwords=stop_words)

If you want to add additional words to the default stopwords, you can simply call add_stop_words method on your instance of WordCloudFa and pass an iterable type (list, set, ...) into it.

wc = WordCloudFa()
wc.add_stop_words(['کلمه‌ی اول', 'کلمه‌ی دوم'])

Also you can add stopwords from a file. That file should include stopwords and each word should be in a separate line.

For that, you should use add_stop_words_from_file method. The only parameter of this

method is relative or absolute path to the stop words file.

wc = WordCloudFa()
wc.add_stop_words_from_file("stopwords.txt")

Mask Image

You can mask the final word cloud by an image. For example, the first image of this document is a wordcloud masked by an image of the map of Iran country. For setting a mask, you should pass the mask parameter.

But before, you first should be sure you have a black and white image. Because other images will not create a good result.

Then, you should convert that image to a numpy array. For that, you should do something like this:

import numpy as np
from PIL import Image

mask_array = np.array(Image.open("mask.png"))

You just should add those two imports, but you don't need to be worried about installing them, because those have been installed as dependencies of this module.

Then, you can pass that array to the constructor of the WordCloudFa class for masking the result.

wordcloud = WordCloudFa(mask=mask_array)

Now you can use your worldcloud instance as before.

Reshaping words

When you pass your texts into an instance of this class, all words will reshape for turning to a proper way for showing And avoiding the invalid shape of Persian or Arabic words (splitted and inverse letters).

If you want to do the same thing outside of this module, you can call reshape_words static method.

reshaped_words = WordCloudFa.reshape_words(['کلمه‌ی اول', 'کلمه‌ی دوم'])

this method gets an Iterable as input and returns a list of reshaped words.

DONT FORGET THAT YOU SHOULD NOT PASS RESHAPED WORDS TO THE METHODS OF THIS CLASS AND THIS STATIC METHOD IS ONLY FOR USAGES OUT OF THIS MODULE

Avoiding Dangerous non-ASCII characters

Some non-ASCII characters like emojies causing errors. By Default, those characters will remove from the input text (not when you are using the generate_from_frequencies method).

For disabling this feature, you can set the value of the remove_unhandled_utf_characters parameter to False when you are creating a new instance of the WordCloudFa.

Also you can access the compiled regex patten of those characters using the unhandled_characters_regex class attribute.

Examples

You can see Example codes in the Examples directory.

Font

The default font is an unknown! font that supports both Persian and English letters. So you don't need to pass a font for getting results. But if you want to change the font you can pass font_path parameter.

Persian Tutorial

If you want to read a brief tutorial about how to use this package in Farsi (Persian), you can click on this link.

Contribution

We want to keep this library fresh and useful for all Iranian developers. So we need your help for adding new features, fixing bugs and adding more documents.

You are wondering how you can contribute to this project? Here is a list of what you can do:

  1. Documents are not enough? You can help us by adding more documents.
  2. The current code could be better? You can make this cleaner or faster.
  3. Do you think one useful feature missed? You can open an issue and tell us about it.
  4. Did you find a good open and free font that supports Farsi and English? You can notify us by a pull request or if opening an issue

Common Problems

Farsi Letters are separated

If you see separated Farsi letters in your output, you should pass no_reshape=True parameter to your WordCoudFa constructor:

wordcloud = WordCloudFa(no_reshape=True)

I See Repeated Farsi Words

In some cases you may see repeated Farsi words in the output. For solving that problem, you should pass collocations=False Parameter to your WordCloudFa constructor:

wordcloud = WordCloudFa(collocations=False)

I Have Problem in Running Example Scripts

In some operating systems like Windows, you should specify the encoding of the example text files. If you can not open example files, add encoding="utf-8" to your open statements:

with open('persian-example.txt', 'r', encoding="utf-8") as file:

There is any problem?

If you have questions, find some bugs or need some features, you can open an issue and tell us. For some strange reasons this is not possible? so contact me by this email: [email protected].

Citations

Texts in the Example directory are from this and this Wikipedia pages.

word_cloud_fa's People

Contributors

aasmpro avatar alihoseiny avatar dependabot-preview[bot] avatar dependabot[bot] avatar rsharifnasab avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

word_cloud_fa's Issues

[BUG]

Describe the bug
For some texts code doesn't work and after few seconds it throws following exception.
AssertionError: LRI not allowed here
But when I write "no_reshape=True" in constructor the problem fixes but words appear unreshaped again like previous version.

To Reproduce
Steps to reproduce the behavior:
python 3,wordcloud-fa v0.1.6 on ubuntu v18.04
input: some persian texts.

Expected behavior
A good cloud like in the project README.

Reshaping does not work

Describe the bug
It is expected to reshape the words that appear in the Word Cloud, but words appear unreshaped and wrong-looking.

To Reproduce
Steps to reproduce the behavior:
Python 3.8, wordcloud_fa v0.1.5, arabic_reshaper v2.0.15 on macOS v10.15.3
Input: any persian text

Expected behavior
A good cloud as in the project README.

Screenshots
telegram-cloud-photo-size-4-5960644511078133959-y

Code

            width=900, height=900,
            background_color="white",
            font_path="assets/fonts/font2.ttf",
            mask = mask_array,
            persian_normalize=True,
            include_numbers=False,
        )

        word_cloud = wc.generate(text)

AssertionError: LRI not allowed here

Describe the bug
got this error while generating wordcloud from txt file.

To Reproduce

LRI not allowed here
Traceback (most recent call last):
  File "/home/runner/.local/share/virtualenvs/python3/lib/python3.8/site-packages/pyrogram/client/ext/dispatcher.py", line 199, in update_worker
    handler.callback(self.client, *args)
  File "main.py", line 37, in hello
    wc = wodcloud.generate(text)  File "/home/runner/.local/share/virtualenvs/python3/lib/python3.8/site-packages/wordcloud_fa/WordCloudFa.py", line 175, in generate
    return self.generate_from_text(text)
  File "/home/runner/.local/share/virtualenvs/python3/lib/python3.8/site-packages/wordcloud/wordcloud.py", line 601, in generate_from_text
    self.generate_from_frequencies(words)
  File "/home/runner/.local/share/virtualenvs/python3/lib/python3.8/site-packages/wordcloud_fa/WordCloudFa.py", line 161, in generate_from_frequencies
    words = WordCloudFa.reshape_words(words)
  File "/home/runner/.local/share/virtualenvs/python3/lib/python3.8/site-packages/wordcloud_fa/WordCloudFa.py", line 75, in reshape_words
    return get_display(arabic_reshaper.reshape(combined_words)).split("\n")
  File "/home/runner/.local/share/virtualenvs/python3/lib/python3.8/site-packages/bidi/algorithm.py", line 648, in get_display
    resolve_implicit_levels(storage, debug)
  File "/home/runner/.local/share/virtualenvs/python3/lib/python3.8/site-packages/bidi/algorithm.py", line 465, in resolve_implicit_levels
    assert _ch['type'] in ('L', 'R', 'EN', 'AN'),\
AssertionError: LRI not allowed here

Unexpected outcome

Describe the bug
I run the example codes but get different results. For example this is what I get with mixed-example code:

mixed-example

To Reproduce
Steps to reproduce the behavior:

  1. Running the same code as yours
  2. Your environment (python 3.7.5, Ubuntu 19.10)

Expected behavior
Of course to get same result as yours

Screenshots
shared above

Additional context
I run the code in virtualenv.

[BUG] wrong argument passed to function

Hi,

Describe the bug
Tried to run one of the examples (english-example.py) when I got the following error

Screenshots
Screenshot from 2020-05-20 20-07-44

Possible Fix

        if self.collocations:
            word_counts = unigrams_and_bigrams(words, self.normalize_plurals)
        else:
            word_counts, _ = process_tokens(words, self.normalize_plurals)

        return word_counts

The second argument passed to unigrams_and_bigrams function (line 134 WordCloudFa.py) is self.normalize_plurals by mistake. Changing it to self.stopwords seems to fix it.

خطا در نصب[BUG]

سلام
در نصب کتابخانه خطا زیر مشاهده می شود لطفا راهنمایی نمایید
ERROR: Command errored out with exit status 1:
command: 'c:\users\home\appdata\local\programs\python\python38\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\Users\home\AppData\Local\Temp\pip-install-2qflbnk8\wordcloud\setup.py'"'"'; file='"'"'C:\Users\home\AppData\Local\Temp\pip-install-2qflbnk8\wordcloud\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\home\AppData\Local\Temp\pip-record-d8sqakkd\install-record.txt' --single-version-externally-managed --compile --install-headers 'c:\users\home\appdata\local\programs\python\python38\Include\wordcloud'
cwd: C:\Users\home\AppData\Local\Temp\pip-install-2qflbnk8\wordcloud
Complete output (20 lines):
running install
running build
running build_py
creating build
creating build\lib.win-amd64-3.8
creating build\lib.win-amd64-3.8\wordcloud
copying wordcloud\color_from_image.py -> build\lib.win-amd64-3.8\wordcloud
copying wordcloud\tokenization.py -> build\lib.win-amd64-3.8\wordcloud
copying wordcloud\wordcloud.py -> build\lib.win-amd64-3.8\wordcloud
copying wordcloud\wordcloud_cli.py -> build\lib.win-amd64-3.8\wordcloud
copying wordcloud_version.py -> build\lib.win-amd64-3.8\wordcloud
copying wordcloud_init_.py -> build\lib.win-amd64-3.8\wordcloud
copying wordcloud_main_.py -> build\lib.win-amd64-3.8\wordcloud
copying wordcloud\stopwords -> build\lib.win-amd64-3.8\wordcloud
copying wordcloud\DroidSansMono.ttf -> build\lib.win-amd64-3.8\wordcloud
UPDATING build\lib.win-amd64-3.8\wordcloud/_version.py
set build\lib.win-amd64-3.8\wordcloud/_version.py to '1.7.0'
running build_ext
building 'wordcloud.query_integral_image' extension
error: Microsoft Visual C++ 14.0 is required. Get it with "Build Tools for Visual Studio": https://visualstudio.microsoft.com/downloads/
----------------------------------------
ERROR: Command errored out with exit status 1: 'c:\users\home\appdata\local\programs\python\python38\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\Users\home\AppData\Local\Temp\pip-install-2qflbnk8\wordcloud\setup.py'"'"'; file='"'"'C:\Users\home\AppData\Local\Temp\pip-install-2qflbnk8\wordcloud\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\home\AppData\Local\Temp\pip-record-d8sqakkd\install-record.txt' --single-version-externally-managed --compile --install-headers 'c:\users\home\appdata\local\programs\python\python38\Include\wordcloud' Check the logs for full command output.

Installing error with Python 3.9

I tried to install this module normally from pip. I use Python 3.9. Python3.9-dev is also installed. I got this error:

Building wheels for collected packages: wordcloud
  Building wheel for wordcloud (setup.py) ... error
  ERROR: Command errored out with exit status 1:
   command: /home/arma/PycharmProjects/mywordcloud/venv/bin/python -u -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-iwdsbzfw/wordcloud_6e3d26d001e24b08ad18bde6d595171e/setup.py'"'"'; __file__='"'"'/tmp/pip-install-iwdsbzfw/wordcloud_6e3d26d001e24b08ad18bde6d595171e/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(__file__) if os.path.exists(__file__) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' bdist_wheel -d /tmp/pip-wheel-bbdpu3zt
       cwd: /tmp/pip-install-iwdsbzfw/wordcloud_6e3d26d001e24b08ad18bde6d595171e/
  Complete output (155 lines):
  running bdist_wheel
  running build
  running build_py
  creating build
  creating build/lib.linux-x86_64-3.9
  creating build/lib.linux-x86_64-3.9/wordcloud
  copying wordcloud/_version.py -> build/lib.linux-x86_64-3.9/wordcloud
  copying wordcloud/__main__.py -> build/lib.linux-x86_64-3.9/wordcloud
  copying wordcloud/wordcloud.py -> build/lib.linux-x86_64-3.9/wordcloud
  copying wordcloud/color_from_image.py -> build/lib.linux-x86_64-3.9/wordcloud
  copying wordcloud/wordcloud_cli.py -> build/lib.linux-x86_64-3.9/wordcloud
  copying wordcloud/__init__.py -> build/lib.linux-x86_64-3.9/wordcloud
  copying wordcloud/tokenization.py -> build/lib.linux-x86_64-3.9/wordcloud
  copying wordcloud/stopwords -> build/lib.linux-x86_64-3.9/wordcloud
  copying wordcloud/DroidSansMono.ttf -> build/lib.linux-x86_64-3.9/wordcloud
  UPDATING build/lib.linux-x86_64-3.9/wordcloud/_version.py
  set build/lib.linux-x86_64-3.9/wordcloud/_version.py to '1.7.0'
  running build_ext
  building 'wordcloud.query_integral_image' extension
  creating build/temp.linux-x86_64-3.9
  creating build/temp.linux-x86_64-3.9/wordcloud
  x86_64-linux-gnu-gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O2 -Wall -g -ffile-prefix-map=/build/python3.9-1n6GrT/python3.9-3.9.5=. -fstack-protector-strong -Wformat -Werror=format-security -g -fwrapv -O2 -g -ffile-prefix-map=/build/python3.9-1n6GrT/python3.9-3.9.5=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -I/home/arma/PycharmProjects/mywordcloud/venv/include -I/usr/include/python3.9 -c wordcloud/query_integral_image.c -o build/temp.linux-x86_64-3.9/wordcloud/query_integral_image.o
  wordcloud/query_integral_image.c: In function ‘__Pyx_modinit_type_init_code’:
  wordcloud/query_integral_image.c:16523:25: error: ‘PyTypeObject’ {aka ‘struct _typeobject’} has no member named ‘tp_print’
  16523 |   __pyx_type___pyx_array.tp_print = 0;
        |                         ^
  wordcloud/query_integral_image.c:16528:31: error: ‘PyTypeObject’ {aka ‘struct _typeobject’} has no member named ‘tp_print’
  16528 |   __pyx_type___pyx_MemviewEnum.tp_print = 0;
        |                               ^
  wordcloud/query_integral_image.c:16543:30: error: ‘PyTypeObject’ {aka ‘struct _typeobject’} has no member named ‘tp_print’
  16543 |   __pyx_type___pyx_memoryview.tp_print = 0;
        |                              ^
  wordcloud/query_integral_image.c:16556:35: error: ‘PyTypeObject’ {aka ‘struct _typeobject’} has no member named ‘tp_print’
  16556 |   __pyx_type___pyx_memoryviewslice.tp_print = 0;
        |                                   ^
  wordcloud/query_integral_image.c: In function ‘__Pyx_ParseOptionalKeywords’:
  wordcloud/query_integral_image.c:17126:21: warning: ‘_PyUnicode_get_wstr_length’ is deprecated [-Wdeprecated-declarations]
  17126 |                     (PyUnicode_GET_SIZE(**name) != PyUnicode_GET_SIZE(key)) ? 1 :
        |                     ^
  In file included from /usr/include/python3.9/unicodeobject.h:1026,
                   from /usr/include/python3.9/Python.h:97,
                   from wordcloud/query_integral_image.c:4:
  /usr/include/python3.9/cpython/unicodeobject.h:446:26: note: declared here
    446 | static inline Py_ssize_t _PyUnicode_get_wstr_length(PyObject *op) {
        |                          ^~~~~~~~~~~~~~~~~~~~~~~~~~
  wordcloud/query_integral_image.c:17126:21: warning: ‘PyUnicode_AsUnicode’ is deprecated [-Wdeprecated-declarations]
  17126 |                     (PyUnicode_GET_SIZE(**name) != PyUnicode_GET_SIZE(key)) ? 1 :
        |                     ^
  In file included from /usr/include/python3.9/unicodeobject.h:1026,
                   from /usr/include/python3.9/Python.h:97,
                   from wordcloud/query_integral_image.c:4:
  /usr/include/python3.9/cpython/unicodeobject.h:580:45: note: declared here
    580 | Py_DEPRECATED(3.3) PyAPI_FUNC(Py_UNICODE *) PyUnicode_AsUnicode(
        |                                             ^~~~~~~~~~~~~~~~~~~
  wordcloud/query_integral_image.c:17126:21: warning: ‘_PyUnicode_get_wstr_length’ is deprecated [-Wdeprecated-declarations]
  17126 |                     (PyUnicode_GET_SIZE(**name) != PyUnicode_GET_SIZE(key)) ? 1 :
        |                     ^
  In file included from /usr/include/python3.9/unicodeobject.h:1026,
                   from /usr/include/python3.9/Python.h:97,
                   from wordcloud/query_integral_image.c:4:
  /usr/include/python3.9/cpython/unicodeobject.h:446:26: note: declared here
    446 | static inline Py_ssize_t _PyUnicode_get_wstr_length(PyObject *op) {
        |                          ^~~~~~~~~~~~~~~~~~~~~~~~~~
  wordcloud/query_integral_image.c:17126:21: warning: ‘_PyUnicode_get_wstr_length’ is deprecated [-Wdeprecated-declarations]
  17126 |                     (PyUnicode_GET_SIZE(**name) != PyUnicode_GET_SIZE(key)) ? 1 :
        |                     ^
  In file included from /usr/include/python3.9/unicodeobject.h:1026,
                   from /usr/include/python3.9/Python.h:97,
                   from wordcloud/query_integral_image.c:4:
  /usr/include/python3.9/cpython/unicodeobject.h:446:26: note: declared here
    446 | static inline Py_ssize_t _PyUnicode_get_wstr_length(PyObject *op) {
        |                          ^~~~~~~~~~~~~~~~~~~~~~~~~~
  wordcloud/query_integral_image.c:17126:21: warning: ‘PyUnicode_AsUnicode’ is deprecated [-Wdeprecated-declarations]
  17126 |                     (PyUnicode_GET_SIZE(**name) != PyUnicode_GET_SIZE(key)) ? 1 :
        |                     ^
  In file included from /usr/include/python3.9/unicodeobject.h:1026,
                   from /usr/include/python3.9/Python.h:97,
                   from wordcloud/query_integral_image.c:4:
  /usr/include/python3.9/cpython/unicodeobject.h:580:45: note: declared here
    580 | Py_DEPRECATED(3.3) PyAPI_FUNC(Py_UNICODE *) PyUnicode_AsUnicode(
        |                                             ^~~~~~~~~~~~~~~~~~~
  wordcloud/query_integral_image.c:17126:21: warning: ‘_PyUnicode_get_wstr_length’ is deprecated [-Wdeprecated-declarations]
  17126 |                     (PyUnicode_GET_SIZE(**name) != PyUnicode_GET_SIZE(key)) ? 1 :
        |                     ^
  In file included from /usr/include/python3.9/unicodeobject.h:1026,
                   from /usr/include/python3.9/Python.h:97,
                   from wordcloud/query_integral_image.c:4:
  /usr/include/python3.9/cpython/unicodeobject.h:446:26: note: declared here
    446 | static inline Py_ssize_t _PyUnicode_get_wstr_length(PyObject *op) {
        |                          ^~~~~~~~~~~~~~~~~~~~~~~~~~
  wordcloud/query_integral_image.c:17142:25: warning: ‘_PyUnicode_get_wstr_length’ is deprecated [-Wdeprecated-declarations]
  17142 |                         (PyUnicode_GET_SIZE(**argname) != PyUnicode_GET_SIZE(key)) ? 1 :
        |                         ^
  In file included from /usr/include/python3.9/unicodeobject.h:1026,
                   from /usr/include/python3.9/Python.h:97,
                   from wordcloud/query_integral_image.c:4:
  /usr/include/python3.9/cpython/unicodeobject.h:446:26: note: declared here
    446 | static inline Py_ssize_t _PyUnicode_get_wstr_length(PyObject *op) {
        |                          ^~~~~~~~~~~~~~~~~~~~~~~~~~
  wordcloud/query_integral_image.c:17142:25: warning: ‘PyUnicode_AsUnicode’ is deprecated [-Wdeprecated-declarations]
  17142 |                         (PyUnicode_GET_SIZE(**argname) != PyUnicode_GET_SIZE(key)) ? 1 :
        |                         ^
  In file included from /usr/include/python3.9/unicodeobject.h:1026,
                   from /usr/include/python3.9/Python.h:97,
                   from wordcloud/query_integral_image.c:4:
  /usr/include/python3.9/cpython/unicodeobject.h:580:45: note: declared here
    580 | Py_DEPRECATED(3.3) PyAPI_FUNC(Py_UNICODE *) PyUnicode_AsUnicode(
        |                                             ^~~~~~~~~~~~~~~~~~~
  wordcloud/query_integral_image.c:17142:25: warning: ‘_PyUnicode_get_wstr_length’ is deprecated [-Wdeprecated-declarations]
  17142 |                         (PyUnicode_GET_SIZE(**argname) != PyUnicode_GET_SIZE(key)) ? 1 :
        |                         ^
  In file included from /usr/include/python3.9/unicodeobject.h:1026,
                   from /usr/include/python3.9/Python.h:97,
                   from wordcloud/query_integral_image.c:4:
  /usr/include/python3.9/cpython/unicodeobject.h:446:26: note: declared here
    446 | static inline Py_ssize_t _PyUnicode_get_wstr_length(PyObject *op) {
        |                          ^~~~~~~~~~~~~~~~~~~~~~~~~~
  wordcloud/query_integral_image.c:17142:25: warning: ‘_PyUnicode_get_wstr_length’ is deprecated [-Wdeprecated-declarations]
  17142 |                         (PyUnicode_GET_SIZE(**argname) != PyUnicode_GET_SIZE(key)) ? 1 :
        |                         ^
  In file included from /usr/include/python3.9/unicodeobject.h:1026,
                   from /usr/include/python3.9/Python.h:97,
                   from wordcloud/query_integral_image.c:4:
  /usr/include/python3.9/cpython/unicodeobject.h:446:26: note: declared here
    446 | static inline Py_ssize_t _PyUnicode_get_wstr_length(PyObject *op) {
        |                          ^~~~~~~~~~~~~~~~~~~~~~~~~~
  wordcloud/query_integral_image.c:17142:25: warning: ‘PyUnicode_AsUnicode’ is deprecated [-Wdeprecated-declarations]
  17142 |                         (PyUnicode_GET_SIZE(**argname) != PyUnicode_GET_SIZE(key)) ? 1 :
        |                         ^
  In file included from /usr/include/python3.9/unicodeobject.h:1026,
                   from /usr/include/python3.9/Python.h:97,
                   from wordcloud/query_integral_image.c:4:
  /usr/include/python3.9/cpython/unicodeobject.h:580:45: note: declared here
    580 | Py_DEPRECATED(3.3) PyAPI_FUNC(Py_UNICODE *) PyUnicode_AsUnicode(
        |                                             ^~~~~~~~~~~~~~~~~~~
  wordcloud/query_integral_image.c:17142:25: warning: ‘_PyUnicode_get_wstr_length’ is deprecated [-Wdeprecated-declarations]
  17142 |                         (PyUnicode_GET_SIZE(**argname) != PyUnicode_GET_SIZE(key)) ? 1 :
        |                         ^
  In file included from /usr/include/python3.9/unicodeobject.h:1026,
                   from /usr/include/python3.9/Python.h:97,
                   from wordcloud/query_integral_image.c:4:
  /usr/include/python3.9/cpython/unicodeobject.h:446:26: note: declared here
    446 | static inline Py_ssize_t _PyUnicode_get_wstr_length(PyObject *op) {
        |                          ^~~~~~~~~~~~~~~~~~~~~~~~~~
  wordcloud/query_integral_image.c: In function ‘__Pyx_decode_c_string’:
  wordcloud/query_integral_image.c:18051:9: warning: ‘PyUnicode_FromUnicode’ is deprecated [-Wdeprecated-declarations]
  18051 |         return PyUnicode_FromUnicode(NULL, 0);
        |         ^~~~~~
  In file included from /usr/include/python3.9/unicodeobject.h:1026,
                   from /usr/include/python3.9/Python.h:97,
                   from wordcloud/query_integral_image.c:4:
  /usr/include/python3.9/cpython/unicodeobject.h:551:42: note: declared here
    551 | Py_DEPRECATED(3.3) PyAPI_FUNC(PyObject*) PyUnicode_FromUnicode(
        |                                          ^~~~~~~~~~~~~~~~~~~~~
  error: command '/usr/bin/x86_64-linux-gnu-gcc' failed with exit code 1
  ----------------------------------------
  ERROR: Failed building wheel for wordcloud
  Running setup.py clean for wordcloud
Failed to build wordcloud
Installing collected packages: wordcloud, python-bidi, hazm, arabic-reshaper, wordcloud-fa
    Running setup.py install for wordcloud ... error
    ERROR: Command errored out with exit status 1:
     command: /home/arma/PycharmProjects/mywordcloud/venv/bin/python -u -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-iwdsbzfw/wordcloud_6e3d26d001e24b08ad18bde6d595171e/setup.py'"'"'; __file__='"'"'/tmp/pip-install-iwdsbzfw/wordcloud_6e3d26d001e24b08ad18bde6d595171e/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(__file__) if os.path.exists(__file__) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /tmp/pip-record-lxs19u47/install-record.txt --single-version-externally-managed --compile --install-headers /home/arma/PycharmProjects/mywordcloud/venv/include/site/python3.9/wordcloud
         cwd: /tmp/pip-install-iwdsbzfw/wordcloud_6e3d26d001e24b08ad18bde6d595171e/
    Complete output (155 lines):
    running install
    running build
    running build_py
    creating build
    creating build/lib.linux-x86_64-3.9
    creating build/lib.linux-x86_64-3.9/wordcloud
    copying wordcloud/_version.py -> build/lib.linux-x86_64-3.9/wordcloud
    copying wordcloud/__main__.py -> build/lib.linux-x86_64-3.9/wordcloud
    copying wordcloud/wordcloud.py -> build/lib.linux-x86_64-3.9/wordcloud
    copying wordcloud/color_from_image.py -> build/lib.linux-x86_64-3.9/wordcloud
    copying wordcloud/wordcloud_cli.py -> build/lib.linux-x86_64-3.9/wordcloud
    copying wordcloud/__init__.py -> build/lib.linux-x86_64-3.9/wordcloud
    copying wordcloud/tokenization.py -> build/lib.linux-x86_64-3.9/wordcloud
    copying wordcloud/stopwords -> build/lib.linux-x86_64-3.9/wordcloud
    copying wordcloud/DroidSansMono.ttf -> build/lib.linux-x86_64-3.9/wordcloud
    UPDATING build/lib.linux-x86_64-3.9/wordcloud/_version.py
    set build/lib.linux-x86_64-3.9/wordcloud/_version.py to '1.7.0'
    running build_ext
    building 'wordcloud.query_integral_image' extension
    creating build/temp.linux-x86_64-3.9
    creating build/temp.linux-x86_64-3.9/wordcloud
    x86_64-linux-gnu-gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O2 -Wall -g -ffile-prefix-map=/build/python3.9-1n6GrT/python3.9-3.9.5=. -fstack-protector-strong -Wformat -Werror=format-security -g -fwrapv -O2 -g -ffile-prefix-map=/build/python3.9-1n6GrT/python3.9-3.9.5=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -I/home/arma/PycharmProjects/mywordcloud/venv/include -I/usr/include/python3.9 -c wordcloud/query_integral_image.c -o build/temp.linux-x86_64-3.9/wordcloud/query_integral_image.o
    wordcloud/query_integral_image.c: In function ‘__Pyx_modinit_type_init_code’:
    wordcloud/query_integral_image.c:16523:25: error: ‘PyTypeObject’ {aka ‘struct _typeobject’} has no member named ‘tp_print’
    16523 |   __pyx_type___pyx_array.tp_print = 0;
          |                         ^
    wordcloud/query_integral_image.c:16528:31: error: ‘PyTypeObject’ {aka ‘struct _typeobject’} has no member named ‘tp_print’
    16528 |   __pyx_type___pyx_MemviewEnum.tp_print = 0;
          |                               ^
    wordcloud/query_integral_image.c:16543:30: error: ‘PyTypeObject’ {aka ‘struct _typeobject’} has no member named ‘tp_print’
    16543 |   __pyx_type___pyx_memoryview.tp_print = 0;
          |                              ^
    wordcloud/query_integral_image.c:16556:35: error: ‘PyTypeObject’ {aka ‘struct _typeobject’} has no member named ‘tp_print’
    16556 |   __pyx_type___pyx_memoryviewslice.tp_print = 0;
          |                                   ^
    wordcloud/query_integral_image.c: In function ‘__Pyx_ParseOptionalKeywords’:
    wordcloud/query_integral_image.c:17126:21: warning: ‘_PyUnicode_get_wstr_length’ is deprecated [-Wdeprecated-declarations]
    17126 |                     (PyUnicode_GET_SIZE(**name) != PyUnicode_GET_SIZE(key)) ? 1 :
          |                     ^
    In file included from /usr/include/python3.9/unicodeobject.h:1026,
                     from /usr/include/python3.9/Python.h:97,
                     from wordcloud/query_integral_image.c:4:
    /usr/include/python3.9/cpython/unicodeobject.h:446:26: note: declared here
      446 | static inline Py_ssize_t _PyUnicode_get_wstr_length(PyObject *op) {
          |                          ^~~~~~~~~~~~~~~~~~~~~~~~~~
    wordcloud/query_integral_image.c:17126:21: warning: ‘PyUnicode_AsUnicode’ is deprecated [-Wdeprecated-declarations]
    17126 |                     (PyUnicode_GET_SIZE(**name) != PyUnicode_GET_SIZE(key)) ? 1 :
          |                     ^
    In file included from /usr/include/python3.9/unicodeobject.h:1026,
                     from /usr/include/python3.9/Python.h:97,
                     from wordcloud/query_integral_image.c:4:
    /usr/include/python3.9/cpython/unicodeobject.h:580:45: note: declared here
      580 | Py_DEPRECATED(3.3) PyAPI_FUNC(Py_UNICODE *) PyUnicode_AsUnicode(
          |                                             ^~~~~~~~~~~~~~~~~~~
    wordcloud/query_integral_image.c:17126:21: warning: ‘_PyUnicode_get_wstr_length’ is deprecated [-Wdeprecated-declarations]
    17126 |                     (PyUnicode_GET_SIZE(**name) != PyUnicode_GET_SIZE(key)) ? 1 :
          |                     ^
    In file included from /usr/include/python3.9/unicodeobject.h:1026,
                     from /usr/include/python3.9/Python.h:97,
                     from wordcloud/query_integral_image.c:4:
    /usr/include/python3.9/cpython/unicodeobject.h:446:26: note: declared here
      446 | static inline Py_ssize_t _PyUnicode_get_wstr_length(PyObject *op) {
          |                          ^~~~~~~~~~~~~~~~~~~~~~~~~~
    wordcloud/query_integral_image.c:17126:21: warning: ‘_PyUnicode_get_wstr_length’ is deprecated [-Wdeprecated-declarations]
    17126 |                     (PyUnicode_GET_SIZE(**name) != PyUnicode_GET_SIZE(key)) ? 1 :
          |                     ^
    In file included from /usr/include/python3.9/unicodeobject.h:1026,
                     from /usr/include/python3.9/Python.h:97,
                     from wordcloud/query_integral_image.c:4:
    /usr/include/python3.9/cpython/unicodeobject.h:446:26: note: declared here
      446 | static inline Py_ssize_t _PyUnicode_get_wstr_length(PyObject *op) {
          |                          ^~~~~~~~~~~~~~~~~~~~~~~~~~
    wordcloud/query_integral_image.c:17126:21: warning: ‘PyUnicode_AsUnicode’ is deprecated [-Wdeprecated-declarations]
    17126 |                     (PyUnicode_GET_SIZE(**name) != PyUnicode_GET_SIZE(key)) ? 1 :
          |                     ^
    In file included from /usr/include/python3.9/unicodeobject.h:1026,
                     from /usr/include/python3.9/Python.h:97,
                     from wordcloud/query_integral_image.c:4:
    /usr/include/python3.9/cpython/unicodeobject.h:580:45: note: declared here
      580 | Py_DEPRECATED(3.3) PyAPI_FUNC(Py_UNICODE *) PyUnicode_AsUnicode(
          |                                             ^~~~~~~~~~~~~~~~~~~
    wordcloud/query_integral_image.c:17126:21: warning: ‘_PyUnicode_get_wstr_length’ is deprecated [-Wdeprecated-declarations]
    17126 |                     (PyUnicode_GET_SIZE(**name) != PyUnicode_GET_SIZE(key)) ? 1 :
          |                     ^
    In file included from /usr/include/python3.9/unicodeobject.h:1026,
                     from /usr/include/python3.9/Python.h:97,
                     from wordcloud/query_integral_image.c:4:
    /usr/include/python3.9/cpython/unicodeobject.h:446:26: note: declared here
      446 | static inline Py_ssize_t _PyUnicode_get_wstr_length(PyObject *op) {
          |                          ^~~~~~~~~~~~~~~~~~~~~~~~~~
    wordcloud/query_integral_image.c:17142:25: warning: ‘_PyUnicode_get_wstr_length’ is deprecated [-Wdeprecated-declarations]
    17142 |                         (PyUnicode_GET_SIZE(**argname) != PyUnicode_GET_SIZE(key)) ? 1 :
          |                         ^
    In file included from /usr/include/python3.9/unicodeobject.h:1026,
                     from /usr/include/python3.9/Python.h:97,
                     from wordcloud/query_integral_image.c:4:
    /usr/include/python3.9/cpython/unicodeobject.h:446:26: note: declared here
      446 | static inline Py_ssize_t _PyUnicode_get_wstr_length(PyObject *op) {
          |                          ^~~~~~~~~~~~~~~~~~~~~~~~~~
    wordcloud/query_integral_image.c:17142:25: warning: ‘PyUnicode_AsUnicode’ is deprecated [-Wdeprecated-declarations]
    17142 |                         (PyUnicode_GET_SIZE(**argname) != PyUnicode_GET_SIZE(key)) ? 1 :
          |                         ^
    In file included from /usr/include/python3.9/unicodeobject.h:1026,
                     from /usr/include/python3.9/Python.h:97,
                     from wordcloud/query_integral_image.c:4:
    /usr/include/python3.9/cpython/unicodeobject.h:580:45: note: declared here
      580 | Py_DEPRECATED(3.3) PyAPI_FUNC(Py_UNICODE *) PyUnicode_AsUnicode(
          |                                             ^~~~~~~~~~~~~~~~~~~
    wordcloud/query_integral_image.c:17142:25: warning: ‘_PyUnicode_get_wstr_length’ is deprecated [-Wdeprecated-declarations]
    17142 |                         (PyUnicode_GET_SIZE(**argname) != PyUnicode_GET_SIZE(key)) ? 1 :
          |                         ^
    In file included from /usr/include/python3.9/unicodeobject.h:1026,
                     from /usr/include/python3.9/Python.h:97,
                     from wordcloud/query_integral_image.c:4:
    /usr/include/python3.9/cpython/unicodeobject.h:446:26: note: declared here
      446 | static inline Py_ssize_t _PyUnicode_get_wstr_length(PyObject *op) {
          |                          ^~~~~~~~~~~~~~~~~~~~~~~~~~
    wordcloud/query_integral_image.c:17142:25: warning: ‘_PyUnicode_get_wstr_length’ is deprecated [-Wdeprecated-declarations]
    17142 |                         (PyUnicode_GET_SIZE(**argname) != PyUnicode_GET_SIZE(key)) ? 1 :
          |                         ^
    In file included from /usr/include/python3.9/unicodeobject.h:1026,
                     from /usr/include/python3.9/Python.h:97,
                     from wordcloud/query_integral_image.c:4:
    /usr/include/python3.9/cpython/unicodeobject.h:446:26: note: declared here
      446 | static inline Py_ssize_t _PyUnicode_get_wstr_length(PyObject *op) {
          |                          ^~~~~~~~~~~~~~~~~~~~~~~~~~
    wordcloud/query_integral_image.c:17142:25: warning: ‘PyUnicode_AsUnicode’ is deprecated [-Wdeprecated-declarations]
    17142 |                         (PyUnicode_GET_SIZE(**argname) != PyUnicode_GET_SIZE(key)) ? 1 :
          |                         ^
    In file included from /usr/include/python3.9/unicodeobject.h:1026,
                     from /usr/include/python3.9/Python.h:97,
                     from wordcloud/query_integral_image.c:4:
    /usr/include/python3.9/cpython/unicodeobject.h:580:45: note: declared here
      580 | Py_DEPRECATED(3.3) PyAPI_FUNC(Py_UNICODE *) PyUnicode_AsUnicode(
          |                                             ^~~~~~~~~~~~~~~~~~~
    wordcloud/query_integral_image.c:17142:25: warning: ‘_PyUnicode_get_wstr_length’ is deprecated [-Wdeprecated-declarations]
    17142 |                         (PyUnicode_GET_SIZE(**argname) != PyUnicode_GET_SIZE(key)) ? 1 :
          |                         ^
    In file included from /usr/include/python3.9/unicodeobject.h:1026,
                     from /usr/include/python3.9/Python.h:97,
                     from wordcloud/query_integral_image.c:4:
    /usr/include/python3.9/cpython/unicodeobject.h:446:26: note: declared here
      446 | static inline Py_ssize_t _PyUnicode_get_wstr_length(PyObject *op) {
          |                          ^~~~~~~~~~~~~~~~~~~~~~~~~~
    wordcloud/query_integral_image.c: In function ‘__Pyx_decode_c_string’:
    wordcloud/query_integral_image.c:18051:9: warning: ‘PyUnicode_FromUnicode’ is deprecated [-Wdeprecated-declarations]
    18051 |         return PyUnicode_FromUnicode(NULL, 0);
          |         ^~~~~~
    In file included from /usr/include/python3.9/unicodeobject.h:1026,
                     from /usr/include/python3.9/Python.h:97,
                     from wordcloud/query_integral_image.c:4:
    /usr/include/python3.9/cpython/unicodeobject.h:551:42: note: declared here
      551 | Py_DEPRECATED(3.3) PyAPI_FUNC(PyObject*) PyUnicode_FromUnicode(
          |                                          ^~~~~~~~~~~~~~~~~~~~~
    error: command '/usr/bin/x86_64-linux-gnu-gcc' failed with exit code 1
    ----------------------------------------
ERROR: Command errored out with exit status 1: /home/arma/PycharmProjects/mywordcloud/venv/bin/python -u -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-iwdsbzfw/wordcloud_6e3d26d001e24b08ad18bde6d595171e/setup.py'"'"'; __file__='"'"'/tmp/pip-install-iwdsbzfw/wordcloud_6e3d26d001e24b08ad18bde6d595171e/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(__file__) if os.path.exists(__file__) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /tmp/pip-record-lxs19u47/install-record.txt --single-version-externally-managed --compile --install-headers /home/arma/PycharmProjects/mywordcloud/venv/include/site/python3.9/wordcloud Check the logs for full command output.

Is there any solution?

hi. my wordcludfa wont delete my stop words.

Describe the bug
A clear and concise description of what the bug is.

To Reproduce
Steps to reproduce the behavior:

  1. The code that produces the bug
  2. Your environment (python version, os, other modules and etc)
  3. Steps for reproducing the bug (input data, methods you should call and etc)
  4. Complete Error message
  5. Any other data that can help to reproduce the bug

Expected behavior
A clear and concise description of what you expected to happen.

Screenshots
If applicable, add screenshots to help explain your problem.

Additional context
Add any other context about the problem here.

bool error

با سلام موقع جنریت کردن ابر کلمه با ارور bool مواجه شدم :
argument of type 'bool' is not iterable

incompatibility with wordcloud >1.7.0

hi friends,
As you may know, your paramount package requires wordcloud 1.7.0 as its dependency. unfortunately, this package is not installed on python>=3.9. Do you have any suggestions other than changing the py version?

جدا نوشتن حروف

سلام
من از ورژن 1.6 استفاده میکنم و ویرایش جدید نصب نمی شود مشکل من الان جدا نوشتن حروف به شکل زیر است
persian-example

خطا نصب pip

سلام متاسفانه هنگام نصب برای من ارور زیر رو میده،تموم پیش نیاز ها مثل ویژوال سی پلاس و ... رو نصب کردم اما متاسفانه مشکل حل نشد:

`ERROR: Command errored out with exit status 1:
command: 'c:\users\mohammad malmir\appdata\local\programs\python\python39\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\Users\Mohammad Malmir\AppData\Local\Temp\pip-install-n1l4lar0\wordcloud\setup.py'"'"'; file='"'"'C:\Users\Mohammad Malmir\AppData\Local\Temp\pip-install-n1l4lar0\wordcloud\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(file);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' bdist_wheel -d 'C:\Users\Mohammad Malmir\AppData\Local\Temp\pip-wheel-53pqauqh'
cwd: C:\Users\Mohammad Malmir\AppData\Local\Temp\pip-install-n1l4lar0\wordcloud
Complete output (38 lines):
running bdist_wheel
running build
running build_py
creating build
creating build\lib.win-amd64-3.9
creating build\lib.win-amd64-3.9\wordcloud
copying wordcloud\color_from_image.py -> build\lib.win-amd64-3.9\wordcloud
copying wordcloud\tokenization.py -> build\lib.win-amd64-3.9\wordcloud
copying wordcloud\wordcloud.py -> build\lib.win-amd64-3.9\wordcloud
copying wordcloud\wordcloud_cli.py -> build\lib.win-amd64-3.9\wordcloud
copying wordcloud_version.py -> build\lib.win-amd64-3.9\wordcloud
copying wordcloud_init_.py -> build\lib.win-amd64-3.9\wordcloud
copying wordcloud_main_.py -> build\lib.win-amd64-3.9\wordcloud
copying wordcloud\stopwords -> build\lib.win-amd64-3.9\wordcloud
copying wordcloud\DroidSansMono.ttf -> build\lib.win-amd64-3.9\wordcloud
UPDATING build\lib.win-amd64-3.9\wordcloud/_version.py
set build\lib.win-amd64-3.9\wordcloud/_version.py to '1.7.0'
running build_ext
building 'wordcloud.query_integral_image' extension
creating build\temp.win-amd64-3.9
creating build\temp.win-amd64-3.9\Release
creating build\temp.win-amd64-3.9\Release\wordcloud
C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\VC\Tools\MSVC\14.28.29333\bin\HostX86\x64\cl.exe /c /nologo /Ox /W3 /GL /DNDEBUG /MD -Ic:\users\mohammad malmir\appdata\local\programs\python\python39\include -Ic:\users\mohammad malmir\appdata\local\programs\python\python39\include -IC:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\VC\Tools\MSVC\14.28.29333\include -IC:\Program Files (x86)\Windows Kits\10\include\10.0.18362.0\ucrt -IC:\Program Files (x86)\Windows Kits\10\include\10.0.18362.0\shared -IC:\Program Files (x86)\Windows Kits\10\include\10.0.18362.0\um -IC:\Program Files (x86)\Windows Kits\10\include\10.0.18362.0\winrt -IC:\Program Files (x86)\Windows Kits\10\include\10.0.18362.0\cppwinrt /Tcwordcloud/query_integral_image.c /Fobuild\temp.win-amd64-3.9\Release\wordcloud/query_integral_image.obj
query_integral_image.c
wordcloud/query_integral_image.c(2060): warning C4244: '=': conversion from 'Py_ssize_t' to 'int', possible loss of data
wordcloud/query_integral_image.c(2069): warning C4244: '=': conversion from 'Py_ssize_t' to 'int', possible loss of data
wordcloud/query_integral_image.c(16523): error C2039: 'tp_print': is not a member of '_typeobject'
c:\users\mohammad malmir\appdata\local\programs\python\python39\include\cpython/object.h(193): note: see declaration of '_typeobject'
wordcloud/query_integral_image.c(16528): error C2039: 'tp_print': is not a member of '_typeobject'
c:\users\mohammad malmir\appdata\local\programs\python\python39\include\cpython/object.h(193): note: see declaration of '_typeobject'
wordcloud/query_integral_image.c(16543): error C2039: 'tp_print': is not a member of '_typeobject'
c:\users\mohammad malmir\appdata\local\programs\python\python39\include\cpython/object.h(193): note: see declaration of '_typeobject'
wordcloud/query_integral_image.c(16556): error C2039: 'tp_print': is not a member of '_typeobject'
c:\users\mohammad malmir\appdata\local\programs\python\python39\include\cpython/object.h(193): note: see declaration of '_typeobject'
wordcloud/query_integral_image.c(17126): warning C4996: 'PyUnicode_get_wstr_length': deprecated in 3.3
wordcloud/query_integral_image.c(17142): warning C4996: 'PyUnicode_get_wstr_length': deprecated in 3.3
wordcloud/query_integral_image.c(18051): warning C4996: 'PyUnicode_FromUnicode': deprecated in 3.3
error: command 'C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\VC\Tools\MSVC\14.28.29333\bin\HostX86\x64\cl.exe' failed with exit code 2
ERROR: Failed building wheel for wordcloud
Running setup.py clean for wordcloud
Failed to build wordcloud
Installing collected packages: wordcloud, wordcloud-fa
Attempting uninstall: wordcloud
Found existing installation: wordcloud 1.8.1
Uninstalling wordcloud-1.8.1:
Successfully uninstalled wordcloud-1.8.1
Running setup.py install for wordcloud ... error
ERROR: Command errored out with exit status 1:
command: 'c:\users\mohammad malmir\appdata\local\programs\python\python39\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\Users\Mohammad Malmir\AppData\Local\Temp\pip-install-n1l4lar0\wordcloud\setup.py'"'"'; file='"'"'C:\Users\Mohammad Malmir\AppData\Local\Temp\pip-install-n1l4lar0\wordcloud\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\Mohammad Malmir\AppData\Local\Temp\pip-record-eu3t57xc\install-record.txt' --single-version-externally-managed --compile --install-headers 'c:\users\mohammad malmir\appdata\local\programs\python\python39\Include\wordcloud'
cwd: C:\Users\Mohammad Malmir\AppData\Local\Temp\pip-install-n1l4lar0\wordcloud
Complete output (38 lines):
running install
running build
running build_py
creating build
creating build\lib.win-amd64-3.9
creating build\lib.win-amd64-3.9\wordcloud
copying wordcloud\color_from_image.py -> build\lib.win-amd64-3.9\wordcloud
copying wordcloud\tokenization.py -> build\lib.win-amd64-3.9\wordcloud
copying wordcloud\wordcloud.py -> build\lib.win-amd64-3.9\wordcloud
copying wordcloud\wordcloud_cli.py -> build\lib.win-amd64-3.9\wordcloud
copying wordcloud_version.py -> build\lib.win-amd64-3.9\wordcloud
copying wordcloud_init
.py -> build\lib.win-amd64-3.9\wordcloud
copying wordcloud_main
.py -> build\lib.win-amd64-3.9\wordcloud
copying wordcloud\stopwords -> build\lib.win-amd64-3.9\wordcloud
copying wordcloud\DroidSansMono.ttf -> build\lib.win-amd64-3.9\wordcloud
UPDATING build\lib.win-amd64-3.9\wordcloud/_version.py
set build\lib.win-amd64-3.9\wordcloud/_version.py to '1.7.0'
running build_ext
building 'wordcloud.query_integral_image' extension
creating build\temp.win-amd64-3.9
creating build\temp.win-amd64-3.9\Release
creating build\temp.win-amd64-3.9\Release\wordcloud
C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\VC\Tools\MSVC\14.28.29333\bin\HostX86\x64\cl.exe /c /nologo /Ox /W3 /GL /DNDEBUG /MD -Ic:\users\mohammad malmir\appdata\local\programs\python\python39\include -Ic:\users\mohammad malmir\appdata\local\programs\python\python39\include -IC:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\VC\Tools\MSVC\14.28.29333\include -IC:\Program Files (x86)\Windows Kits\10\include\10.0.18362.0\ucrt -IC:\Program Files (x86)\Windows Kits\10\include\10.0.18362.0\shared -IC:\Program Files (x86)\Windows Kits\10\include\10.0.18362.0\um -IC:\Program Files (x86)\Windows Kits\10\include\10.0.18362.0\winrt -IC:\Program Files (x86)\Windows Kits\10\include\10.0.18362.0\cppwinrt /Tcwordcloud/query_integral_image.c /Fobuild\temp.win-amd64-3.9\Release\wordcloud/query_integral_image.obj
query_integral_image.c
wordcloud/query_integral_image.c(2060): warning C4244: '=': conversion from 'Py_ssize_t' to 'int', possible loss of data
wordcloud/query_integral_image.c(2069): warning C4244: '=': conversion from 'Py_ssize_t' to 'int', possible loss of data
wordcloud/query_integral_image.c(16523): error C2039: 'tp_print': is not a member of '_typeobject'
c:\users\mohammad malmir\appdata\local\programs\python\python39\include\cpython/object.h(193): note: see declaration of '_typeobject'
wordcloud/query_integral_image.c(16528): error C2039: 'tp_print': is not a member of '_typeobject'
c:\users\mohammad malmir\appdata\local\programs\python\python39\include\cpython/object.h(193): note: see declaration of '_typeobject'
wordcloud/query_integral_image.c(16543): error C2039: 'tp_print': is not a member of '_typeobject'
c:\users\mohammad malmir\appdata\local\programs\python\python39\include\cpython/object.h(193): note: see declaration of '_typeobject'
wordcloud/query_integral_image.c(16556): error C2039: 'tp_print': is not a member of '_typeobject'
c:\users\mohammad malmir\appdata\local\programs\python\python39\include\cpython/object.h(193): note: see declaration of '_typeobject'
wordcloud/query_integral_image.c(17126): warning C4996: '_PyUnicode_get_wstr_length': deprecated in 3.3
wordcloud/query_integral_image.c(17142): warning C4996: '_PyUnicode_get_wstr_length': deprecated in 3.3
wordcloud/query_integral_image.c(18051): warning C4996: 'PyUnicode_FromUnicode': deprecated in 3.3
error: command 'C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\VC\Tools\MSVC\14.28.29333\bin\HostX86\x64\cl.exe' failed with exit code 2

Rolling back uninstall of wordcloud
Moving to c:\users\mohammad malmir\appdata\local\programs\python\python39\lib\site-packages\wordcloud-1.8.1.dist-info
from C:\Users\Mohammad Malmir\AppData\Local\Programs\Python\Python39\Lib\site-packagesordcloud-1.8.1.dist-info
Moving to c:\users\mohammad malmir\appdata\local\programs\python\python39\lib\site-packages\wordcloud
from C:\Users\Mohammad Malmir\AppData\Local\Programs\Python\Python39\Lib\site-packages
ordcloud
Moving to c:\users\mohammad malmir\appdata\local\programs\python\python39\scripts\wordcloud_cli.exe
from C:\Users\Mohammad Malmir\AppData\Local\Temp\pip-uninstall-zgautptw\wordcloud_cli.exe
ERROR: Command errored out with exit status 1: 'c:\users\mohammad malmir\appdata\local\programs\python\python39\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\Users\Mohammad Malmir\AppData\Local\Temp\pip-install-n1l4lar0\wordcloud\setup.py'"'"'; file='"'"'C:\Users\Mohammad Malmir\AppData\Local\Temp\pip-install-n1l4lar0\wordcloud\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\Mohammad Malmir\AppData\Local\Temp\pip-record-eu3t57xc\install-record.txt' --single-version-externally-managed --compile --install-headers 'c:\users\mohammad malmir\appdata\local\programs\python\python39\Include\wordcloud' Check the logs for full command output.`

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.