Returns the label that contains the inputed action.
        
        :return     <XDockActionLabel> || None
549377
def labelForAction(self, action):
        
        for label in self.actionLabels():
            if label.action() == action:
                return label
        return None
1307829
def get_label(self, x, w):
        
        scores = np.dot(x,w)
        return np.argmax(scores,axis=1).transpose()
1043515
def get_ndmapping_label(ndmapping, attr):
    
    label = None
    els = itervalues(ndmapping.data)
    while label is None:
        try:
            el = next(els)
        except StopIteration:
            return None
        if not getattr(el, '_auxiliary_component', True):
            label = getattr(el, attr)
    if attr == 'group':
        tp = type(el).__name__
        if tp == label:
            return None
    return label
766360
def label(labelname)
      read_labels
      return [nil, nil, nil] if @label.size < 1 || !@label.key?(labelname)
      [
        @label[labelname][1].to_i,
        ::Roo::Utils.letter_to_number(@label[labelname][2]),
        @label[labelname][0]
      ]
    end
1161906
def get_label_names(ctx):
    """"""
    labels = [
        label
        for label in ctx.__dict__
        if not label.startswith("_")
        and label
        not in [
            "children",
            "exception",
            "invokingState",
            "parentCtx",
            "parser",
            "start",
            "stop",
        ]
    ]
    return labels
178747
def select_action(self, **kwargs):
        
        setattr(self.inner_policy, self.attr, self.get_current_value())
        return self.inner_policy.select_action(**kwargs)
933120
def showActionToolTip(self):
        
        if ( not self.isVisible() ):
            return
            
        geom  = self.actionGeometry(self._toolTipAction)
        pos   = self.mapToGlobal(QPoint(geom.left(), geom.top()))
        pos.setY(pos.y() + geom.height())
        
        tip   = nativestring(self._toolTipAction.toolTip()).strip().strip('.')
        text  = nativestring(self._toolTipAction.text()).strip().strip('.')
        
        # don't waste time showing the user what they already see
        if ( tip == text ):
            return
        
        QToolTip.showText(pos, self._toolTipAction.toolTip())
80032
protected function getActionText()
    {
        if ($this->hasBeenSent()) {
            $action = 'action_sent';
        } elseif ($this->isSendingPrevented()) {
            $action = 'action_not_sent';
        } else {
            $action = 'action_unknown';
        }
        return $this->t($action);
    }
742142
def get_widget_label_for(self, fieldname, default=None):
        
        widget = self.get_widget_for(fieldname)
        if widget is None:
            return default
        return widget.label
355753
def label(self, name, internal=False, definition=False):
        
        return "{0}{1}{2}".format(self.internal if internal else "", name, self.definition if definition else "")
1117983
def GetValue(self):
    '''
    
    '''
    if not self._widget.GetValue() or len(self._widget.GetValue()) <= 0:
        return None
    else:
        return self._action.option_strings[0]
1158787
def find_label(self, label: Label):
        
        for index, action in enumerate(self.program):
            if isinstance(action, JumpTarget):
                if label == action.label:
                    return index

        raise RuntimeError("Improper program - Jump Target not found in the "
                           "input program!")
757103
def about_action(self):
        
        name = self.action.metavar or self.action.dest
        type_name = self.action.type.__name__ if self.action.type else ''
        if self.action.help or type_name:
            extra = ' (%s)' % (self.action.help or 'type: %s' % type_name)
        else:
            extra = ''
        return name + extra
1243255
def get_name(self, label_type):
        
        if label_type in self._label_values:
            return self._label_values[label_type][0]
        else:
            return Labels.LABEL_NAMES[label_type][0]
803459
private LabeledStatement matchJumpLabelName()
        throws IOException
    {
        LabeledStatement label = null;

        if (peekTokenOrEOL() == Token.NAME) {
            consumeToken();
            if (labelSet != null) {
                label = labelSet.get(ts.getString());
            }
            if (label == null) {
                reportError("msg.undef.label");
            }
        }

        return label;
    }
1071450
def get_steps_from_feature_description(self, description):
        
        self.init_actions()
        label_exists = EMPTY
        for row in description:
            if label_exists != EMPTY:
                # in case of a line with a comment, it is removed
                if "#" in row:
                    row = row[0:row.find("#")].strip()

                if any(row.startswith(x) for x in KEYWORDS):
                    self.actions[label_exists].append(row)
                elif row.find(TABLE_SEPARATOR) >= 0:
                    self.actions[label_exists][-1] = "%s\n      %s" % (self.actions[label_exists][-1], row)
                else:
                    label_exists = EMPTY
            for action_label in self.actions:
                if row.lower().find(action_label) >= 0:
                    label_exists = action_label
275012
def label(self, input_grid):
        
        marked = self.find_local_maxima(input_grid)
        marked = np.where(marked >= 0, 1, 0)
        # splabel returns two things in a tuple: an array and an integer
        # assign the first thing (array) to markers
        markers = splabel(marked)[0]
        return markers