<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def cpmaximum(image, structure=np.ones((3,3),dtype=bool),offset=None):
 """Find the local maximum at each point in the image, using the given structuring element image - a 2-d array of doubles structure - a boolean structuring element indicating which local elements should be sampled offset - the offset to the center of the structuring element """

    center = np.array(structure.shape) // 2
    if offset is None:
        offset = center
    origin = np.array(offset) - center
    return scind.maximum_filter(image, footprint=structure, origin=origin,
                                mode='constant', cval=np.min(image))