wynot12 commented on a change in pull request #203: [NEMO-360] Implementing an 
'XGBoostPolicy'
URL: https://github.com/apache/incubator-nemo/pull/203#discussion_r269532647
 
 

 ##########
 File path: 
compiler/optimizer/src/main/java/org/apache/nemo/compiler/optimizer/NemoOptimizer.java
 ##########
 @@ -113,6 +124,23 @@ public IRDAG optimizeAtRunTime(final IRDAG dag, final 
Message message) {
     return optimizationPolicy.runRunTimeOptimizations(dag, message);
   }
 
+  /**
+   * Operations to be done prior to the Compile-Time Optimizations.
+   * @param dag the DAG to process.
+   * @param policy the optimization policy to optimize the DAG with.
+   */
+  private void beforeCompileTimeOptimization(final IRDAG dag, final Policy 
policy) {
+    if (policy instanceof XGBoostPolicy) {
+      clientRPC.send(ControlMessage.DriverToClientMessage.newBuilder()
+        .setType(ControlMessage.DriverToClientMessageType.LaunchOptimization)
+        .setOptimizationType("xgboost")
+        .setDataCollected(ControlMessage.DataCollectMessage.newBuilder()
+          .setData(dag.irDAGSummary() + this.environmentTypeStr)
+          .build())
+        .build());
+    }
+  }
 
 Review comment:
   Please let me know the issue number and add it to the PR description, after 
registering this issue.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to