Return the index of the given pane. ValueError if not found.
481977
def get_pane_index(self, pane):
        "  "
        assert isinstance(pane, Pane)
        return self.panes.index(pane)
276617
def get_selected_python_frame(cls):
        ''''''
        frame = cls.get_selected_frame()

        while frame:
            if frame.is_evalframeex():
                return frame
            frame = frame.older()

        # Not found:
        return None
1110955
def get_value(self, query):
        
        indices = self.get_dimension_indices(query)
        index = self.get_value_index(indices)
        value = self.get_value_by_index(index)
        return value
76311
def _maybe_cast_indexer(self, key):
        

        if is_float(key) and not self.is_floating():
            try:
                ckey = int(key)
                if ckey == key:
                    key = ckey
            except (OverflowError, ValueError, TypeError):
                pass
        return key
433755
def index(ctx, view):
    """"""
    adapter = ctx.obj['adapter']
    if view:
        click.echo(adapter.indexes())
        return
    adapter.ensure_indexes()
638127
def _get_index(self):
        
        contour = self.contour
        value = contour.segments.index(self)
        return value
770860
def index(self, key):
        
        if isinstance(key, str):
            for idx, (item, quality) in enumerate(self):
                if self._value_matches(key, item):
                    return idx
            raise ValueError(key)
        return list.index(self, key)
639291
def index_at_event(self, event):
        
        # find index at mouse position
        globalpos = event.globalPos()
        viewport = self.viewport()
        pos = viewport.mapFromGlobal(globalpos)
        return self.indexAt(pos)
675007
def get_model_index(cls, model, default=True):
        '''
        
        '''
        try:
            if default:
                return cls._model_name_to_default_index[model]
            return cls._model_name_to_model_idx[model]
        except KeyError:
            raise KeyError('Could not find any model index defined for model {}.'.format(model))
1156552
def get_bin_index(self, value):
        """"""
        if value == self.max_value:
            return self.num_bins - 1

        return int(self.C * log(value / self.min_value))
569398
def get_bin_index(self, value):
        """"""
        if value == self.max_value:
            return self.num_bins - 1
        return int((value - self.min_value) / self.bin_size)
178152
def _get_fill_indexer_searchsorted(self, target, method, limit=None):
        
        if limit is not None:
            raise ValueError('limit argument for %r method only well-defined '
                             'if index and target are monotonic' % method)

        side = 'left' if method == 'pad' else 'right'

        # find exact matches first (this simplifies the algorithm)
        indexer = self.get_indexer(target)
        nonexact = (indexer == -1)
        indexer[nonexact] = self._searchsorted_monotonic(target[nonexact],
                                                         side)
        if side == 'left':
            # searchsorted returns "indices into a sorted array such that,
            # if the corresponding elements in v were inserted before the
            # indices, the order of a would be preserved".
            # Thus, we need to subtract 1 to find values to the left.
            indexer[nonexact] -= 1
            # This also mapped not found values (values of 0 from
            # np.searchsorted) to -1, which conveniently is also our
            # sentinel for missing values
        else:
            # Mark indices to the right of the largest value as not found
            indexer[indexer == len(self)] = -1
        return indexer
838816
def to_python_index(self, length, check_bounds=True, circular=False):
        
        if not self.is_unitless:
            raise ValueError("Index cannot have units: {0!r}".format(self))

        ret = int(self.value)
        if ret != self.value:
            raise ValueError("Index must be an integer: {0!r}".format(ret))

        if ret == 0:
            raise ValueError("Index cannot be zero")

        if check_bounds and not circular and abs(ret) > length:
            raise ValueError("Index {0!r} out of bounds for length {1}".format(ret, length))

        if ret > 0:
            ret -= 1

        if circular:
            ret = ret % length

        return ret
418043
def get_index(index_name, *partition_indices):  # pragma: no cover
    """"""
    index = partition_indices[0].append(partition_indices[1:])
    index.names = index_name
    return index
60219
static Object getIndexObject(String s)
    {
        long indexTest = indexFromString(s);
        if (indexTest >= 0) {
            return Integer.valueOf((int)indexTest);
        }
        return s;
    }
44985
def get_value_index(self, indices):
        
        size = self['size'] if self.get('size') else self['dimension']['size']
        ndims = len(size)
        mult = 1
        num = 0
        for idx, dim in enumerate(size):
            mult *= size[ndims - idx] if (idx > 0) else 1
            num += mult * indices[ndims - idx - 1]
        return num
815733
private long getIndex(T x, T y) {
        int i = elementIndices.index(x);
        int j = elementIndices.index(y);
        long index = (((long)i) << 32) | j;
        return index;
    }