class_docstr: This table's columns are text columns representing JSON data of how
  to extract the train and test datasets, base learner cross-validation method,
  and the stacked ensemble cross-validation method.
  It will contain only a single row.
class_docstr_tok: ["This","table","'s","columns","are","text","columns","representing","JSON","data","of","how","to","extract","the","train","and","test","datasets",",","base","learner","cross-validation","method",",","and","the","stacked","ensemble","cross-validation","method",".","It","will","contain","only","a","single","row","."]
docstr: Returns test data set
  
  Returns:
      X (numpy.ndarray): Features
  
      y (numpy.ndarray): Labels
docstr_tok: ["Returns","test","data","set","Returns",":","X","(","numpy.ndarray",")",":","Features","y","(","numpy.ndarray",")",":","Labels"]
code: def return_test_dataset(self):
      """Returns test data set
  
      Returns:
          X (numpy.ndarray): Features
  
          y (numpy.ndarray): Labels
      """
      if self.test_dataset["method"] == "split_from_main":
          X, y = self.return_main_dataset()
          X, X_test, y, y_test = train_test_split(
              X,
              y,
              test_size=self.test_dataset["split_ratio"],
              random_state=self.test_dataset["split_seed"],
              stratify=y,
          )
  
          return X_test, y_test
  
      if self.test_dataset["method"] == "source":
          if (
              "source" not in self.test_dataset
              or not self.test_dataset["source"]
          ):
              raise exceptions.UserError("Source is empty")
  
          extraction_code = self.test_dataset["source"]
          extraction_function = (
              functions.import_object_from_string_code(
                  extraction_code, "extract_test_dataset"
              )
          )
          X_test, y_test = extraction_function()
  
          return np.array(X_test), np.array(y_test)
  
imports: from __future__ import absolute_import, print_function, division, unicode_literals
  import random
  import string
  from sqlalchemy.ext.declarative import declarative_base
  from sqlalchemy import Column, Text, Integer, Boolean, TypeDecorator, ForeignKey, Table, UniqueConstraint
  from sqlalchemy.orm import relationship
  from sqlalchemy.ext import mutable
  import numpy
  import json
  import os
  from sklearn.model_selection import train_test_split
  from xcessiv import constants
  from xcessiv import exceptions
  from xcessiv import functions
  from xcessiv import app
label_desc: Use image node_id 4 for calling the Extraction obj's underlying member method code with example usage: obj.return_test_dataset() and returns: X_test,  y_test, np,  np