def get_explicit_from_implicit(seekpath_output, reference_distance):
    """
    Given the output of ``get_path`` by seekpath, compute an "explicit" path,
    i.e. instead of just giving the endpoints and their coordinates, compute 
    a full list of kpoints

    :param seekpath_output: a dictionary, the output of ``seekpath.get_path``

    :param reference_distance: a reference target distance between neighboring
        k-points in the path, in units of 1/ang. The actual value will be as
        close as possible to this value, to have an integer number of points in
        each path.
    """
    import numpy as np
    retdict = {}
    kpoints_rel = []
    kpoints_labels = []
    kpoints_linearcoord = []
    previous_linearcoord = 0.0
    segments = []
    for start_label, stop_label in seekpath_output['path']:
        start_coord = np.array(seekpath_output['point_coords'][start_label])
        stop_coord = np.array(seekpath_output['point_coords'][stop_label])
        start_coord_abs = np.dot(start_coord, seekpath_output[
            'reciprocal_primitive_lattice'])
        stop_coord_abs = np.dot(stop_coord, seekpath_output[
            'reciprocal_primitive_lattice'])
        segment_length = np.linalg.norm(stop_coord_abs - start_coord_abs)
        num_points = max(2, int(segment_length / reference_distance))
        segment_linearcoord = np.linspace(0.0, segment_length, num_points)
        segment_start = len(kpoints_labels)
        for i in range(num_points):
            if i == 0:
                if kpoints_labels:
                    if kpoints_labels[-1] == start_label:
                        segment_start -= 1
                        continue
            kpoints_rel.append(start_coord + (stop_coord - start_coord) *
                float(i) / float(num_points - 1))
            if i == 0:
                kpoints_labels.append(start_label)
            elif i == num_points - 1:
                kpoints_labels.append(stop_label)
            else:
                kpoints_labels.append('')
            kpoints_linearcoord.append(previous_linearcoord +
                segment_linearcoord[i])
        previous_linearcoord += segment_length
        segment_end = len(kpoints_labels)
        segments.append((segment_start, segment_end))
    retdict['kpoints_rel'] = np.array(kpoints_rel)
    retdict['kpoints_linearcoord'] = np.array(kpoints_linearcoord)
    retdict['kpoints_labels'] = kpoints_labels
    retdict['kpoints_abs'] = np.dot(retdict['kpoints_rel'], seekpath_output
        ['reciprocal_primitive_lattice'])
    retdict['segments'] = segments
    return retdict
