580af77a96d8c6b306ad4425eafd7768df00338a,mordecai/geoparse.py,Geoparser,batch_geoparse,#Geoparser#Any#,984

Before Change


        

        nlped_docs = nlp.pipe(text_list, n_threads = self.n_threads)
        pool = ThreadPool(self.n_threads)
        processed = pool.map(self.geoparse, nlped_docs)
        pool.close()
        pool.join()
        return processed

After Change


        proced : list of list of dicts
            The list is the same length as the input list of documents. Each element is a list of geolocated entities.
        
        if not self.threads:
            print("Error: can"t run batch_geoparse without setting threads = True.")
            return
        nlped_docs = nlp.pipe(text_list, multiprocessing.cpu_count())
        //pool = ThreadPool(self.n_threads)
        //processed = pool.map(self.geoparse, nlped_docs)
        //pool.close()
        //pool.join()
        processed = [self.geoparse(i) for i in nlped_docs]
        return processed

Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 6

Instances


Project Name: openeventdata/mordecai
Commit Name: 580af77a96d8c6b306ad4425eafd7768df00338a
Time: 2018-06-27
Author: ahalterman0@gmail.com
File Name: mordecai/geoparse.py
Class Name: Geoparser
Method Name: batch_geoparse


Project Name: lanpa/tensorboardX
Commit Name: f4a6c738beabc312a848804e5c4d4f384919f026
Time: 2020-06-29
Author: prafullasd@gmail.com
File Name: tensorboardX/summary.py
Class Name:
Method Name: audio


Project Name: pfnet/optuna
Commit Name: dac1135635661f39b66432f702047abc704585d1
Time: 2018-06-24
Author: sano@preferred.jp
File Name: examples/chainermn_mnist.py
Class Name:
Method Name: