def convert_spot_coordinates(spots, resolution_z, resolution_yx):
    """
    Convert spots coordinates in nanometer.

    Parameters
    ----------
    spots : np.ndarray, np.int64
        Coordinates of the detected spots with shape (nb_spots, 3).
    resolution_z : int or float
        Height of a voxel, along the z axis, in nanometer.
    resolution_yx : int or float
        Size of a voxel on the yx plan, in nanometer.

    Returns
    -------
    spots_nanometer : np.ndarray, np.int64
        Coordinates of the detected spots with shape (nb_spots, 3), in
        nanometer.

    """
    # convert spots coordinates in nanometer, for each dimension, according to
    # the pixel size of the image
    spots_nanometer = spots.copy()
    spots_nanometer[:, 0] *= resolution_z
    spots_nanometer[:, 1:] *= resolution_yx

    return spots_nanometer