Skip to content

Commit 877e796

Browse files
brs96FlorentinDbreakanalysisorazve
committed
WIP add mutateProperty
Co-authored-by: Florentin Dörre <[email protected]> Co-authored-by: Jacob Sznajdman <[email protected]> Co-authored-by: Olga Razvenskaia <[email protected]>
1 parent 84b8cef commit 877e796

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

graphdatascience/gnn/gnn_nc_runner.py

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ def train(
3535
self._query_runner.run_query(
3636
"CALL gds.upload.graph($config)",
3737
params={
38-
"config": {"mlTrainingConfig": mlTrainingConfig, "graphName": graph_name, "modelName": model_name},
38+
"config": {"mlTrainingConfig": mlTrainingConfig, "graphName": graph_name, "modelName": model_name, "mutateProperty": "TODO,REMOVE"},
3939
},
4040
)
4141

@@ -45,14 +45,17 @@ def predict(
4545
model_name: str,
4646
feature_properties: List[str],
4747
relationship_types: List[str],
48+
mutateProperty: str,
4849
target_node_label: str = None,
4950
node_labels: List[str] = None,
5051
) -> "Series[Any]": # noqa: F821
5152
mlConfigMap = {
5253
"featureProperties": feature_properties,
5354
"job_type": "predict",
5455
"nodeProperties": feature_properties,
55-
"relationshipTypes": relationship_types
56+
"relationshipTypes": relationship_types,
57+
##TODO cleanup the same from outside config
58+
"mutateProperty": mutateProperty
5659
}
5760
if target_node_label:
5861
mlConfigMap["targetNodeLabel"] = target_node_label
@@ -63,6 +66,6 @@ def predict(
6366
self._query_runner.run_query(
6467
"CALL gds.upload.graph($config)",
6568
params={
66-
"config": {"mlTrainingConfig": mlTrainingConfig, "graphName": graph_name, "modelName": model_name},
69+
"config": {"mlTrainingConfig": mlTrainingConfig, "graphName": graph_name, "modelName": model_name, "mutateProperty": mutateProperty},
6770
},
6871
) # type: ignore

0 commit comments

Comments
 (0)