preprocessColorTextureToArray3D(rgbTexture, imageDimensions) {
    const preprocessResultShapeRC =
        [imageDimensions[0], imageDimensions[0] * 3];

    const preprocessResultTexture =
        this.math.getTextureManager().acquireTexture(preprocessResultShapeRC);

    imagenet_util.preprocessInput(
        this.gpgpu, this.preprocessInputShader, rgbTexture,
        preprocessResultTexture, preprocessResultShapeRC);
    return NDArray.make([imageDimensions[0], imageDimensions[0], 3], {
      texture: preprocessResultTexture,
      textureShapeRC: preprocessResultShapeRC
    });
  }
Preprocess an RGB color texture before inferring through squeezenet.
@param rgbTexture The RGB color texture to process into an Array3D.
@param imageDimensions The 2D dimensions of the image.