'Node' object has no attribute 'get_config'
HeshamMahrous opened this issue · 2 comments
Please find the following issue:
Do you have an idea this might be or library version mismatch ?
AttributeError Traceback (most recent call last)
in
----> 1 pmmlObj=KerasToPmml(model)
2 pmmlObj.export(open('predicitive_maintence.pmml','w'),0)
~\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.8_qbz5n2kfra8p0\LocalCache\local-packages\Python38\site-packages\nyoka\keras\keras_model_to_pmml.py in init(self, keras_model, model_name, description, copyright, dataSet, predictedClasses, script_args)
800 version="4.4", Header=KerasHeader(description=description, copyright=copyright),
801 DataDictionary=data_dict, TransformationDictionary= trans_dict, DeepNetwork=[
--> 802 KerasNetwork(keras_model=keras_model,
803 model_name=model_name,
804 dataSet=dataSet,
~\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.8_qbz5n2kfra8p0\LocalCache\local-packages\Python38\site-packages\nyoka\keras\keras_model_to_pmml.py in init(self, keras_model, model_name, dataSet, predictedClasses, script_args)
707 if not model_name:
708 model_namme = keras_model.name
--> 709 network_layers = self._create_layers(keras_model, dataSet, script_args)
710 local_trans = None
711 mining_schema = KerasMiningSchema(dataSet, predictedClasses)
~\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.8_qbz5n2kfra8p0\LocalCache\local-packages\Python38\site-packages\nyoka\keras\keras_model_to_pmml.py in _create_layers(self, keras_model, dataSet, script_args)
695 first_layer = model_layers[0]
696 if first_layer.class.name != "InputLayer":
--> 697 input_layer = self._create_an_input_layer(first_layer, dataSet, script_args)
698 if input_layer:
699 network_layers.append(input_layer)
~\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.8_qbz5n2kfra8p0\LocalCache\local-packages\Python38\site-packages\nyoka\keras\keras_model_to_pmml.py in _create_an_input_layer(self, layer, dataSet, script_args)
666 else:
667 input_dims = output_dims = str(tuple(list(in_shape[1:])))
--> 668 node_config = layer._inbound_nodes[0].get_config()
669 connection_layers = ", ".join(node_config['inbound_layers'])
670 input_layer = ny.NetworkLayer(
AttributeError: 'Node' object has no attribute 'get_config'
Hi @HeshamMahrous, could you please whether you are using supported version of libraries. The list of supported libraries and versions can be found here - List of supported libraries.
Note - The keras and retinanet exporter will be removed in 5.0.0 release.
Hi @HeshamMahrous! Since there is no update for last 3 weeks, I am going to close this issue. Feel free to re-open or create a new if required.