<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def _memory_usage(func, gallery_conf):
 """Get memory usage of a function call."""

    if gallery_conf['show_memory']:
        from memory_profiler import memory_usage
        assert callable(func)
        mem, out = memory_usage(func, max_usage=True, retval=True,
                                multiprocess=True)
        mem = mem[0]
    else:
        out = func()
        mem = 0
    return out, mem