Comments (10)
I have found a similiar issue from you https://stackoverflow.com/questions/44529869/converting-uiimage-to-mlmultiarray-for-keras-model/44538525#44538525
On the other hand, my output is now "Multiarray (double 4x1917x1)" because input data is in a wrong type, and yours is "Multiarray (double)",so do I need to convert the output data or will it be solved just fixing the input data ?
from coremlhelpers.
I have already tried input conversion but output still is wrong :(
from coremlhelpers.
This happens because Core ML does not understand that it has to interpret your input as an image. You need to tell coremltools that your input should be treated as an image.
from coremlhelpers.
Thanks,
And how can I do this? while conversion from TF to Core Ml? could you show me a sample, please?
Thanks
from coremlhelpers.
Is it the same that you explained here? https://stackoverflow.com/questions/48773397/keras-image-classifier-for-coreml-image-input-asks-multiarray-instead-of-image
from coremlhelpers.
I haven't used the TF converter, so no idea how to do it there.
from coremlhelpers.
I mean CoreML tools from keras-python, sorry
from coremlhelpers.
I read this from you "When converting your model to Core ML you also need to add input_names='camera frame' when you call coremltools.converters.keras.convert(), in addition to image_input_names='camera frame'. Otherwise coremltools won't see this input and doesn't know you want to treat it as an image."
from coremlhelpers.
Yes that is correct.
from coremlhelpers.
@periscopiojoe If you are still facing this issue, the tf-coreml converter has image_input_name
variable to be set for telling the converter that input is an image. For more infor, check this example notebook: https://github.com/tf-coreml/tf-coreml/blob/master/examples/style_transfer_example.ipynb
from coremlhelpers.
Related Issues (20)
- use with macOS/NSImage HOT 4
- Is there any way to make the returned CVPixelbuffer backed by an IOSurface ? HOT 2
- How to know if coreML model would perform image-preprocessing step or not?
- Q about output Multiarray shape
- Carthage - no shared framework schemes HOT 2
- Is there any evaluation example code or helper modules on this repo? HOT 1
- Accessing elements from Dim 5 multi array not working
- Swift Package Manager Support? HOT 2
- [Feature] MLMultiArray -> UIImage without premultiplied alpha HOT 2
- Prediction discrepancies between Python's coremltools and Swift's CoreML API HOT 4
- Need help to adjust bbox for cropped images HOT 7
- pixelBuffer not public HOT 1
- MLMultiarray+Image.swift file gives error HOT 1
- How to use the transposed function? from (26, 64, 48, 1) to (1, 26, 64, 48) HOT 3
- CoreGraphics resizing function from iOS (UIImage) to MacOS (NSImage) HOT 6
- PixelBuffer function from iOS (UIImage) to MacOS (NSImage) HOT 3
- UI Image to kCVPixelFormatType_422YpCbCr8FullRange pixel format not working HOT 4
- Add support for transpose with dataType int and float
- Change image to multiArray in case of converted mlmodel from TFlite
- Question about backprop HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from coremlhelpers.