ahmaurya / topics_over_time Goto Github PK
View Code? Open in Web Editor NEWTopics over Time implementation
Topics over Time implementation
I have following two question regarding updating of parameter psi :
Why 1 is added to psi[i][0] and psi[i][1] in GetMethodOfMomentsEstimatesForPsi apart from other factor mentioned in the paper ?
psi[i][0] = 1 + timestamp_mean_common_factor
psi[i][1] = 1 + (1-timestamp_mean)_common_factor
Why time stamp is updated once for every document rather than updating for each word of every document in TopicsOverTimeGibbsSampling ?
par['psi'] = self.GetMethodOfMomentsEstimatesForPsi(par)
Thanks
Hello,
I run the code ,after a while, the Terminal tell me that there is an error:
in TopicsOverTimeGibbsSampling
new_topic = list(np.random.multinomial(1, topic_probabilities, size=1)[0]).index(1)
ValueError: 1 is not in list
Can you tell me why the error will happen? Thanks very much!
Hello,
I am noticing some duplication in the code for tot.py
which doesn't seem right.
Lines 32-33 show:
for line in fileinput.input(stopwords_path):
stopwords.update(set(line.lower().strip().split()))
which seems to repeat in lines 42-43:
for line in fileinput.input(stopwords_path):
stopwords.update(Set(line.lower().strip().split()))
with the difference being the use of Set
in line 43 vs the uset of set
in line 33.
As far as I know there is no Set
construct in Python, so that's likely an error.
I assume the latter code duplicate can be deleted as it's erroneous?
Pls, can we get an evaluation metrics for the model?
Hi, I am trying your code. I wonder whether the number before the time in file alltimes
is necessary? For instance, you have experimented the email data, what is the number in that case? Thank you in advance!
Hello, your project is really a good job. I wonder can I use the trained model(pans_tot) on a tweets dataset? If so, how should I preprocess my dataset?
Thanks!
I want to know if I can get the words change of a topic over time.
hello,i got a problem like that
Traceback (most recent call last): File "main_pnas.py", line 44, in <module> main() File "main_pnas.py", line 33, in main documents, timestamps, dictionary = tot.GetPnasCorpusAndDictionary(documents_path, timestamps_path, stopwords_path) File "/home/mere/topics_over_time/src/tot.py", line 43, in GetPnasCorpusAndDictionary stopwords.update(Set(line.lower().strip().split())) NameError: name 'Set' is not defined
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.