Batch classification of images in Tensorflow java

What's the best way to classify batch of images using TensorFlow java API? I also want the capability to resize the image in GPU so that all the images in the batch are of same dimension.

The only example I have found in the internet is for a single image , here .

In python , I see there is a tf.stack method which allows to create a pack of tensors to create a batch request , I couldnt find anything equivalent to this method in java api.

I found an example of batch request which uses opencv and tensorflow Is there a better way to do this using standard tensor operations in java?