When importing a keras model, the kerasconverter assumes that images are imported as <width, height, color space>. I would like to have a paramter to either configure `image_input_names` or a flag to have `image_input_names` prase inputs as <width, color space, height>
Error:
---------------------------------------------------------------------------
ValueError Traceback (most recent call last)
/home/keras/test/train.py in <module>()
49 print model.input_shape
50
---> 51 coremlmodel = coremltools.converters.keras.convert(model, class_labels="labels.txt", image_input_names="input1")
52
53
/opt/conda/envs/coreml/lib/python2.7/site-packages/coremltools/converters/keras/_keras_converter.pyc in convert(model, input_names, output_names, image_input_names, is_bgr, red_bias, green_bias, blue_bias, gray_bias, image_scale, class_labels, predicted_feature_name)
429 blue_bias = blue_bias,
430 gray_bias = gray_bias,
--> 431 image_scale = image_scale)
432
433 # Return the protobuf spec
/opt/conda/envs/coreml/lib/python2.7/site-packages/coremltools/models/neural_network.pyc in set_pre_processing_parameters(self, image_input_names, is_bgr, red_bias, green_bias, blue_bias, gray_bias, image_scale)
1670 input_.type.imageType.colorSpace = _FeatureTypes_pb2.ImageFeatureType.ColorSpace.Value('RGB')
1671 else:
-> 1672 raise ValueError("Channel Value %d not supported for image inputs" % channels)
1673 input_.type.imageType.width = width
1674 input_.type.imageType.height = height
ValueError: Channel Value 100 not supported for image inputs
Here is a link to samle code on GitHub: https://github.com/joeblau/coremltools-demo