def make_sure_ind(inds, req_len=None):
    """Given an object, constructs a tuple of floats the required length.
    Either removes items that cannot be cast as floats, or adds the last valid
    item until the required length is reached.

    Parameters
    ----------
    inds : sequence
        the sequence to be constructed into tuple of floats
    req_len : {None, number}
        The required length of the output

    Returns
    -------
    indices : tuple of floats
    """
    try:
        number = len(inds)
        val = ()
        for i in inds:
            try:
                val = val + (float(i),)
            except TypeError:
                pass
        number = len(val)
    except TypeError:
        val = float(inds),
        number = len(val)
    if req_len:
        if req_len < number:
            val = val[:req_len]
        else:
            val = val + tuple([val[-1] for _ in range(number, req_len)])
    return val
