get_memory cookbook