class_docstr: Custom distance/kernel (on data frame rows). todo: write docstring.
  
  todo: describe your custom distance/kernel here
  
  Hyper-parameters
  ----------------
  parama : int
      descriptive explanation of parama
  paramb : string, optional (default='default')
      descriptive explanation of paramb
  paramc : boolean, optional (default= whether paramb is not the default)
      descriptive explanation of paramc
  and so on
  
  Components
  ----------
  est : sktime.estimator, BaseEstimator descendant
      descriptive explanation of est
  est2: another estimator
      descriptive explanation of est2
  and so on
class_docstr_tok: ["Custom","distance\/kernel","(","on","data","frame","rows",")",".","todo",":","write","docstring",".","todo",":","describe","your","custom","distance\/kernel","here","Hyper-parameters","--","--","--","--","--","--","--","--","parama",":","int","descriptive","explanation","of","parama","paramb",":","string",",","optional","(","default='default","'",")","descriptive","explanation","of","paramb","paramc",":","boolean",",","optional","(","default=","whether","paramb","is","not","the","default",")","descriptive","explanation","of","paramc","and","so","on","Components","--","--","--","--","--","est",":","sktime.estimator",",","BaseEstimator","descendant","descriptive","explanation","of","est","est2",":","another","estimator","descriptive","explanation","of","est2","and","so","on"]
docstr: Compute distance/kernel matrix between samples.
  
  Behaviour: returns pairwise distance/kernel matrix
      between samples in X and X2 (equal to X if not passed)
  
      core logic
  
  Parameters
  ----------
  X: pd.DataFrame of length n, or 2D np.array with n rows
  X2: pd.DataFrame of length m, or 2D np.array with m rows, optional
      default X2 = X
  
  Returns
  -------
  distmat: np.array of shape [n, m]
      (i,j)-th entry contains distance/kernel between X.iloc[i] and X2.iloc[j]
docstr_tok: ["Compute","distance\/kernel","matrix","between","samples",".","Behaviour",":","returns","pairwise","distance\/kernel","matrix","between","samples","in","X","and","X2","(","equal","to","X","if","not","passed",")","core","logic","Parameters","--","--","--","--","--","X",":","pd.DataFrame","of","length","n",",","or","2D","np.array","with","n","rows","X2",":","pd.DataFrame","of","length","m",",","or","2D","np.array","with","m","rows",",","optional","default","X2","=","X","Returns","--","--","--","-","distmat",":","np.array","of","shape","[","n",",","m","]","(","i",",","j",")","-th","entry","contains","distance\/kernel","between","X.iloc","[","i","]","and","X2.iloc","[","j","]"]
code: def _transform(self, X, X2=None):
      """Compute distance/kernel matrix between samples.
  
      Behaviour: returns pairwise distance/kernel matrix
          between samples in X and X2 (equal to X if not passed)
  
          core logic
  
      Parameters
      ----------
      X: pd.DataFrame of length n, or 2D np.array with n rows
      X2: pd.DataFrame of length m, or 2D np.array with m rows, optional
          default X2 = X
  
      Returns
      -------
      distmat: np.array of shape [n, m]
          (i,j)-th entry contains distance/kernel between X.iloc[i] and X2.iloc[j]
      """
  
imports: from sktime.dists_kernels import BasePairwiseTransformer
label_desc: Use image node_id 2 for calling the MyTrafoPw obj's underlying member method code with example usage: obj._transform(X, X2) without return types