Determining the number of factors in a large-dimensional generalised factor model