Discussion:
[gensim:11741] Redirecting Mallet log
Simón Roca
2018-11-01 10:32:04 UTC
Permalink
Hello there!

I'm working with the LdaMallet wrapper in order to check the LL/token
evolution among iterations.

My first thought was converting the model to a gensim LdaModel, but I think
I'm affected by issue #2069
<https://github.com/RaRe-Technologies/gensim/issues/2069>, still open (if
mallet was converging to a, roughly speaking, -8.5, after using
malletmodel2ldamodel bound I'll have -13, and the topics have changed).

However, my question ended up far from that:

During Mallet execution, gensim will execute mallet using check_output(cmd,
shell=True). This redirects the 'mallet log' to my shell, where is
displayed, but I'm not able to capture it with a logger, nor unix redirect
or tee commands.

Is there a way to capture this external log (and others) from a subprocess
call and save it to a file?

Thank you in advance!


Simón
--
You received this message because you are subscribed to the Google Groups "Gensim" group.
To unsubscribe from this group and stop receiving emails from it, send an email to gensim+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Loading...