d56be803b77f08fda145df0374220a0cdae71193
java/com.sap.sailing.windestimation.lab/src/com/sap/sailing/windestimation/model/SimpleModelsTrainingPart1.java
| ... | ... | @@ -58,7 +58,10 @@ public class SimpleModelsTrainingPart1 { |
| 58 | 58 | * maneuvers to use for training which defaults to 80; {@code args[2]} may contain a percentage of the |
| 59 | 59 | * maneuvers to use for testing which defaults to 20. If {@code args[3]} is also provided, it is taken to |
| 60 | 60 | * be the file system path for storing the models that result from the training process; with this, the |
| 61 | - * models are not stored in MongoDB which otherwise would be the default. |
|
| 61 | + * models are not stored in MongoDB which otherwise would be the default. If {@code args[4]} is provided and |
|
| 62 | + * is something that {@link Boolean#valueOf(String)} evaluates to {@code true} then visuals are presented |
|
| 63 | + * (requiring a display to be available to the Java process which may, e.g., not be the case for a docker |
|
| 64 | + * container) that show the results of outlier removal for the wind regressions. |
|
| 62 | 65 | */ |
| 63 | 66 | public static void main(String[] args) throws Exception { |
| 64 | 67 | final String bearerToken = args[0]; |
| ... | ... | @@ -106,15 +109,20 @@ public class SimpleModelsTrainingPart1 { |
| 106 | 109 | }); |
| 107 | 110 | awaitThreadPoolCompletion(); |
| 108 | 111 | // The following code would open pop-up windows that display charts of original TWD regressions before cleansing: |
| 109 | - AggregatedDurationDimensionPlot.main(args); |
|
| 110 | - AggregatedDistanceDimensionPlot.main(args); |
|
| 112 | + final boolean showCharts = args.length > 4 && Boolean.valueOf(args[4]); |
|
| 113 | + if (showCharts) { |
|
| 114 | + AggregatedDurationDimensionPlot.main(args); |
|
| 115 | + AggregatedDistanceDimensionPlot.main(args); |
|
| 116 | + } |
|
| 111 | 117 | enforceMonotonicZeroMeanSigmaGrowth(AggregatedSingleDimensionType.DURATION); |
| 112 | 118 | enforceMonotonicZeroMeanSigmaGrowth(AggregatedSingleDimensionType.DISTANCE); |
| 113 | 119 | // The following code would open pop-up windows that display charts of original and "cleansed" TWD regressions: |
| 114 | - AggregatedDurationDimensionPlot.main(args); |
|
| 115 | - showInfoAboutIntervalAdjustments(DurationBasedTwdTransitionRegressorModelContext.class, DurationValueRange.class); |
|
| 116 | - AggregatedDistanceDimensionPlot.main(args); |
|
| 117 | - showInfoAboutIntervalAdjustments(DistanceBasedTwdTransitionRegressorModelContext.class, DistanceValueRange.class); |
|
| 120 | + if (showCharts) { |
|
| 121 | + AggregatedDurationDimensionPlot.main(args); |
|
| 122 | + showInfoAboutIntervalAdjustments(DurationBasedTwdTransitionRegressorModelContext.class, DurationValueRange.class); |
|
| 123 | + AggregatedDistanceDimensionPlot.main(args); |
|
| 124 | + showInfoAboutIntervalAdjustments(DistanceBasedTwdTransitionRegressorModelContext.class, DistanceValueRange.class); |
|
| 125 | + } |
|
| 118 | 126 | DurationBasedTwdTransitionStdRegressorTrainer.train(modelStore); |
| 119 | 127 | DistanceBasedTwdTransitionStdRegressorTrainer.train(modelStore); |
| 120 | 128 | Thread.sleep(1000); |
wiki/howto/development/ci.md
| ... | ... | @@ -78,7 +78,7 @@ The image has been crafted specifically to contain the tools required for the bu |
| 78 | 78 | echo "deb https://repo.mongodb.org/apt/ubuntu focal/mongodb-org/4.4 multiverse" >/etc/apt/sources.list.d/mongodb-org-4.4.list |
| 79 | 79 | apt-get -y update |
| 80 | 80 | apt-get -y upgrade |
| 81 | - apt-get -y install google-chrome-stable mongodb-org fwupd linux-aws linux-headers-aws linux-image-aws |
|
| 81 | + apt-get -y install google-chrome-stable maven mongodb-org fwupd linux-aws linux-headers-aws linux-image-aws |
|
| 82 | 82 | apt-get -y autoremove |
| 83 | 83 | cd /tmp |
| 84 | 84 | wget https://chromedriver.storage.googleapis.com/2.41/chromedriver_linux64.zip |