code: def pil_resize_from_ndarray(arr, size, resample):
      mode = "F" if arr.dtype == np.float32 else None
  
      pil_image = Image.fromarray(arr, mode=mode)
      resized_image = pil_image.resize(size, resample=resample)
  
      return np.asarray(resized_image)
  
file_path: nnabla/python/src/nnabla/utils/image_utils/backend_events/pil_backend.py
imports: from __future__ import absolute_import, division
  import numpy
  from PIL import Image
  from nnabla.logger import logger
  from .common import _imread_before, _imread_after, _imsave_before, _imresize_before, _imresize_after
  from .image_utils_backend import ImageUtilsBackend
label_desc: Use image node_id 4 for calling the PilBackend obj's underlying member method code with example usage: obj.pil_resize_from_ndarray(arr, size, resample) and returns: np