code: def time_features(dates, freq="h"):
      return np.vstack(
          [
              feat(dates)
              for feat in time_features_from_frequency_str(freq)
          ]
      )
  
imports: from typing import List
  import numpy
  import pandas
  from pandas import Timedelta
  from pandas.tseries.frequencies import to_offset
  from bigdl.chronos.data.utils.roll import _roll_timeseries_ndarray
label_desc: Use image node_id 2 for calling a global function with example usage: time_features(dates, freq) and returns: np