code: def normalize(
      input_matrix: Union[pd.DataFrame, pd.Series], norm="l2"
  ) -> pd.Series:
      """
      Normalize every cell in a Pandas Series.
  
      Input can be VectorSeries or DataFrames. For sparse DataFrames,
      the sparseness is kept.
  
      Parameters
      ----------
      input_matrix: Pandas Series (VectorSeries) or DataFrame
  
      norm: str, optional, default="l2"
          One of "l1", "l2", or "max". The norm that is used.
  
      Examples
      --------
      >>> import texthero as hero
      >>> import pandas as pd
      >>> col = ["a","b","c", "d"]
      >>> s = pd.DataFrame([[1, 2, 3, 4],[4, 2, 7, 5],[2, 2, 3, 5],[1, 2, 9, 8]],
      ...                   columns=col).astype("Sparse")
      >>> hero.normalize(s, norm="max") # doctest: +SKIP
                a         b     c         d
      0  0.250000  0.500000  0.75  1.000000
      1  0.571429  0.285714  1.00  0.714286
      2  0.400000  0.400000  0.60  1.000000
      3  0.111111  0.222222  1.00  0.888889
  
  
      See Also
      --------
      DataFrame link TODO add link to tutorial
  
      `Norm on Wikipedia
      <https://en.wikipedia.org/wiki/Norm_(mathematics)>`_
  
      """
      isDataFrame = isinstance(input_matrix, pd.DataFrame)
  
      if isDataFrame:
          input_matrix_coo = input_matrix.sparse.to_coo()
          input_matrix_for_vectorization = input_matrix_coo.astype(
              "float64"
          )
      else:
          input_matrix_for_vectorization = list(input_matrix)
  
      result = sklearn_normalize(
          input_matrix_for_vectorization, norm=norm
      )  # Can handle sparse input.
  
      if isDataFrame:
          return pd.DataFrame.sparse.from_spmatrix(
              result, input_matrix.index, input_matrix.columns
          )
      else:
          return pd.Series(list(result), index=input_matrix.index)
  
imports: import pandas
  import numpy
  from sklearn.feature_extraction.text import TfidfVectorizer, CountVectorizer
  from sklearn.manifold import TSNE
  from sklearn.decomposition import PCA, NMF
  from sklearn.cluster import KMeans, DBSCAN, MeanShift
  from sklearn.metrics.pairwise import cosine_similarity
  from sklearn.preprocessing import normalize
  from scipy.sparse import coo_matrix
  from typing import Optional, Union, Any
  from texthero._types import TextSeries, TokenSeries, VectorSeries, DataFrame, InputSeries
  from texthero import preprocessing
  import logging
  import warnings
label_desc: Use image node_id 10 for calling a global function with example usage: normalize(input_matrix, norm) and returns: pd, pd