I would like to know how is determined the dimension of the context in
The dimension of the context in Gensim's Doc2Vec is determined by the parameter
vector_size when you initialize the Doc2Vec model. This parameter sets the dimensionality of the output vectors.
For example, if you set
vector_size=100, then the model will output 100-dimensional vectors for each document and word. This is a hyperparameter that you can tune based on your specific use case.
from gensim.models import Doc2Vec
model = Doc2Vec(vector_size=100)
In this case, the dimension of the context (i.e., the output vectors) is 100. You can change it as per your requirement.
In Genism's doc2vec,context is a list of words passed to models. That is a hyperparameter selected by the user, thus will problem specific.