code: def test_to_vector():
      vector = Vectors.dense([4, 2])
      x = from_vector(vector)
      assert x.shape == (2,)
  
imports: import numpy
  from elephas.mllib.adapter import *
  from pyspark.mllib.linalg import Matrices, Vectors
label_desc: Use image node_id 4 for calling a global function with example usage: test_to_vector() without return types