Skip to content
This repository was archived by the owner on Nov 16, 2023. It is now read-only.

up version #210

Merged
merged 9 commits into from
Aug 6, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -199,6 +199,7 @@ then
cp "${BuildOutputDir}/${__configuration}"/DotNetBridge.dll "${__currentScriptDir}/src/python/nimbusml/internal/libs/"
cp "${BuildOutputDir}/${__configuration}"/pybridge.so "${__currentScriptDir}/src/python/nimbusml/internal/libs/"

# ls "${BuildOutputDir}/${__configuration}/Platform/${PublishDir}"/publish/
if [ ${PythonVersion} = 2.7 ]
then
cp "${BuildOutputDir}/${__configuration}/Platform/${PublishDir}"/publish/*.dll "${__currentScriptDir}/src/python/nimbusml/internal/libs/"
Expand Down
6 changes: 4 additions & 2 deletions build/libs_linux.txt
Original file line number Diff line number Diff line change
@@ -1,14 +1,16 @@
Newtonsoft.Json.dll
libCpuMathNative.so
libFactorizationMachineNative.so
libFastTreeNative.so
libLdaNative.so
libMklImports.so
libMklProxyNative.so
libSymSgdNative.so
lib_lightgbm.so
libtensorflow.so
libtensorflow_framework.so
libtensorflow_framework.so.1
libonnxruntime.so
System.Drawing.Common.dll
TensorFlow.NET.dll
Microsoft.DataPrep.dll
Microsoft.DPrep.*
Microsoft.ML.*
6 changes: 4 additions & 2 deletions build/libs_mac.txt
Original file line number Diff line number Diff line change
@@ -1,14 +1,16 @@
Newtonsoft.Json.dll
libCpuMathNative.dylib
libFactorizationMachineNative.dylib
libFastTreeNative.dylib
libLdaNative.dylib
libMklImports.dylib
libMklProxyNative.dylib
libSymSgdNative.dylib
lib_lightgbm.dylib
libtensorflow.dylib
libtensorflow_framework.dylib
libonnxruntime.dylib
libtensorflow_framework.1.dylib
System.Drawing.Common.dll
TensorFlow.NET.dll
Microsoft.DataPrep.dll
Microsoft.DPrep.*
Microsoft.ML.*
3 changes: 2 additions & 1 deletion build/libs_win.txt
Original file line number Diff line number Diff line change
@@ -1,14 +1,15 @@
Google.Protobuf.dll
Newtonsoft.Json.dll
CpuMathNative.dll
FactorizationMachineNative.dll
FastTreeNative.dll
LdaNative.dll
lib_lightgbm.dll
libiomp5md.dll
MklImports.dll
MklProxyNative.dll
SymSgdNative.dll
tensorflow.dll
TensorFlow.NET.dll
System.Drawing.Common.dll
Microsoft.DataPrep.dll
Microsoft.DPrep.*
Expand Down
24 changes: 13 additions & 11 deletions src/DotNetBridge/DotNetBridge.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -31,17 +31,19 @@
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets>
</PackageReference>
<PackageReference Include="Microsoft.ML" Version="1.2.0" />
<PackageReference Include="Microsoft.ML.CpuMath" Version="1.2.0" />
<PackageReference Include="Microsoft.ML.EntryPoints" Version="0.14.0" />
<PackageReference Include="Microsoft.ML.Mkl.Components" Version="1.2.0" />
<PackageReference Include="Microsoft.ML.Mkl.Redist" Version="1.2.0" />
<PackageReference Include="Microsoft.ML.ImageAnalytics" Version="1.2.0" />
<PackageReference Include="Microsoft.ML.LightGBM" Version="1.2.0" />
<PackageReference Include="Microsoft.ML.OnnxTransformer" Version="1.2.0" />
<PackageReference Include="Microsoft.ML.TensorFlow" Version="1.2.0" />
<PackageReference Include="Microsoft.ML.Ensemble" Version="0.14.0" />
<PackageReference Include="Microsoft.ML.TimeSeries" Version="1.2.0" />
<PackageReference Include="Microsoft.ML" Version="1.3.1" />
<PackageReference Include="Microsoft.ML.CpuMath" Version="1.3.1" />
<PackageReference Include="Microsoft.ML.EntryPoints" Version="0.15.1" />
<PackageReference Include="Microsoft.ML.Mkl.Components" Version="1.3.1" />
<PackageReference Include="Microsoft.ML.ImageAnalytics" Version="1.3.1" />
<PackageReference Include="Microsoft.ML.LightGBM" Version="1.3.1" />
<PackageReference Include="Microsoft.ML.OnnxTransformer" Version="1.3.1" />
<PackageReference Include="Microsoft.ML.TensorFlow" Version="1.3.1" />
<PackageReference Include="Microsoft.ML.Dnn" Version="0.15.1" />
<PackageReference Include="Microsoft.ML.Ensemble" Version="0.15.1" />
<PackageReference Include="Microsoft.ML.TimeSeries" Version="1.3.1" />
<PackageReference Include="Microsoft.DataPrep" Version="0.0.1.5-preview" />
<PackageReference Include="TensorFlow.NET" Version="0.10.10" />
<PackageReference Include="SciSharp.TensorFlow.Redist" Version="1.14.0" />
</ItemGroup>
</Project>
23 changes: 13 additions & 10 deletions src/Platforms/build.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -11,17 +11,20 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Microsoft.ML" Version="1.2.0" />
<PackageReference Include="Microsoft.ML.CpuMath" Version="1.2.0" />
<PackageReference Include="Microsoft.ML.EntryPoints" Version="0.14.0" />
<PackageReference Include="Microsoft.ML.Mkl.Components" Version="1.2.0" />
<PackageReference Include="Microsoft.ML.ImageAnalytics" Version="1.2.0" />
<PackageReference Include="Microsoft.ML.LightGBM" Version="1.2.0" />
<PackageReference Include="Microsoft.ML.OnnxTransformer" Version="1.2.0" />
<PackageReference Include="Microsoft.ML.TensorFlow" Version="1.2.0" />
<PackageReference Include="Microsoft.ML.Ensemble" Version="0.14.0" />
<PackageReference Include="Microsoft.ML.TimeSeries" Version="1.2.0" />
<PackageReference Include="Microsoft.ML" Version="1.3.1" />
<PackageReference Include="Microsoft.ML.CpuMath" Version="1.3.1" />
<PackageReference Include="Microsoft.ML.EntryPoints" Version="0.15.1" />
<PackageReference Include="Microsoft.ML.Mkl.Components" Version="1.3.1" />
<PackageReference Include="Microsoft.ML.ImageAnalytics" Version="1.3.1" />
<PackageReference Include="Microsoft.ML.LightGBM" Version="1.3.1" />
<PackageReference Include="Microsoft.ML.OnnxTransformer" Version="1.3.1" />
<PackageReference Include="Microsoft.ML.TensorFlow" Version="1.3.1" />
<PackageReference Include="Microsoft.ML.Dnn" Version="0.15.1" />
<PackageReference Include="Microsoft.ML.Ensemble" Version="0.15.1" />
<PackageReference Include="Microsoft.ML.TimeSeries" Version="1.3.1" />
<PackageReference Include="Microsoft.DataPrep" Version="0.0.1.5-preview" />
<PackageReference Include="TensorFlow.NET" Version="0.10.10" />
<PackageReference Include="SciSharp.TensorFlow.Redist" Version="1.14.0" />
</ItemGroup>

</Project>
2 changes: 1 addition & 1 deletion src/python/nimbusml/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
Microsoft Machine Learning for Python
"""

__version__ = '1.2.1'
__version__ = '1.3.0'

# CoreCLR version of MicrosoftML is built on Windows.
# But file permissions are not preserved when it's copied to Linux.
Expand Down
2 changes: 1 addition & 1 deletion src/python/nimbusml/ensemble/lightgbmbinaryclassifier.py
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ def __init__(
unbalanced_sets=False,
weight_of_positive_examples=1.0,
sigmoid=0.5,
evaluation_metric='Default',
evaluation_metric='Logloss',
maximum_bin_count_per_feature=255,
verbose=False,
silent=True,
Expand Down
2 changes: 1 addition & 1 deletion src/python/nimbusml/ensemble/lightgbmclassifier.py
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ def __init__(
unbalanced_sets=False,
use_softmax=None,
sigmoid=0.5,
evaluation_metric='Default',
evaluation_metric='Error',
maximum_bin_count_per_feature=255,
verbose=False,
silent=True,
Expand Down
2 changes: 1 addition & 1 deletion src/python/nimbusml/ensemble/lightgbmranker.py
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@ def __init__(
caching='Auto',
custom_gains=[0, 3, 7, 15, 31, 63, 127, 255, 511, 1023, 2047, 4095],
sigmoid=0.5,
evaluation_metric='Default',
evaluation_metric='NormalizedDiscountedCumulativeGain',
maximum_bin_count_per_feature=255,
verbose=False,
silent=True,
Expand Down
2 changes: 1 addition & 1 deletion src/python/nimbusml/ensemble/lightgbmregressor.py
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ def __init__(
booster=None,
normalize='Auto',
caching='Auto',
evaluation_metric='Default',
evaluation_metric='RootMeanSquaredError',
maximum_bin_count_per_feature=255,
verbose=False,
silent=True,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ def __init__(
unbalanced_sets=False,
weight_of_positive_examples=1.0,
sigmoid=0.5,
evaluation_metric='Default',
evaluation_metric='Logloss',
maximum_bin_count_per_feature=255,
verbose=False,
silent=True,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ def __init__(
unbalanced_sets=False,
use_softmax=None,
sigmoid=0.5,
evaluation_metric='Default',
evaluation_metric='Error',
maximum_bin_count_per_feature=255,
verbose=False,
silent=True,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ def __init__(
caching='Auto',
custom_gains=[0, 3, 7, 15, 31, 63, 127, 255, 511, 1023, 2047, 4095],
sigmoid=0.5,
evaluation_metric='Default',
evaluation_metric='NormalizedDiscountedCumulativeGain',
maximum_bin_count_per_feature=255,
verbose=False,
silent=True,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ def __init__(
booster=None,
normalize='Auto',
caching='Auto',
evaluation_metric='Default',
evaluation_metric='RootMeanSquaredError',
maximum_bin_count_per_feature=255,
verbose=False,
silent=True,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,41 +52,8 @@ class TensorFlowScorer(BasePipelineItem, DefaultSignature):

:param output_columns: The name of the outputs.

:param label_column: Training labels.

:param tensor_flow_label: TensorFlow label node.

:param optimization_operation: The name of the optimization operation in
the TensorFlow graph.

:param loss_operation: The name of the operation in the TensorFlow graph to
compute training loss (Optional).

:param metric_operation: The name of the operation in the TensorFlow graph
to compute performance metric during training (Optional).

:param batch_size: Number of samples to use for mini-batch training.

:param epoch: Number of training iterations.

:param learning_rate_operation: The name of the operation in the TensorFlow
graph which sets optimizer learning rate (Optional).

:param learning_rate: Determines the size of the step taken in the
direction of the gradient in each step of the learning process. This
determines how fast or slow the learner converges on the optimal
solution. If the step size is too big, you might overshoot the optimal
solution. If the step size is too small, training takes longer to
converge to the best solution.

:param save_location_operation: Name of the input in TensorFlow graph that
specifiy the location for saving/restoring models from disk.

:param save_operation: Name of the input in TensorFlow graph that specifiy
the location for saving/restoring models from disk.

:param re_train: Retrain TensorFlow model.

:param add_batch_dimension_inputs: Add a batch dimension to the input e.g.
input = [224, 224, 3] => [-1, 224, 224, 3].

Expand All @@ -105,18 +72,7 @@ def __init__(
model_location,
input_columns=None,
output_columns=None,
label_column=None,
tensor_flow_label=None,
optimization_operation=None,
loss_operation=None,
metric_operation=None,
batch_size=64,
epoch=5,
learning_rate_operation=None,
learning_rate=0.01,
save_location_operation='save/Const',
save_operation='save/control_dependency',
re_train=False,
add_batch_dimension_inputs=False,
**params):
BasePipelineItem.__init__(
Expand All @@ -125,18 +81,7 @@ def __init__(
self.model_location = model_location
self.input_columns = input_columns
self.output_columns = output_columns
self.label_column = label_column
self.tensor_flow_label = tensor_flow_label
self.optimization_operation = optimization_operation
self.loss_operation = loss_operation
self.metric_operation = metric_operation
self.batch_size = batch_size
self.epoch = epoch
self.learning_rate_operation = learning_rate_operation
self.learning_rate = learning_rate
self.save_location_operation = save_location_operation
self.save_operation = save_operation
self.re_train = re_train
self.add_batch_dimension_inputs = add_batch_dimension_inputs

@property
Expand All @@ -149,18 +94,7 @@ def _get_node(self, **all_args):
model_location=self.model_location,
input_columns=self.input_columns,
output_columns=self.output_columns,
label_column=self.label_column,
tensor_flow_label=self.tensor_flow_label,
optimization_operation=self.optimization_operation,
loss_operation=self.loss_operation,
metric_operation=self.metric_operation,
batch_size=self.batch_size,
epoch=self.epoch,
learning_rate_operation=self.learning_rate_operation,
learning_rate=self.learning_rate,
save_location_operation=self.save_location_operation,
save_operation=self.save_operation,
re_train=self.re_train,
add_batch_dimension_inputs=self.add_batch_dimension_inputs)

all_args.update(algo_args)
Expand Down
10 changes: 8 additions & 2 deletions src/python/nimbusml/internal/entrypoints/models_onnxconverter.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,14 +10,15 @@

def models_onnxconverter(
onnx,
model,
data_file=None,
json=None,
name=None,
domain=None,
inputs_to_drop=None,
outputs_to_drop=None,
model=None,
onnx_version='Stable',
predictive_model=None,
**params):
"""
**Description**
Expand All @@ -40,6 +41,8 @@ def models_onnxconverter(
"Stable" or "Experimental". If "Experimental" is used,
produced model can contain components that is not officially
supported in ONNX standard. (inputs).
:param predictive_model: Predictor model that needs to be
converted to ONNX format. (inputs).
"""

entrypoint_name = 'Models.OnnxConverter'
Expand Down Expand Up @@ -85,7 +88,7 @@ def models_onnxconverter(
if model is not None:
inputs['Model'] = try_set(
obj=model,
none_acceptable=False,
none_acceptable=True,
is_of_type=str)
if onnx_version is not None:
inputs['OnnxVersion'] = try_set(
Expand All @@ -95,6 +98,9 @@ def models_onnxconverter(
values=[
'Stable',
'Experimental'])
if predictive_model is not None:
inputs['PredictiveModel'] = try_set(
obj=predictive_model, none_acceptable=True, is_of_type=str)

input_variables = {
x for x in unlist(inputs.values())
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ def trainers_lightgbmbinaryclassifier(
unbalanced_sets=False,
weight_of_positive_examples=1.0,
sigmoid=0.5,
evaluation_metric='Default',
evaluation_metric='Logloss',
maximum_bin_count_per_feature=255,
verbose=False,
silent=True,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ def trainers_lightgbmclassifier(
unbalanced_sets=False,
use_softmax=None,
sigmoid=0.5,
evaluation_metric='Default',
evaluation_metric='Error',
maximum_bin_count_per_feature=255,
verbose=False,
silent=True,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ def trainers_lightgbmranker(
caching='Auto',
custom_gains=[0, 3, 7, 15, 31, 63, 127, 255, 511, 1023, 2047, 4095],
sigmoid=0.5,
evaluation_metric='Default',
evaluation_metric='NormalizedDiscountedCumulativeGain',
maximum_bin_count_per_feature=255,
verbose=False,
silent=True,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ def trainers_lightgbmregressor(
row_group_column_name=None,
normalize_features='Auto',
caching='Auto',
evaluation_metric='Default',
evaluation_metric='RootMeanSquaredError',
maximum_bin_count_per_feature=255,
verbose=False,
silent=True,
Expand Down
Loading