Notice (2018-05-24): bugzilla.xamarin.com is now in
Please join us on
Visual Studio Developer Community and in the
Mono organizations on
GitHub to continue tracking issues. Bugzilla will remain
available for reference in read-only mode. We will continue to work
on open Bugzilla bugs, copy them to the new locations
as needed for follow-up, and add the new items under Related
Our sincere thanks to everyone who has contributed on this bug
tracker over the years. Thanks also for your understanding as we
make these adjustments and improvements for the future.
Please create a new report on
Developer Community or GitHub with
your current version information, steps to reproduce, and relevant error
messages or log files if you are hitting an issue that looks similar to
this resolved bug and you do not yet see a matching new report.
MLDictionaryFeatureProvider (MonoTouch.Foundation.NSDictionary<MonoTouch.Foundation.NSString,MonoTouch.Foundation.NSObject> dictionary, out MonoTouch.Foundation.NSError error);
Should specify CoreML.MLFeatureValue as the second parameterized type rather than NSObject, as evidenced by the `Item` property and `IMLFeatureProvider.GetFeatureValue`.
I understand where this is coming from but I don't think it is a valid request.
CoreML.MLDictionaryFeatureProvider's .ctor seems to be taking a NSDictionary<NSString, NSObject> on purpose. At least it's the correct binding for the header which is:
- (nullable instancetype)initWithDictionary:(NSDictionary<NSString *, id> *)dictionary
It's taking an id and not a MLFeatureValue *
@property (readonly, nonatomic) NSDictionary<NSString *, MLFeatureValue *> *dictionary;
The swift version takes `Any` too when they could have strongly typed it: https://developer.apple.com/documentation/coreml/mldictionaryfeatureprovider/2879366-init
And here are the comments in the header file for the constructor:
* Create from a generic dictionary by converting all values to MLFeatureValues
* or from a dictionary with values already stored as MLFeatureValues.
* An error results if the values are not or cannot be represented as MLFeatureValues.
"from a generic dictionary by converting all values to MLFeatureValues".
I think we should leave it as is as it might be because of how they expect people to use the API, we'll see if Apple update that API in the future.