def get_df_from_shared_memory(
  sharedMemoryDfInfo: c.SharedMemoryDataframeInfo,
) -> pd.DataFrame:
  """
  Intended to be called from a process within a multiprocessing pool in parallel.
  Read a dataframe from shared memory and return it.
  """
  existing_shm = shared_memory.SharedMemory(name=sharedMemoryDfInfo.sharedMemoryName)
  size = sharedMemoryDfInfo.dataSize
  with io.BytesIO(existing_shm.buf[:size]) as buf:
    return pd.read_parquet(buf)

  Intended to be called from a process within a multiprocessing pool in parallel.
  Read a dataframe from shared memory and return it.
  
sourcecode/scoring/run_scoring.py