code: def test_cp_normalize(shape, rank):
      cp_tensor = ivy.random_cp(shape, rank)
      weights, factors = ivy.CPTensor.cp_normalize(cp_tensor)
      expected_norm = ivy.ones((rank,))
      for f in factors:
          norm = ivy.sqrt(ivy.sum(ivy.square(f), axis=0))
          assert np.allclose(norm, expected_norm)
      assert np.allclose(
          ivy.CPTensor.cp_to_tensor((weights, factors)),
          ivy.CPTensor.cp_to_tensor(cp_tensor),
      )
  
file_path: ivy/ivy_tests/test_ivy/test_misc/test_factorized_tensor/test_cp_tensor.py
imports: import ivy
  import numpy
  import pytest
label_desc: Use image node_id 5 for calling a global function with example usage: test_cp_normalize(shape, rank) without return types