summaryrefslogtreecommitdiff
path: root/python-pyldavis.spec
blob: ec1748243a8cbc7560e9834b390a9d75e2da2aab (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
%global _empty_manifest_terminate_build 0
Name:		python-pyLDAvis
Version:	3.4.0
Release:	1
Summary:	Interactive topic model visualization. Port of the R package.
License:	BSD-3-Clause
URL:		https://github.com/bmabey/pyLDAvis
Source0:	https://mirrors.nju.edu.cn/pypi/web/packages/c8/87/c25ac784d4da5f63a7d8b4b9a51c931e9392a4984bec631ebb8cf5de8da6/pyLDAvis-3.4.0.tar.gz
BuildArch:	noarch

Requires:	python3-numpy
Requires:	python3-scipy
Requires:	python3-pandas
Requires:	python3-joblib
Requires:	python3-jinja2
Requires:	python3-numexpr
Requires:	python3-funcy
Requires:	python3-scikit-learn
Requires:	python3-gensim
Requires:	python3-setuptools

%description
Python library for interactive topic model visualization.
This is a port of the fabulous `R package <https://github.com/cpsievert/LDAvis>`_ by `Carson Sievert <https://cpsievert.me/>`__ and `Kenny Shirley <http://www.kennyshirley.com/>`__.
**pyLDAvis** is designed to help users interpret the topics in a topic model that has been fit to a corpus of text data. The package extracts information from a fitted LDA topic model to inform an interactive web-based visualization.
The visualization is intended to be used within an IPython notebook but can also be saved to a stand-alone HTML file for easy sharing.
Note: LDA stands for `latent Dirichlet allocation <https://en.wikipedia.org/wiki/Latent_Dirichlet_allocation>`_.
|version status| |build status| |docs|
Installation
~~~~~~~~~~~~~~~~~~~~~~
-  Stable version using pip:
    pip install pyldavis
-  Development version on GitHub
Clone the repository and run ``python setup.py``
Usage
~~~~~~~~~~~~~~~~~~~~~~
The best way to learn how to use **pyLDAvis** is to see it in action.
Check out this `notebook for an overview <http://nbviewer.ipython.org/github/bmabey/pyLDAvis/blob/master/notebooks/pyLDAvis_overview.ipynb>`__.
Refer to the `documentation <https://pyLDAvis.readthedocs.org>`__ for details.
For a concise explanation of the visualization see this
`vignette <http://cran.r-project.org/web/packages/LDAvis/vignettes/details.pdf>`__ from the LDAvis R package.
Video demos
~~~~~~~~~~~
Ben Mabey walked through the visualization in this short talk using a Hacker News corpus:
-  `Visualizing Topic Models <https://www.youtube.com/watch?v=tGxW2BzC_DU&index=4&list=PLykRMO7ZuHwP5cWnbEmP_mUIVgzd5DZgH>`__
-  `Notebook and visualization used in the demo <http://nbviewer.ipython.org/github/bmabey/hacker_news_topic_modelling/blob/master/HN%20Topic%20Model%20Talk.ipynb>`__
-  `Slide deck <https://speakerdeck.com/bmabey/visualizing-topic-models>`__
`Carson Sievert <https://cpsievert.me/>`__ created a video demoing the R package. The visualization is the same and so it applies equally to pyLDAvis:
-  `Visualizing & Exploring the Twenty Newsgroup Data <http://stat-graphics.org/movies/ldavis.html>`__
More documentation
~~~~~~~~~~~~~~~~~~
To read about the methodology behind pyLDAvis, see `the original
paper <http://nlp.stanford.edu/events/illvi2014/papers/sievert-illvi2014.pdf>`__,
which was presented at the `2014 ACL Workshop on Interactive Language
Learning, Visualization, and
Interfaces <http://nlp.stanford.edu/events/illvi2014/>`__ in Baltimore
on June 27, 2014.

%package -n python3-pyLDAvis
Summary:	Interactive topic model visualization. Port of the R package.
Provides:	python-pyLDAvis
BuildRequires:	python3-devel
BuildRequires:	python3-setuptools
BuildRequires:	python3-pip
%description -n python3-pyLDAvis
Python library for interactive topic model visualization.
This is a port of the fabulous `R package <https://github.com/cpsievert/LDAvis>`_ by `Carson Sievert <https://cpsievert.me/>`__ and `Kenny Shirley <http://www.kennyshirley.com/>`__.
**pyLDAvis** is designed to help users interpret the topics in a topic model that has been fit to a corpus of text data. The package extracts information from a fitted LDA topic model to inform an interactive web-based visualization.
The visualization is intended to be used within an IPython notebook but can also be saved to a stand-alone HTML file for easy sharing.
Note: LDA stands for `latent Dirichlet allocation <https://en.wikipedia.org/wiki/Latent_Dirichlet_allocation>`_.
|version status| |build status| |docs|
Installation
~~~~~~~~~~~~~~~~~~~~~~
-  Stable version using pip:
    pip install pyldavis
-  Development version on GitHub
Clone the repository and run ``python setup.py``
Usage
~~~~~~~~~~~~~~~~~~~~~~
The best way to learn how to use **pyLDAvis** is to see it in action.
Check out this `notebook for an overview <http://nbviewer.ipython.org/github/bmabey/pyLDAvis/blob/master/notebooks/pyLDAvis_overview.ipynb>`__.
Refer to the `documentation <https://pyLDAvis.readthedocs.org>`__ for details.
For a concise explanation of the visualization see this
`vignette <http://cran.r-project.org/web/packages/LDAvis/vignettes/details.pdf>`__ from the LDAvis R package.
Video demos
~~~~~~~~~~~
Ben Mabey walked through the visualization in this short talk using a Hacker News corpus:
-  `Visualizing Topic Models <https://www.youtube.com/watch?v=tGxW2BzC_DU&index=4&list=PLykRMO7ZuHwP5cWnbEmP_mUIVgzd5DZgH>`__
-  `Notebook and visualization used in the demo <http://nbviewer.ipython.org/github/bmabey/hacker_news_topic_modelling/blob/master/HN%20Topic%20Model%20Talk.ipynb>`__
-  `Slide deck <https://speakerdeck.com/bmabey/visualizing-topic-models>`__
`Carson Sievert <https://cpsievert.me/>`__ created a video demoing the R package. The visualization is the same and so it applies equally to pyLDAvis:
-  `Visualizing & Exploring the Twenty Newsgroup Data <http://stat-graphics.org/movies/ldavis.html>`__
More documentation
~~~~~~~~~~~~~~~~~~
To read about the methodology behind pyLDAvis, see `the original
paper <http://nlp.stanford.edu/events/illvi2014/papers/sievert-illvi2014.pdf>`__,
which was presented at the `2014 ACL Workshop on Interactive Language
Learning, Visualization, and
Interfaces <http://nlp.stanford.edu/events/illvi2014/>`__ in Baltimore
on June 27, 2014.

%package help
Summary:	Development documents and examples for pyLDAvis
Provides:	python3-pyLDAvis-doc
%description help
Python library for interactive topic model visualization.
This is a port of the fabulous `R package <https://github.com/cpsievert/LDAvis>`_ by `Carson Sievert <https://cpsievert.me/>`__ and `Kenny Shirley <http://www.kennyshirley.com/>`__.
**pyLDAvis** is designed to help users interpret the topics in a topic model that has been fit to a corpus of text data. The package extracts information from a fitted LDA topic model to inform an interactive web-based visualization.
The visualization is intended to be used within an IPython notebook but can also be saved to a stand-alone HTML file for easy sharing.
Note: LDA stands for `latent Dirichlet allocation <https://en.wikipedia.org/wiki/Latent_Dirichlet_allocation>`_.
|version status| |build status| |docs|
Installation
~~~~~~~~~~~~~~~~~~~~~~
-  Stable version using pip:
    pip install pyldavis
-  Development version on GitHub
Clone the repository and run ``python setup.py``
Usage
~~~~~~~~~~~~~~~~~~~~~~
The best way to learn how to use **pyLDAvis** is to see it in action.
Check out this `notebook for an overview <http://nbviewer.ipython.org/github/bmabey/pyLDAvis/blob/master/notebooks/pyLDAvis_overview.ipynb>`__.
Refer to the `documentation <https://pyLDAvis.readthedocs.org>`__ for details.
For a concise explanation of the visualization see this
`vignette <http://cran.r-project.org/web/packages/LDAvis/vignettes/details.pdf>`__ from the LDAvis R package.
Video demos
~~~~~~~~~~~
Ben Mabey walked through the visualization in this short talk using a Hacker News corpus:
-  `Visualizing Topic Models <https://www.youtube.com/watch?v=tGxW2BzC_DU&index=4&list=PLykRMO7ZuHwP5cWnbEmP_mUIVgzd5DZgH>`__
-  `Notebook and visualization used in the demo <http://nbviewer.ipython.org/github/bmabey/hacker_news_topic_modelling/blob/master/HN%20Topic%20Model%20Talk.ipynb>`__
-  `Slide deck <https://speakerdeck.com/bmabey/visualizing-topic-models>`__
`Carson Sievert <https://cpsievert.me/>`__ created a video demoing the R package. The visualization is the same and so it applies equally to pyLDAvis:
-  `Visualizing & Exploring the Twenty Newsgroup Data <http://stat-graphics.org/movies/ldavis.html>`__
More documentation
~~~~~~~~~~~~~~~~~~
To read about the methodology behind pyLDAvis, see `the original
paper <http://nlp.stanford.edu/events/illvi2014/papers/sievert-illvi2014.pdf>`__,
which was presented at the `2014 ACL Workshop on Interactive Language
Learning, Visualization, and
Interfaces <http://nlp.stanford.edu/events/illvi2014/>`__ in Baltimore
on June 27, 2014.

%prep
%autosetup -n pyLDAvis-3.4.0

%build
%py3_build

%install
%py3_install
install -d -m755 %{buildroot}/%{_pkgdocdir}
if [ -d doc ]; then cp -arf doc %{buildroot}/%{_pkgdocdir}; fi
if [ -d docs ]; then cp -arf docs %{buildroot}/%{_pkgdocdir}; fi
if [ -d example ]; then cp -arf example %{buildroot}/%{_pkgdocdir}; fi
if [ -d examples ]; then cp -arf examples %{buildroot}/%{_pkgdocdir}; fi
pushd %{buildroot}
if [ -d usr/lib ]; then
	find usr/lib -type f -printf "/%h/%f\n" >> filelist.lst
fi
if [ -d usr/lib64 ]; then
	find usr/lib64 -type f -printf "/%h/%f\n" >> filelist.lst
fi
if [ -d usr/bin ]; then
	find usr/bin -type f -printf "/%h/%f\n" >> filelist.lst
fi
if [ -d usr/sbin ]; then
	find usr/sbin -type f -printf "/%h/%f\n" >> filelist.lst
fi
touch doclist.lst
if [ -d usr/share/man ]; then
	find usr/share/man -type f -printf "/%h/%f.gz\n" >> doclist.lst
fi
popd
mv %{buildroot}/filelist.lst .
mv %{buildroot}/doclist.lst .

%files -n python3-pyLDAvis -f filelist.lst
%dir %{python3_sitelib}/*

%files help -f doclist.lst
%{_docdir}/*

%changelog
* Mon Apr 10 2023 Python_Bot <Python_Bot@openeuler.org> - 3.4.0-1
- Package Spec generated