code: def reduce_dimensions(model):
      num_dimensions = 2  # final num dimensions (2D, 3D, etc)
  
      # extract the words & their vectors, as numpy arrays
      vectors = np.asarray(model.wv.vectors)
      labels = np.asarray(
          model.wv.index_to_key
      )  # fixed-width numpy strings
  
      # reduce using t-SNE
      tsne = TSNE(n_components=num_dimensions, random_state=0)
      vectors = tsne.fit_transform(vectors)
  
      x_vals = [v[0] for v in vectors]
      y_vals = [v[1] for v in vectors]
      return x_vals, y_vals, labels
  
imports: import logging
  import gensim.downloader
  from gensim.test.utils import datapath
  from gensim import utils
  import gensim.models
  import tempfile
  import os
  import io
  import os
  import gensim.models.word2vec
  import gensim.downloader
  import smart_open
  import time
  import numpy
  import pandas
  from sklearn.decomposition import IncrementalPCA
  from sklearn.manifold import TSNE
  import numpy
label_desc: Use image node_id 3 for calling a global function with example usage: reduce_dimensions(model) and returns: x_vals,  y_vals,  labels