code: def _get_pls_dataset(tensor_dimensions, n_latent, n_response):
      """Creates PLS dataset"""
      x_tensor = random_cp(
          tensor_dimensions,
          n_latent,
          orthogonal=True,
          normalise_factors=True,
          random_state=RANDOM_STATE,
          dtype=tl.float64,
      )
      y_tensor = random_cp(
          (tensor_dimensions[0], n_response),
          n_latent,
          random_state=RANDOM_STATE,
          dtype=tl.float64,
      )
  
      y_tensor.factors[0] = x_tensor.factors[0]
      x = cp_to_tensor(x_tensor)
      y = cp_to_tensor(y_tensor)
  
      return x, y, x_tensor, y_tensor
  
imports: import numpy
  import pytest
  import tensorly
  from ...testing import assert_allclose
  from ...cp_tensor import CPTensor, cp_normalize, cp_to_tensor
  from ...metrics.factors import congruence_coefficient
  from ...random import random_cp
  from ..cp_plsr import CP_PLSR
label_desc: Use image node_id 1 for calling a global function with example usage: _get_pls_dataset(tensor_dimensions, n_latent, n_response) and returns: x,  y,  x_tensor,  y_tensor