diff --git a/html/docs/modelFunctional.html b/html/docs/modelFunctional.html index 51fed453..028e244a 100644 --- a/html/docs/modelFunctional.html +++ b/html/docs/modelFunctional.html @@ -334,9 +334,9 @@ ... // necessary configurations - inputs: [input], - outputs: [addLayer], - outputsOrder: ["input", "conv1", "conv2", "conv3", "add"], + inputs: [ input ], + outputs: [ addLayer ], + outputsOrder: [ "conv1", "conv2", "conv3", "add" ], layerShape: "rect", layerInitStatus: "close", stats: true @@ -351,48 +351,65 @@
let input = new TSP.layers.GreyscaleInput({
- shape: [28, 28, 1]
-});
+ let input = new TSP.layers.GreyscaleInput( {
+
+ shape: [ 28, 28, 1 ]
+
+} );
+
+let layer1 = new TSP.layers.Conv2d( {
-let layer1 = new TSP.layers.Conv2d({
kernelSize: 2,
filters: 36,
strides: 1,
- padding: "same"
-});
+ padding: "same",
+ name: "conv1"
+
+} );
layer1.apply( input );
-let layer2 = new TSP.layers.Conv2d({
+let layer2 = new TSP.layers.Conv2d( {
+
kernelSize: 2,
filters: 36,
strides: 1,
- padding: "same"
-});
+ padding: "same",
+ name: "conv2"
+
+} );
layer2.apply( input );
-let layer3 = new TSP.layers.Conv2d({
+let layer3 = new TSP.layers.Conv2d( {
+
kernelSize: 2,
filters: 4,
strides: 1,
- padding: "same"
-});
+ padding: "same",
+ name: "conv3"
+
+} );
layer3.apply( layer2 );
-let addLayer = new TSP.layers.Add([layer1, layer3]);
+let addLayer = new TSP.layers.Add(
+
+ [ layer1, layer3 ],
+
+ { name: "add" }
+
+);
let model = new TSP.model.Model(container, {
...
- inputs: [input],
- outputs: [addLayer],
- outputsOrder: ["input", "conv1", "conv2", "conv3", "add"],
+ inputs: [ input ],
+ outputs: [ addLayer ],
+ outputsOrder: [ "conv1", "conv2", "conv3", "add" ],
...
-});
+} );
let model = new TSP.model.Model( container, {
...
- // necessary configurations
- inputs: [input],
- outputs: [addLayer],
- outputsOrder: ["input", "conv1", "conv2", "conv3", "add"],
+ // 模型参数配置
+ inputs: [ input ],
+ outputs: [ addLayer ],
+ outputsOrder: [ "conv1", "conv2", "conv3", "add" ],
layerShape: "rect",
layerInitStatus: "close",
stats: true
@@ -350,48 +350,65 @@
- let input = new TSP.layers.GreyscaleInput({
- shape: [28, 28, 1]
-});
+ let input = new TSP.layers.GreyscaleInput( {
+
+ shape: [ 28, 28, 1 ]
+
+} );
+
+let layer1 = new TSP.layers.Conv2d( {
-let layer1 = new TSP.layers.Conv2d({
kernelSize: 2,
filters: 36,
strides: 1,
- padding: "same"
-});
+ padding: "same",
+ name: "conv1"
+
+} );
layer1.apply( input );
-let layer2 = new TSP.layers.Conv2d({
+let layer2 = new TSP.layers.Conv2d( {
+
kernelSize: 2,
filters: 36,
strides: 1,
- padding: "same"
-});
+ padding: "same",
+ name: "conv2"
+
+} );
layer2.apply( input );
-let layer3 = new TSP.layers.Conv2d({
+let layer3 = new TSP.layers.Conv2d( {
+
kernelSize: 2,
filters: 4,
strides: 1,
- padding: "same"
-});
+ padding: "same",
+ name: "conv3"
+
+} );
layer3.apply( layer2 );
-let addLayer = new TSP.layers.Add([layer1, layer3]);
+let addLayer = new TSP.layers.Add(
+
+ [ layer1, layer3 ],
+
+ { name: "add" }
+
+);
let model = new TSP.model.Model(container, {
...
- inputs: [input],
- outputs: [addLayer],
- outputsOrder: ["input", "conv1", "conv2", "conv3", "add"],
+ inputs: [ input ],
+ outputs: [ addLayer ],
+ outputsOrder: [ "conv1", "conv2", "conv3", "add" ],
...
-});
+} );
@@ -423,7 +440,7 @@
- Property
+ 属性
.inputs : Layer[]
@@ -468,7 +485,7 @@
表示输出层对象的名称列表。
filter_center_focus
- 展示输出层对象的输出顺序。
+ 列表中的每一个名称对应了 TSP 模型中,各个 TSP.Layer 对象的 "name" 属性的值。
filter_center_focus
其输出顺序代表了预处理的神经网络模型的中间层计算输出的顺序。
@@ -548,7 +565,7 @@
- Method
+ 方法
.init( callback ) : void
diff --git a/html/docs/modelSequential.html b/html/docs/modelSequential.html
index 1ad69eee..e63c88ae 100644
--- a/html/docs/modelSequential.html
+++ b/html/docs/modelSequential.html
@@ -516,7 +516,7 @@
- .add( layer ) : void
+ .add( layer ) : void
- filter_center_focus
diff --git a/html/docs/modelSequential_zh.html b/html/docs/modelSequential_zh.html
index 7e65534e..5b84e45a 100644
--- a/html/docs/modelSequential_zh.html
+++ b/html/docs/modelSequential_zh.html
@@ -509,7 +509,7 @@
- .add( layer ) : void
+ .add( layer ) : void
- filter_center_focus