Commit 7cb75c68 authored by Fize Jacques's avatar Fize Jacques

Debug

parent 090f3653
......@@ -116,7 +116,7 @@ cdef class DeepWalk(Base):
def extract_embedding(self, listgs):
from tqdm import tqdm
models = Parallel(n_jobs = cpu_count())(delayed(process)(nx.Graph(g)) for g in tqdm(listgs,desc="Extracting Embeddings..."))
models = [process(nx.Graph(g)) for g in tqdm(listgs,desc="Extracting Embeddings...")]
return models
@cython.boundscheck(False)
......
......@@ -89,7 +89,7 @@ def generate_model(graphs, iteration = 2, dimensions = 64, min_count = 5, down_s
Main function to read the graph list, extract features, learn the embedding and save it.
:param args: Object with the arguments.
"""
document_collections = Parallel(n_jobs = workers)(delayed(feature_extractor)(g, ix,iteration) for ix,g in tqdm(enumerate(graphs),desc="Extracting Features..."))
document_collections = [feature_extractor(g, ix,iteration) for ix,g in tqdm(enumerate(graphs),desc="Extracting Features...")]
graphs=[nx.relabel_nodes(g,{node:str(node) for node in list(g.nodes)},copy=True) for g in graphs]
model = Doc2Vec(document_collections,
vector_size = dimensions,
......
......@@ -58,7 +58,7 @@ this_directory = path.abspath(path.dirname(__file__))
with open(path.join(this_directory, 'README.md'), encoding='utf-8') as f:
long_description = f.read()
requirements=["numpy","networkx","scipy",'scikit-learn','tqdm','pandas',"joblib","gensim"]
requirements=["numpy","networkx","scipy",'scikit-learn','tqdm','pandas',"joblib","gensim","psutil"]
setup(
name="GMatch4py",
author="Jacques Fize",
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment