In this part of the documentation, it is mentioned that nlp.pipe() works in parallel and the following example is given:
for doc in nlp.pipe(texts, batch_size=10000, n_threads=3):
pass
After that, another, longer example is given that makes use of joblib. I don't quite understand the relationship between the two. As I understand the documentation, if I simply want to parallelize the tokenisation of many documents, the above, simple for loop will work and I do not have to use joblib, right?
My pipeline looks like this:
nlp = spacy.load('en', disable=['parser', 'ner', 'textcat'])
When would I need to use joblib?