How does Azure Machine Learning (AML) decide what 'type' an input is in the training data as this is causing an error - azure-machine-learning-studio

We have trained a network in AML based on a large training data-set with many inputs. For one of the inputs all the training data supplied was an integer amount. Nowhere in our model do we specify the type of the input fields and this input is a continuous field as opposed to a discrete one.
However in use in production, the AML web service was called with this input supplied as a decimal instead of a real and it threw an error:
Error Content: {"error":{"code":"BadArgument","message":"Invalid argument provided.","details":[{"code":"InputParseError","target":"input1","message":"Parsing of input vector failed. Verify the input vector has the correct number of columns and data types. Additional details: Input string was not in a correct format.."}]}}
If I edit the call to change the input from being a decimal to an integer it works perfectly.
Before we go change either the model or the calling code i would like to understand how/why this error is occurring?
I have done some research and cant seem to find anything that explains how AML decides the input "type" and whether it can be changed in the model.

Well persistent searching the net has revealed the correct answer (for me anyway). Essentially I needed to add the "Edit Metadata" module to my experiment then use the column selector to select the column in question and set its data type from integer to floating point. It seems that AML detected that all the training data was of type integer and hence automatically selected this data type on import of the training data.
See here for more details: https://learn.microsoft.com/en-us/azure/machine-learning/studio-module-reference/edit-metadata

Related

Using shacl to validate a property that has at most one value in its properties

