Hi @p_jung
Do you mean in python or Java API?
If Python then have you tried converting the image with:
image = Image.open(“path”).convert(“RGB”)
Check also here:
  
      

      pillow.readthedocs.io
  

  
    

Image Module 3

  The Image module provides a class with the same name which is used to represent a PIL image. The module also provides a number of factory functions, including functions to load images from files, a...


  

  
    
    
  

  


Or if you have image loaded you can do something like:
image = Image.open(""path)
tmpImg = np.zeros((image.shape[0],image.shape[1],3))
tmpImg[:,:,0] = image[:,:,0]
tmpImg[:,:,1] = image[:,:,0]
tmpImg[:,:,2] = image[:,:,0]
and use the tmpImg. If you need dimensions like [1,w,h,3] then check:
  
      

      TensorFlow
  

  
    

tf.expand_dims  |  TensorFlow Core v2.6.0 1

  Returns a tensor with a length 1 axis inserted at index axis.