-
Notifications
You must be signed in to change notification settings - Fork 19
launch don't work and index issues #4
Comments
The package was originally developed with Python2.7, and the error seems to
be some incompatible syntax error or tab/space conversion.
Let me know if that helps.
…On Sun, Sep 30, 2018 at 10:42 PM jorgecastillo2 ***@***.***> wrote:
Hi,
I running the instructions on windows 10, python 3.6. After editing the
rint command (because we know that there is a change on it), I keep get the
following errors after launch the command:
Traceback (most recent call last):
File "C:\Users\Jorge
Castillo\AppData\Local\Programs\Python\Python36\lib\runpy.py", line 183, in
_run_module_as_main
mod_name, mod_spec, code = _get_module_details(mod_name, _Error)
File "C:\Users\Jorge
Castillo\AppData\Local\Programs\Python\Python36\lib\runpy.py", line 153, in
_get_module_details
code = loader.get_code(mod_name)
File "", line 781, in get_code
File "", line 741, in source_to_code
File "", line 219, in _call_with_frames_removed
File "C:\Users\Jorge Castillo(...)\InfVocLDA-master\src\infvoc\launch.py",
line 232
gamma_path = os.path.join(output_directory, "gamma.txt")
^
SyntaxError: invalid syntax
I'm launching the command (following the instruction) on cmd windows, in
the source established (i.e.,
in *InfVocLDA-master\src*) and getting the error and can't installing.
Also, changing "python" with "py " don't fit the error. What I'm doing
wrong? Thanks for help.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#4>, or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAklRpUjbcNrc82UzXrpIxJOQ7RT7SO1ks5ugatHgaJpZM4XBaWF>
.
|
Hi kzhai, thanks for answering
Clearly, I must edit the lines 335 and 448 of hybrid.py in order to recognize valid indexes Edit: now I see, for both lines, that wordids is the problem but I don't know how to fix it. Edit 2: Curiosly, between lines 309 to 317 there is no error, specifically in 310 it's defined wordid and in 317 the sentence Thanks for your help and code developing. |
Hi, Jorge, The reason is the newer version of numpy enforces the data type to be explicitly defined, even creating from an all integer list. kzhai@MININT-LPGA1J7:/mnt/c/Users/kezhai/Workspace/PyInfVoc$ python3 -m launch_train --input_directory=./de-news/ --output_directory=./ --truncation_level=4000 --number_of_pics=10 --number_of_documents=9800 --training_iterations=100 --vocab_prune_interval=10 --batch_size=98 --alpha_beta=100
========== ========== ========== ========== ==========
output_directory=./de-news/18Oct03-231005-D9800-K10-T4000-P10-I10-B98-O100-t64-k0.75-at0.1-ab100/
input_directory=./de-news
corpus_name=de-news
dictionary_file=None
number_of_documents=9800
number_of_topics=10
truncation_level=4000
vocab_prune_interval=10
snapshot_interval=10
batch_size=98
training_iterations=100
tau=64.0
kappa=0.75
alpha_theta=0.1
alpha_beta=100.0
========== ========== ========== ========== ==========
successfully load all training documents...
select documents from 0 to 98
P-step, E-step and M-step take 0, 2, 0 seconds respectively...
vocabulary size = [1725, 1725, 1725, 1725, 1725, 1725, 1725, 1725, 1725, 1725]
training iteration 1 finished in 2.888820 seconds: epsilon = 0.043683
select documents from 98 to 196
P-step, E-step and M-step take 0, 2, 0 seconds respectively...
vocabulary size = [2582, 2582, 2582, 2582, 2582, 2582, 2582, 2582, 2582, 2582]
training iteration 2 finished in 3.002949 seconds: epsilon = 0.043186
select documents from 196 to 294
P-step, E-step and M-step take 0, 2, 0 seconds respectively...
vocabulary size = [3194, 3194, 3194, 3194, 3194, 3194, 3194, 3194, 3194, 3194]
training iteration 3 finished in 2.965397 seconds: epsilon = 0.042702
select documents from 294 to 392
P-step, E-step and M-step take 0, 4, 0 seconds respectively...
vocabulary size = [3654, 3654, 3654, 3654, 3654, 3654, 3654, 3654, 3654, 3654]
training iteration 4 finished in 4.734318 seconds: epsilon = 0.042230
select documents from 392 to 490
P-step, E-step and M-step take 0, 3, 0 seconds respectively... Thanks for digging into this, and feel free to let me know for any bugs. Best, |
Hi,
I running the instructions on windows 10, python 3.6. After editing the "print" command inside launch (because we know that there is a change on it), I keep get the following errors after launch the command:
I'm launching the command (following the instruction) on cmd windows, in the source established (i.e.,
in InfVocLDA-master\src) and getting the error and can't installing. Also, changing "python" with "py " don't fit the error. What I'm doing wrong? Thanks for help.
The text was updated successfully, but these errors were encountered: