An ESA implementation in python.
Project description
Get the required resources
scp -r webis@webislab40.medien.uni-weimar.de:/home/weci2587/projects/args-topic-modeling/resources .
To run the ESA-script with all terms run:
For normal ESA:
./esa-all-terms.py --similarity cos
--matrix-path <path_to_resources>/resources/esa-plain/<debatepedia|strategic-intelligence|wikipedia>.mat
--model-path <path_to_resources>/resources/esa-w2v/GoogleNews-vectors-negative300.bin
--model-vocab <path_to_resources>/resources/esa-w2v/w2v-vocab.p
--input-path <path_to_input_file>
--output-path <path_to_output_file>
For word2vec-ESA:
./esa-all-terms.py --similarity max
--matrix-path <path_to_resources>/resources/esa-w2v/<debatepedia|strategic-intelligence|wikipedia>.mat
--model-path <path_to_resources>/resources/esa-w2v/GoogleNews-vectors-negative300.bin
--model-vocab <path_to_resources>/resources/esa-w2v/w2v-vocab.p
--input-path <path_to_input_file>
--output-path <path_to_output_file>
To run the word2vec-ESA with reduced terms run:
./esa-top-n-terms.py -n <number_of_terms>
--corpus-path <path_to_resources>/resources/corpora/<debatepedia|strategic-intelligence|wikipedia>.csv
--model-path <path_to_resources>/resources/esa-w2v/GoogleNews-vectors-negative300.bin
--model-vocab <path_to_resources>/resources/esa-w2v/w2v-vocab.p
--input-path <path_to_input_file>
--output-path <path_to_output_file>
The input document must be a csv file with "|" as the separator and must contain the column "document", which is used as the input text for the ESA.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for argument_esa_model-0.2.122.linux-x86_64.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | d3521f28e2df6537d7ff041b7c7e576e949f321ff680e7b6b55722ccaa023da0 |
|
MD5 | f0943f7264a43c8bf82d78e235de5347 |
|
BLAKE2b-256 | ac6ca207294a47a8558ec2b45d94faa1ffda109c56c8c2cd884289400618f945 |
Close
Hashes for argument_esa_model-0.2.122-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | c0d8320d61256ef9e90b5d126317970b1a40378fbd51dca25813edae46bacb01 |
|
MD5 | 61bc17c2e5abdd9f4778a9845c281155 |
|
BLAKE2b-256 | b81e68c7f7f35ff2a9bdc221c8449eba365fe4786169fac8a9e4f01f3d49a97a |