I'm trying to create a shacl based on the ontology that my organization is developing (in dutch): https://wegenenverkeer.data.vlaanderen.be/
The objects described have attributes (properties), that have a specified datatype. The datatype can a primitive (like string or decimal) or complex, which means the property will have properties itself (nested properties). For example: an asset object A will have an attribute assetId which is a complex datatype DtcIdentificator, which consists of two properties itself. I have succesfully created a shacl that validates objects by creating multiple shapes and nesting them.
I now run into the problem of what we call union datatypes. These are a special kind of complex datatypes. They are still nested datatypes: the attribute with the union datatypes will have multiple properties but only exactly zero or one of those properties may have a value. If the attribute has 2 properties with values, it is invalid. How can I create such a constraint in shacl?
Example (in dutch): https://wegenenverkeer.data.vlaanderen.be/doc/implementatiemodel/union-datatypes/#Afmeting%20verkeersbord
A traffic sign (Verkeersbord, see https://wegenenverkeer.data.vlaanderen.be/doc/implementatiemodel/signalisatie/#Verkeersbord) can have a property afmeting (size) of the datatype DtuAfmetingVerkeersbord.
If an asset A of this type would exist, I could define its size as (in dotnotation):
A.afmeting.rond.waarde = 700
-or-
A.afmeting.driehoekig.waarde = 400
Both are valid ways of using the afmeting property, however, if they are both used for the same object, this becomes invalid, as only one property of A.afmeting may have a value.
I have tried using the union constraint in shacl, but soon found out that that has nothing to do with what we call "union datatypes"
I think the reason you are struggling is because this kind of problem is usually modelled differently. Basically you have different types of Traffic signs and these signs can have measurements. With the model as you described, A.afmeting.rond.waarde captures 2 ideas using 1 property: (a) the type and (b) the size. From your question, this seems to be the intend. However, this is usually not how this kind of problem is addressed.
A more intuitive design is for Traffic sign to have 2 different properties: (a) type and (b) a measurement. The Traffic sign types are achthoekig, driehoekig, etc. Then you can use SHACL to check that a traffic sign has either both or no properties for a traffic sign.

HFM Extract data to file is resulting in Parent Child error

I am trying to do a simple extract in HFM and I keep getting this error.
"Parent-Child name must be specified for Entity dimension due to value: [Parent Total]
Member found that requires parent name:"
All the members in the extract are valid members, this was verified using a smart view extract
The entity dimension does contain alternate hierarchies, i.e. the member in my extract does have two parents
This extract runs successfully when the expand only selection is selected
This is being done via Workiva-WData
The integration user has this level of access
Any help would be much appreciated.
I have tried running almost every combination of member and expand function available, BASE, ALLMEMBERS, IPARENTS, all result in that error.

Building A Global Object in Titanium to be written to sqlite3 database

This question is about implementation.
I'm building an android application with titanium.
There are multiple screens and i take data in each of them.
Each screen is a commonJS module
I want to write all the data i take to an sqlite3 database, but i suppose it would be inefficient to write them as i take inputs. Two ways come to my mind as to how to do this.
create an object and pass to each module to hold the data as i take them
create an object in the first module to hold the data and pass each data item to it by firing a custom event.
What i'm asking, is if there's a better approach to this or which of these two would be more efficient.
NB: I don't have a lot of screens, but that could change though.
Thanks.
Titanium.App.Properties are widely used for Global variable creation.
The following methods will help you to create global variable
setBool : Sets the value of a property as a Boolean data type
setDouble : Sets the value of a property as a double (double-precision, floating point) data type
setInt : Sets the value of a property as an integer data type
setList : Sets the value of a property as an array data type
setObject : Sets the value of a property as an object data type
setString : Sets the value of a property as a string data type
All the above methods will allow user to save corresponding type of data as gloabl. You may retrieve saved values using getBool, getDouble, getInt, getList, getObject, getString methods respectively.
i think Ti.App.properties set and get string would do fine for you here is example too
http://docs.appcelerator.com/titanium/3.0/#!/api/Titanium.App.Properties
Thanks

Determine if a value is flagged as Unknown Value

Recently Freebase added flags for values: Has No Values and Has Unknown Values. If I query a property's value it will give me null if it is empty or has one of these flags. How do I determine if the value really is empty or if it's flagged?
A good place to find out about something that you see on freebase.com is the source code that drives the site. In particular, for this case:
https://code.google.com/p/freebase-site/source/browse/trunk/www/lib/propbox/js/propbox-edit.js#640
The properties that you need to query are:
/freebase/valuenotation/has_no_value
/freebase/valuenotation/has_value
Here's an example:
https://www.freebase.com/m/05r3dj?links&lang=en&filter=%2Ffreebase%2Fvaluenotation%2Fhas_value

optional parameter addition to a colletion (asp.net C#)

Hello friends i am to add optional parameter to pass these in a method the parameter may vary every time.
And i need to pass these parameter to a method, so my question is how should i add these optional parameter to a collection and what kind of collection object should i use and how should i use that.
i elaborate here, i am having following fields.
1)course field(a drop down list) and on selected index change of course a check box list of corresponding branches are visible now i can select branches of choice by putting check mark on check boxes.(both course and branch are compulsory fields)
2)pass_out year which is a compulsory field.(a text field)
3)education gap which is optional so the text box may be empty as well and may having a digit as well.
4)required first year percent, second year, third year, final year, current degree, high school, senior secondary, gradation, post graduation, diploma percent, birth date which are all optional so these fields may also be empty or having a digit in the text box.
5) current backlog(a drop down list)having choices all, yes , no.
6)number of ATKT text box which may also be empty or can have a digit.
So i want to store all these variables value to some collection of object which will passed to a different method by passing all these variable from here,
But i am unable to figure out how should i store these optional variable to some object and how should i pass them to other method where all variable values will be taken out and an appropriate query will be written to interact with the data base to get the data table.
please elucidate me on this please. I am really not getting a feasible solution, i have thought of few options which i can let you know if you demand but those all seems to be tedious and difficult and redundant so i see help from you.
Don't bother with optional parameters or some collection of parameters, just decide how you will represent each value best, including how to represent empty values.
For a string value you can just use a null reference or an empty string. For a numeric value you can use a nullable int (int?). For a list of checkboxes where none is selected you can send an empty list.
When figuring out how to use this in a query to the database, it's easier if you have the values as parameters that always exist even if the values represent an empty value, rather than to have to parse out parameters from a collection where a parameter might be missing. Also, as you have different data types it's better if you can use an appropriate data type for each parameter, instead of casting everything into the same mold just to fit in a collection.

Resources