class_docstr: Produces labels for a model with a seperate CRF for NER and group
  information.
  
  Outputs two label sequences, the first for the standard NER CRF and the
  second for the group CRF.
class_docstr_tok: ["Produces","labels","for","a","model","with","a","seperate","CRF","for","NER","and","group","information",".","Outputs","two","label","sequences",",","the","first","for","the","standard","NER","CRF","and","the","second","for","the","group","CRF","."]
code: def transform(self, out, labels):
      labels, groups = labels
  
      # Create "fake" labels for groups
      group_labels = []
      for group in groups:
          if not is_continuous(group):
              continue
          group_start = min([t["start"] for t in group["spans"]])
          group_end = max([t["end"] for t in group["spans"]])
          group_text = " ".join([t["text"] for t in group["spans"]])
          group_labels.append(
              {
                  "start": group_start,
                  "end": group_end,
                  "label": "",
                  "text": group_text,
                  "group_start": True,
              }
          )
  
      # Encode grouping labels
      self.classes_ = self.group_classes_
      self.lookup = self.group_lookup
      # Group tagging must be on and bio tagging must be off
      # (We use group tagging here instead of bio tagging for convenience, as
      # this way we don't have to convert back to group tags when decoding)
      self.group_tagging = True
      _bio, self.bio_tagging = self.bio_tagging, False
      encoded_group_labels = super().transform(out, group_labels)
  
      # Encode NER labels
      self.classes_ = self.label_classes_
      self.lookup = self.label_lookup
      # Turn group tagging off and revert bio tagging
      self.group_tagging = False
      self.bio_tagging = _bio
      encoded_labels = super().transform(out, labels)
  
      return [encoded_labels, encoded_group_labels]
  
imports: from abc import ABCMeta
  import logging
  import json
  import numpy
  from finetune.encoding.target_encoders import BaseEncoder, Seq2SeqLabelEncoder, SequenceLabelingEncoder
label_desc: Use image node_id 3 for calling the MultiCRFGroupSequenceLabelingEncoder obj's underlying member method code with example usage: obj.transform(out, labels) and returns: list