Commit 26ad1bfe authored by Christian Fuß's avatar Christian Fuß
Browse files

adjusted target code files

parent 49ac443c
Pipeline #185309 failed with stages
in 56 seconds
...@@ -4,7 +4,6 @@ import os ...@@ -4,7 +4,6 @@ import os
from CNNNet_Alexnet import Net_0 from CNNNet_Alexnet import Net_0
class CNNCreator_Alexnet: class CNNCreator_Alexnet:
_model_dir_ = "model/Alexnet/" _model_dir_ = "model/Alexnet/"
_model_prefix_ = "model" _model_prefix_ = "model"
...@@ -52,8 +51,8 @@ class CNNCreator_Alexnet: ...@@ -52,8 +51,8 @@ class CNNCreator_Alexnet:
self.networks[0] = Net_0(data_mean=data_mean, data_std=data_std) self.networks[0] = Net_0(data_mean=data_mean, data_std=data_std)
self.networks[0].collect_params().initialize(self.weight_initializer, ctx=context) self.networks[0].collect_params().initialize(self.weight_initializer, ctx=context)
self.networks[0].hybridize() self.networks[0].hybridize()
self.networks[0](mx.nd.zeros((1,3,224,224,), ctx=context)) self.networks[0](
mx.nd.zeros((1,3,224,224,), ctx=context) )
if not os.path.exists(self._model_dir_): if not os.path.exists(self._model_dir_):
os.makedirs(self._model_dir_) os.makedirs(self._model_dir_)
......
...@@ -4,7 +4,6 @@ import os ...@@ -4,7 +4,6 @@ import os
from CNNNet_CifarClassifierNetwork import Net_0 from CNNNet_CifarClassifierNetwork import Net_0
class CNNCreator_CifarClassifierNetwork: class CNNCreator_CifarClassifierNetwork:
_model_dir_ = "model/CifarClassifierNetwork/" _model_dir_ = "model/CifarClassifierNetwork/"
_model_prefix_ = "model" _model_prefix_ = "model"
...@@ -52,8 +51,8 @@ class CNNCreator_CifarClassifierNetwork: ...@@ -52,8 +51,8 @@ class CNNCreator_CifarClassifierNetwork:
self.networks[0] = Net_0(data_mean=data_mean, data_std=data_std) self.networks[0] = Net_0(data_mean=data_mean, data_std=data_std)
self.networks[0].collect_params().initialize(self.weight_initializer, ctx=context) self.networks[0].collect_params().initialize(self.weight_initializer, ctx=context)
self.networks[0].hybridize() self.networks[0].hybridize()
self.networks[0](mx.nd.zeros((1,3,32,32,), ctx=context)) self.networks[0](
mx.nd.zeros((1,3,32,32,), ctx=context) )
if not os.path.exists(self._model_dir_): if not os.path.exists(self._model_dir_):
os.makedirs(self._model_dir_) os.makedirs(self._model_dir_)
......
...@@ -4,7 +4,6 @@ import os ...@@ -4,7 +4,6 @@ import os
from CNNNet_VGG16 import Net_0 from CNNNet_VGG16 import Net_0
class CNNCreator_VGG16: class CNNCreator_VGG16:
_model_dir_ = "model/VGG16/" _model_dir_ = "model/VGG16/"
_model_prefix_ = "model" _model_prefix_ = "model"
...@@ -52,8 +51,8 @@ class CNNCreator_VGG16: ...@@ -52,8 +51,8 @@ class CNNCreator_VGG16:
self.networks[0] = Net_0(data_mean=data_mean, data_std=data_std) self.networks[0] = Net_0(data_mean=data_mean, data_std=data_std)
self.networks[0].collect_params().initialize(self.weight_initializer, ctx=context) self.networks[0].collect_params().initialize(self.weight_initializer, ctx=context)
self.networks[0].hybridize() self.networks[0].hybridize()
self.networks[0](mx.nd.zeros((1,3,224,224,), ctx=context)) self.networks[0](
mx.nd.zeros((1,3,224,224,), ctx=context) )
if not os.path.exists(self._model_dir_): if not os.path.exists(self._model_dir_):
os.makedirs(self._model_dir_) os.makedirs(self._model_dir_)
......
import mxnet as mx import mxnet as mx
import logging import logging
import os import os
from CNNNet_CriticNetwork import Net_0 from CNNNet_CriticNetwork import Net_0
class CNNCreator_CriticNetwork: class CNNCreator_CriticNetwork:
...@@ -50,7 +51,9 @@ class CNNCreator_CriticNetwork: ...@@ -50,7 +51,9 @@ class CNNCreator_CriticNetwork:
self.networks[0] = Net_0(data_mean=data_mean, data_std=data_std) self.networks[0] = Net_0(data_mean=data_mean, data_std=data_std)
self.networks[0].collect_params().initialize(self.weight_initializer, ctx=context) self.networks[0].collect_params().initialize(self.weight_initializer, ctx=context)
self.networks[0].hybridize() self.networks[0].hybridize()
self.networks[0](mx.nd.zeros((1,8,), ctx=context), mx.nd.zeros((1,3,), ctx=context)) self.networks[0](
mx.nd.zeros((1,8,), ctx=context) ,
mx.nd.zeros((1,3,), ctx=context) )
if not os.path.exists(self._model_dir_): if not os.path.exists(self._model_dir_):
os.makedirs(self._model_dir_) os.makedirs(self._model_dir_)
......
import mxnet as mx import mxnet as mx
import logging import logging
import os import os
from CNNNet_RosCriticNetwork import Net_0 from CNNNet_RosCriticNetwork import Net_0
class CNNCreator_RosCriticNetwork: class CNNCreator_RosCriticNetwork:
...@@ -50,7 +51,9 @@ class CNNCreator_RosCriticNetwork: ...@@ -50,7 +51,9 @@ class CNNCreator_RosCriticNetwork:
self.networks[0] = Net_0(data_mean=data_mean, data_std=data_std) self.networks[0] = Net_0(data_mean=data_mean, data_std=data_std)
self.networks[0].collect_params().initialize(self.weight_initializer, ctx=context) self.networks[0].collect_params().initialize(self.weight_initializer, ctx=context)
self.networks[0].hybridize() self.networks[0].hybridize()
self.networks[0](mx.nd.zeros((1,8,), ctx=context), mx.nd.zeros((1,3,), ctx=context)) self.networks[0](
mx.nd.zeros((1,8,), ctx=context) ,
mx.nd.zeros((1,3,), ctx=context) )
if not os.path.exists(self._model_dir_): if not os.path.exists(self._model_dir_):
os.makedirs(self._model_dir_) os.makedirs(self._model_dir_)
......
import mxnet as mx import mxnet as mx
import logging import logging
import os import os
from CNNNet_CriticNetwork import Net_0 from CNNNet_CriticNetwork import Net_0
class CNNCreator_CriticNetwork: class CNNCreator_CriticNetwork:
...@@ -50,7 +51,9 @@ class CNNCreator_CriticNetwork: ...@@ -50,7 +51,9 @@ class CNNCreator_CriticNetwork:
self.networks[0] = Net_0(data_mean=data_mean, data_std=data_std) self.networks[0] = Net_0(data_mean=data_mean, data_std=data_std)
self.networks[0].collect_params().initialize(self.weight_initializer, ctx=context) self.networks[0].collect_params().initialize(self.weight_initializer, ctx=context)
self.networks[0].hybridize() self.networks[0].hybridize()
self.networks[0](mx.nd.zeros((1,8,), ctx=context), mx.nd.zeros((1,3,), ctx=context)) self.networks[0](
mx.nd.zeros((1,8,), ctx=context) ,
mx.nd.zeros((1,3,), ctx=context) )
if not os.path.exists(self._model_dir_): if not os.path.exists(self._model_dir_):
os.makedirs(self._model_dir_) os.makedirs(self._model_dir_)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment