code: def assign_pseudo_labels(active_learner, X, confidence_idx):
      conf_samples = X[confidence_idx]
      labels = active_learner.predict(conf_samples)
      return labels
  
imports: from keras.datasets import mnist
  import numpy
  from modAL.models import ActiveLearner
  from sklearn.ensemble import RandomForestClassifier
  from scipy.special import entr
label_desc: Use image node_id 1 for calling a global function with example usage: assign_pseudo_labels(active_learner, X, confidence_idx) and returns: labels