Remove a model, or a list of models from the set.
180951
function(models, options) {
      options = _.extend({}, options);
      var singular = !_.isArray(models);
      models = singular ? [models] : models.slice();
      var removed = this._removeModels(models, options);
      if (!options.silent && removed.length) {
        options.changes = {added: [], merged: [], removed: removed};
        this.trigger('update', this, options);
      }
      return singular ? removed[0] : removed;
    }
881876
def remove_item(self, item):
        """"""
        index = self.items.index(item)
        self.beginRemoveRows(QtCore.QModelIndex(), index, index)
        self.items.remove(item)
        self.endRemoveRows()
343226
public function remove()
    {
        $returnValue = (bool) false;

        
        $db = core_kernel_classes_DbWrapper::singleton();
        if (false === $db->exec("DELETE FROM statements WHERE modelid = ?", array($this->getModelId()))){
        	$returnValue = false;
        }
        else{
        	if (false === $db->exec("DELETE FROM models WHERE modelid = ?", array($this->getModelId()))){
        		$returnValue = false;
        	}
        	else{
        		$returnValue = true;
        	}
        }
        
        

        return (bool) $returnValue;
    }
685447
protected function forgetAddedModels()
    {
        $this->quantities = $this->modelPopulators = [];

        $this->lastModelPopulator = $this->lastModelClass = null;
    }
800091
def remove_filter_set(self, filter_name):
        
        if filter_name in self._filter_sets:
            del self._filter_sets[filter_name]
        else:
            raise ValueError('Unknown filter set name.')
368363
def remove_attributes(self, model):
        
        for child in model.children():
            if 'nn.modules.container' in str(type(child)):
                self.remove_attributes(child)
            else:
                try:
                    del child.x
                except AttributeError:
                    pass
                try:
                    del child.y
                except AttributeError:
                    pass
843179
function(model_s, options){
      var toRemove = model_s instanceof Array ? model_s : [model_s];

      ko.utils.arrayForEach(toRemove, function(model){
        model.destroy(options);
      });
    }
334280
function(view, options) {
        options = _.extend({}, options);
        var model = options.model || view.model,
            collection = options.collection || view.collection;

        if(model) {
          unbindModel(model, view);
        }
        else if(collection) {
          collection.each(function(model){
            unbindModel(model, view);
          });
          collection.unbind('add', collectionAdd);
          collection.unbind('remove', collectionRemove);
        }
      }
537812
private function doDelete()
    {
        if (!$this->model->trashed()) {
            $this->model->delete();
            event(new ModelSoftDelete($this));

            return;
        }

        $this->model->forceDelete();
        event(new ModelDelete($this));
    }
76552
def remove_model(self, model, **kwargs):
        
        kwargs['model'] = model
        kwargs['context'] = 'model'
        self.remove_parameters_all(**kwargs)
1067157
def unregister(self, model_or_iterable):
        
        if isinstance(model_or_iterable, ModelBase):
            model_or_iterable = [model_or_iterable]
        for model in model_or_iterable:
            # Check if the model is actually registered (``get_options_for_model``
            # throws an exception if it's not).
            self.get_options_for_model(model)
            # Invalidate all submodels options and forget about
            # the model itself.
            for desc, desc_opts in list(self._registry.items()):
                if not issubclass(desc, model):
                    continue
                if model != desc and desc_opts.registered:
                    # Allowing to unregister a base would necessitate
                    # repatching all submodels.
                    raise DescendantRegistered(
                        'You need to unregister descendant "%s" before'
                        ' unregistering its base "%s"' %
                        (desc.__name__, model.__name__))
                del self._registry[desc]
884811
def _on_model_delete(sender, **kwargs):
    """"""
    instance = kwargs.pop("instance")
    for index in instance.search_indexes:
        try:
            _delete_from_search_index(instance=instance, index=index)
        except Exception:
            logger.exception("Error handling 'on_delete' signal for %s", instance)
1051760
private void performClearOperation(ModelElementInstanceImpl modelElement, Collection<DomElement> elementsToRemove) {
    Collection<ModelElementInstance> modelElements = ModelUtil.getModelElementCollection(elementsToRemove, modelElement.getModelInstance());
    for (ModelElementInstance element : modelElements) {
      modelElement.removeChildElement(element);
    }
  }
716031
def remove_from_set(set, item)
      Predictor.redis.multi do |redis|
        redis.srem(redis_key(:items, set), item)
        redis.srem(redis_key(:sets, item), set)
      end
    end
725144
def remove(self, resource, **kwargs):
        
        log.info(
            "Removing {} '{}'...".format(self._model_name, resource.name))
        resource.remove(**kwargs)
        self._ids.remove(resource.id)
408540
function(model, options) {
      options || (options = {});
      model = this.getByCid(model) || this.get(model);
      if (!model) return null;
      delete this._byId[model.id];
      delete this._byCid[model.cid];
      this.models.splice(this.indexOf(model), 1);
      this.length--;
      if (!options.silent) model.trigger('remove', model, this, options);
      this._removeReference(model);
      return model;
    }
221163
def delete_model(self):
        
        request_failed = False
        failed_models = []
        for model_name in self._model_names:
            try:
                self.sagemaker_session.delete_model(model_name)
            except Exception:  # pylint: disable=broad-except
                request_failed = True
                failed_models.append(model_name)

        if request_failed:
            raise Exception('One or more models cannot be deleted, please retry. \n'
                            'Failed models: {}'.format(', '.join(failed_models)))