def to_numpy_array(multiprocessing_array, shape, dtype):
    """Convert a share multiprocessing array to a numpy array.
        No data copying involved.
    """

    return np.frombuffer(multiprocessing_array.get_obj(),
                         dtype = dtype).reshape(shape)