code: def test_parafac2_to_vec(shape, rank):
      pf2_tensor = ivy.random_parafac2(shape, rank)
      full_tensor = ivy.Parafac2Tensor.parafac2_to_tensor(pf2_tensor)
      np.allclose(
          ivy.Parafac2Tensor.parafac2_to_vec(pf2_tensor),
          ivy.reshape(full_tensor, (-1)),
      )
  
file_path: ivy/ivy_tests/test_ivy/test_misc/test_factorized_tensor/test_parafac2_tensor.py
imports: import ivy
  import numpy
  import pytest
label_desc: Use image node_id 6 for calling a global function with example usage: test_parafac2_to_vec(shape, rank) without return types