code: def get_lastfm():
      """Returns the lastfm360k dataset, downloading locally if necessary.
      Returns a tuple of (artistids, userids, plays) where plays is a CSR matrix
      """
  
      filename = os.path.join(
          _download.LOCAL_CACHE_DIR, "lastfm_360k.hdf5"
      )
      if not os.path.isfile(filename):
          log.info("Downloading dataset to '%s'", filename)
          _download.download_file(URL, filename)
      else:
          log.info("Using cached dataset at '%s'", filename)
  
      with h5py.File(filename, "r") as f:
          m = f.get("artist_user_plays")
          plays = csr_matrix(
              (m.get("data"), m.get("indices"), m.get("indptr"))
          )
          return (
              np.array(f["artist"].asstr()[:]),
              np.array(f["user"].asstr()[:]),
              plays,
          )
  
file_path: implicit/implicit/datasets/lastfm.py
imports: import logging
  import os
  import time
  import h5py
  import numpy
  from scipy.sparse import coo_matrix, csr_matrix
  from implicit.datasets import _download
label_desc: Use image node_id 1 for calling a global function with example usage: get_lastfm() and returns: np,  np,  plays