code: def _insert_idxs(feature_centre, feature_size, dimensions):
      """Returns the indices of where to put the signal into the signal volume
  
      Parameters
      ----------
  
      feature_centre : list, int
          List of coordinates for the centre location of the signal
  
      feature_size : list, int
          How big is the signal's diameter.
  
      dimensions : 3 length array, int
          What are the dimensions of the volume you wish to create
  
  
      Returns
      ----------
      x_idxs : tuple
          The x coordinates of where the signal is to be inserted
  
      y_idxs : tuple
          The y coordinates of where the signal is to be inserted
  
      z_idxs : tuple
          The z coordinates of where the signal is to be inserted
  
      """
  
      # Set up the indexes within which to insert the signal
      x_idx = [
          int(feature_centre[0] - (feature_size / 2)) + 1,
          int(feature_centre[0] - (feature_size / 2) + feature_size)
          + 1,
      ]
      y_idx = [
          int(feature_centre[1] - (feature_size / 2)) + 1,
          int(feature_centre[1] - (feature_size / 2) + feature_size)
          + 1,
      ]
      z_idx = [
          int(feature_centre[2] - (feature_size / 2)) + 1,
          int(feature_centre[2] - (feature_size / 2) + feature_size)
          + 1,
      ]
  
      # Check for out of bounds
      # Min Boundary
      if 0 > x_idx[0]:
          x_idx[0] = 0
      if 0 > y_idx[0]:
          y_idx[0] = 0
      if 0 > z_idx[0]:
          z_idx[0] = 0
  
      # Max Boundary
      if dimensions[0] < x_idx[1]:
          x_idx[1] = dimensions[0]
      if dimensions[1] < y_idx[1]:
          y_idx[1] = dimensions[1]
      if dimensions[2] < z_idx[1]:
          z_idx[1] = dimensions[2]
  
      # Return the idxs for data
      return x_idx, y_idx, z_idx
  
imports: import logging
  from itertools import product
  from statsmodels.tsa.arima.model import ARIMA
  import math
  import numpy
  from numpy.linalg import LinAlgError
  from pkg_resources import resource_stream
  from scipy import stats
  from scipy import signal
  import scipy.ndimage
  import copy
  from scipy import optimize
label_desc: Use image node_id 2 for calling a global function with example usage: _insert_idxs(feature_centre, feature_size, dimensions) and returns: x_idx,  y_idx,  z_idx