DataFrameに対するMachine LearningライブラリーであるMLを試す。入門PySpark Ch-06 ———————& […]
Author: anesth
Spark実践 #4 PySpark MLlib
PySparkの学習を通じて、Sparkの解析プロセスがRDDから、DataFrameへ移行していること、さらにMLlibの開発は終了し、MLに移行していることなどを学ぶ。 今回は、799万件の米国における2014年と2 […]
Spark実践 #3 PySpark DataFrames
PySparkに挑戦:テキストブックは、入門PySpark ————————— ~/.bash_profile […]
Spark実践 #2 Spark.mlによる分類の実装
「詳解Apache Spark」の例で毒キノコの外見判別ー決定木 ーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーー データは、UCIの機械学習さいとより、 https://archive.i […]
Spark実践 #1
自前のデータでSparkに挑戦してみる。 データは、昇圧剤の使用の有無と他の術前因子の相関を見る24010件のコード化した過去4年の麻酔データ ————— […]
Sparkling Water: Spark+H2O #5
前回のH2O DeepLearningモデル構築で最終的にDeepLearning_model.javaが出力される。
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 |
/* Licensed under the Apache License, Version 2.0 http://www.apache.org/licenses/LICENSE-2.0.html AUTOGENERATED BY H2O at 2018-10-28T16:28:21.908+09:00 3.10.5.4 Standalone prediction code with sample test data for DeepLearningModel named DeepLearning_model_1540691693623_1 How to download, compile and execute: mkdir tmpdir cd tmpdir curl http:/macbook-pro-5/***.***.***.***:54321/3/h2o-genmodel.jar > h2o-genmodel.jar curl http:/macbook-pro-5/***.***.***.***:54321/3/Models.java/DeepLearning_model_1540691693623_1 > DeepLearning_model_1540691693623_1.java javac -cp h2o-genmodel.jar -J-Xmx2g -J-XX:MaxPermSize=128m DeepLearning_model_1540691693623_1.java (Note: Try java argument -XX:+PrintCompilation to show runtime JIT compiler behavior.) */ import java.util.Map; import hex.genmodel.GenModel; import hex.genmodel.annotations.ModelPojo; @ModelPojo(name="DeepLearning_model_1540691693623_1", algorithm="deeplearning") public class DeepLearning_model_1540691693623_1 extends GenModel { public hex.ModelCategory getModelCategory() { return hex.ModelCategory.Binomial; } public boolean isSupervised() { return true; } public int nfeatures() { return 28; } public int nclasses() { return 2; } // Thread-local storage for input neuron activation values. final double[] NUMS = new double[28]; static class NORMMUL implements java.io.Serializable { public static final double[] VALUES = new double[28]; static { NORMMUL_0.fill(VALUES); } static final class NORMMUL_0 implements java.io.Serializable { static final void fill(double[] sa) { sa[0] = 1.7687666758901264; sa[1] = 0.9913821723096016; sa[2] = 0.9936853236221495; sa[3] = 1.6666383037503143; sa[4] = 0.9937488864153216; sa[5] = 2.105437242840467; sa[6] = 0.9908361123051243; sa[7] = 0.9940879578054577; sa[8] = 0.9729178470795813; sa[9] = 2.0007082148981183; sa[10] = 0.9908480722586916; sa[11] = 0.9938660006765665; sa[12] = 0.9528949618561464; sa[13] = 2.0508575278770245; sa[14] = 0.9912345684749029; sa[15] = 0.9937069184546701; sa[16] = 0.8377686617849256; sa[17] = 1.9768892962453906; sa[18] = 0.9926596305568416; sa[19] = 0.9937642381155177; sa[20] = 0.7141691868612743; sa[21] = 1.4816770107928496; sa[22] = 2.62612559064267; sa[23] = 6.074042423656259; sa[24] = 2.5162755660661866; sa[25] = 1.9042873091548915; sa[26] = 2.7391280258211443; sa[27] = 3.1929106654741926; } } } static class NORMSUB implements java.io.Serializable { public static final double[] VALUES = new double[28]; static { NORMSUB_0.fill(VALUES); } static final class NORMSUB_0 implements java.io.Serializable { static final void fill(double[] sa) { sa[0] = 0.991609543911382; sa[1] = -6.172673222856738E-5; sa[2] = 2.1854967778855427E-4; sa[3] = 0.9984508227147362; sa[4] = 2.7703720484945748E-5; sa[5] = 0.9908871828929133; sa[6] = -8.849292707005366E-5; sa[7] = -1.54437948956086E-4; sa[8] = 0.9999179533939873; sa[9] = 0.9927406409576117; sa[10] = -1.6275628806378383E-4; sa[11] = 7.234230467006848E-5; sa[12] = 1.0002384149332444; sa[13] = 0.992170569563542; sa[14] = 4.1840079250049434E-5; sa[15] = 3.615676062458686E-5; sa[16] = 0.999843197801924; sa[17] = 0.9861267051297294; sa[18] = 3.768967267508312E-5; sa[19] = 1.6822728241595495E-4; sa[20] = 1.0001443952117024; sa[21] = 1.0343311905419041; sa[22] = 1.0247880896606023; sa[23] = 1.0505599836914452; sa[24] = 1.0096686212679917; sa[25] = 0.9729231063653536; sa[26] = 1.0329730880581618; sa[27] = 0.9597638460111044; } } } // Workspace for categorical offsets. public static final int[] CATOFFSETS = {0}; // Hidden layer dropout ratios. public static final double[] HIDDEN_DROPOUT_RATIOS = {0.5,0.5,0.5}; // Number of neurons for each layer. public static final int[] NEURONS = {28,500,500,500,2}; // Thread-local storage for neuron activation values. final double[][] ACTIVATION = new double[][] { /* Input */ DeepLearning_model_1540691693623_1_Activation_0.VALUES, /* RectifierDropout */ DeepLearning_model_1540691693623_1_Activation_1.VALUES, /* RectifierDropout */ DeepLearning_model_1540691693623_1_Activation_2.VALUES, /* RectifierDropout */ DeepLearning_model_1540691693623_1_Activation_3.VALUES, /* Softmax */ DeepLearning_model_1540691693623_1_Activation_4.VALUES }; // Neuron bias values. public static final double[][] BIAS = new double[][] { /* Input */ DeepLearning_model_1540691693623_1_Bias_0.VALUES, /* RectifierDropout */ DeepLearning_model_1540691693623_1_Bias_1.VALUES, /* RectifierDropout */ DeepLearning_model_1540691693623_1_Bias_2.VALUES, /* RectifierDropout */ DeepLearning_model_1540691693623_1_Bias_3.VALUES, /* Softmax */ DeepLearning_model_1540691693623_1_Bias_4.VALUES }; // Connecting weights between neurons. public static final float[][] WEIGHT = new float[][] { /* Input */ DeepLearning_model_1540691693623_1_Weight_0.VALUES, /* RectifierDropout */ DeepLearning_model_1540691693623_1_Weight_1.VALUES, /* RectifierDropout */ DeepLearning_model_1540691693623_1_Weight_2.VALUES, /* RectifierDropout */ DeepLearning_model_1540691693623_1_Weight_3.VALUES, /* Softmax */ DeepLearning_model_1540691693623_1_Weight_4.VALUES }; // Names of columns used by model. public static final String[] NAMES = NamesHolder_DeepLearning_model_1540691693623_1.VALUES; // Number of output classes included in training data response column. public static final int NCLASSES = 2; // Column domains. The last array contains domain of response column. public static final String[][] DOMAINS = new String[][] { /* features0 */ null, /* features1 */ null, /* features2 */ null, /* features3 */ null, /* features4 */ null, /* features5 */ null, /* features6 */ null, /* features7 */ null, /* features8 */ null, /* features9 */ null, /* features10 */ null, /* features11 */ null, /* features12 */ null, /* features13 */ null, /* features14 */ null, /* features15 */ null, /* features16 */ null, /* features17 */ null, /* features18 */ null, /* features19 */ null, /* features20 */ null, /* features21 */ null, /* features22 */ null, /* features23 */ null, /* features24 */ null, /* features25 */ null, /* features26 */ null, /* features27 */ null, /* label */ DeepLearning_model_1540691693623_1_ColInfo_28.VALUES }; // Prior class distribution public static final double[] PRIOR_CLASS_DISTRIB = {0.4701428794437793,0.5298571205562207}; // Class distribution used for model building public static final double[] MODEL_CLASS_DISTRIB = null; public DeepLearning_model_1540691693623_1() { super(NAMES,DOMAINS); } public String getUUID() { return Long.toString(-5314795359721044940L); } // Pass in data in a double[], pre-aligned to the Model's requirements. // Jam predictions into the preds[] array; preds[0] is reserved for the // main prediction (class for classifiers or value for regression), // and remaining columns hold a probability distribution for classifiers. public final double[] score0( double[] data, double[] preds ) { java.util.Arrays.fill(preds,0); java.util.Arrays.fill(NUMS,0); int i = 0, ncats = 0; final int n = data.length; for(; i<n; ++i) { NUMS[i] = Double.isNaN(data[i]) ? 0 : (data[i] - NORMSUB.VALUES[i])*NORMMUL.VALUES[i]; } java.util.Arrays.fill(ACTIVATION[0],0); for (i=0; i<NUMS.length; ++i) { ACTIVATION[0][CATOFFSETS[CATOFFSETS.length-1] + i] = Double.isNaN(NUMS[i]) ? 0 : NUMS[i]; } for (i=1; i<ACTIVATION.length; ++i) { java.util.Arrays.fill(ACTIVATION[i],0); int cols = ACTIVATION[i-1].length; int rows = ACTIVATION[i].length; int extra=cols-cols%8; int multiple = (cols/8)*8-1; int idx = 0; float[] a = WEIGHT[i]; double[] x = ACTIVATION[i-1]; double[] y = BIAS[i]; double[] res = ACTIVATION[i]; for (int row=0; row<rows; ++row) { double psum0 = 0, psum1 = 0, psum2 = 0, psum3 = 0, psum4 = 0, psum5 = 0, psum6 = 0, psum7 = 0; for (int col = 0; col < multiple; col += 8) { int off = idx + col; psum0 += a[off ] * x[col ]; psum1 += a[off + 1] * x[col + 1]; psum2 += a[off + 2] * x[col + 2]; psum3 += a[off + 3] * x[col + 3]; psum4 += a[off + 4] * x[col + 4]; psum5 += a[off + 5] * x[col + 5]; psum6 += a[off + 6] * x[col + 6]; psum7 += a[off + 7] * x[col + 7]; } res[row] += psum0 + psum1 + psum2 + psum3; res[row] += psum4 + psum5 + psum6 + psum7; for (int col = extra; col < cols; col++) res[row] += a[idx + col] * x[col]; res[row] += y[row]; idx += cols; } if (i<ACTIVATION.length-1) { for (int r=0; r<ACTIVATION[i].length; ++r) { ACTIVATION[i][r] = Math.max(0, ACTIVATION[i][r]); if (i<ACTIVATION.length-1) { ACTIVATION[i][r] *= 1 - HIDDEN_DROPOUT_RATIOS[i-1]; } } } if (i == ACTIVATION.length-1) { double max = ACTIVATION[i][0]; for (int r=1; r<ACTIVATION[i].length; r++) { if (ACTIVATION[i][r]>max) max = ACTIVATION[i][r]; } double scale = 0; for (int r=0; r<ACTIVATION[i].length; r++) { ACTIVATION[i][r] = Math.exp(ACTIVATION[i][r] - max); scale += ACTIVATION[i][r]; } for (int r=0; r<ACTIVATION[i].length; r++) { if (Double.isNaN(ACTIVATION[i][r])) throw new RuntimeException("Numerical instability, predicted NaN."); ACTIVATION[i][r] /= scale; preds[r+1] = ACTIVATION[i][r]; } } } preds[0] = hex.genmodel.GenModel.getPrediction(preds, PRIOR_CLASS_DISTRIB, data, 0.44319463906785384); return preds; } } // Neuron activation values for Input layer class DeepLearning_model_1540691693623_1_Activation_0 implements java.io.Serializable { public static final double[] VALUES = new double[28]; static { DeepLearning_model_1540691693623_1_Activation_0_0.fill(VALUES); } static final class DeepLearning_model_1540691693623_1_Activation_0_0 implements java.io.Serializable { static final void fill(double[] sa) { sa[0] = 0.0; sa[1] = 0.0; sa[2] = 0.0; sa[3] = 0.0; sa[4] = 0.0; sa[5] = 0.0; sa[6] = 0.0; sa[7] = 0.0; sa[8] = 0.0; sa[9] = 0.0; sa[10] = 0.0; sa[11] = 0.0; sa[12] = 0.0; sa[13] = 0.0; sa[14] = 0.0; sa[15] = 0.0; sa[16] = 0.0; sa[17] = 0.0; sa[18] = 0.0; sa[19] = 0.0; sa[20] = 0.0; sa[21] = 0.0; sa[22] = 0.0; sa[23] = 0.0; sa[24] = 0.0; sa[25] = 0.0; sa[26] = 0.0; sa[27] = 0.0; } } } // Neuron activation values for RectifierDropout layer class DeepLearning_model_1540691693623_1_Activation_1 implements java.io.Serializable { public static final double[] VALUES = new double[500]; static { DeepLearning_model_1540691693623_1_Activation_1_0.fill(VALUES); } static final class DeepLearning_model_1540691693623_1_Activation_1_0 implements java.io.Serializable { static final void fill(double[] sa) { sa[0] = 0.0; sa[1] = 0.0; sa[2] = 0.0; sa[3] = 0.0; sa[4] = 0.0; sa[5] = 0.0; ...... sa[499] = 0.0; } } } // Neuron activation values for RectifierDropout layer class DeepLearning_model_1540691693623_1_Activation_2 implements java.io.Serializable { public static final double[] VALUES = new double[500]; static { DeepLearning_model_1540691693623_1_Activation_2_0.fill(VALUES); } static final class DeepLearning_model_1540691693623_1_Activation_2_0 implements java.io.Serializable { static final void fill(double[] sa) { sa[0] = 0.0; sa[1] = 0.0; sa[2] = 0.0; sa[3] = 0.0; sa[4] = 0.0; sa[5] = 0.0; ...... sa[499] = 0.0; } } } // Neuron activation values for RectifierDropout layer class DeepLearning_model_1540691693623_1_Activation_3 implements java.io.Serializable { public static final double[] VALUES = new double[500]; static { DeepLearning_model_1540691693623_1_Activation_3_0.fill(VALUES); } static final class DeepLearning_model_1540691693623_1_Activation_3_0 implements java.io.Serializable { static final void fill(double[] sa) { sa[0] = 0.0; sa[1] = 0.0; sa[2] = 0.0; sa[3] = 0.0; sa[4] = 0.0; sa[5] = 0.0; ...... sa[499] = 0.0; } } } // Neuron activation values for Softmax layer class DeepLearning_model_1540691693623_1_Activation_4 implements java.io.Serializable { public static final double[] VALUES = new double[2]; static { DeepLearning_model_1540691693623_1_Activation_4_0.fill(VALUES); } static final class DeepLearning_model_1540691693623_1_Activation_4_0 implements java.io.Serializable { static final void fill(double[] sa) { sa[0] = 0.0; sa[1] = 0.0; } } } // Neuron bias values for Input layer class DeepLearning_model_1540691693623_1_Bias_0 implements java.io.Serializable { public static final double[] VALUES = null; } // Neuron bias values for RectifierDropout layer class DeepLearning_model_1540691693623_1_Bias_1 implements java.io.Serializable { public static final double[] VALUES = new double[500]; static { DeepLearning_model_1540691693623_1_Bias_1_0.fill(VALUES); } static final class DeepLearning_model_1540691693623_1_Bias_1_0 implements java.io.Serializable { static final void fill(double[] sa) { sa[0] = -0.6082208509410506; sa[1] = -0.7866761395746675; sa[2] = -0.7902771837144533; sa[3] = -1.078600190576397; sa[4] = -1.1325559100264349; sa[5] = -1.3141680956557276; ...... sa[499] = -1.1605339237438876; } } } // Neuron bias values for RectifierDropout layer class DeepLearning_model_1540691693623_1_Bias_2 implements java.io.Serializable { public static final double[] VALUES = new double[500]; static { DeepLearning_model_1540691693623_1_Bias_2_0.fill(VALUES); } static final class DeepLearning_model_1540691693623_1_Bias_2_0 implements java.io.Serializable { static final void fill(double[] sa) { sa[0] = 0.02034537567535967; sa[1] = 0.2056398687484795; sa[2] = -0.6811208002656562; sa[3] = 0.34906780212313926; sa[4] = 0.1994718812435918; sa[5] = -0.4389162411792007; ...... sa[499] = -0.19825444966679512; } } } // Neuron bias values for RectifierDropout layer class DeepLearning_model_1540691693623_1_Bias_3 implements java.io.Serializable { public static final double[] VALUES = new double[500]; static { DeepLearning_model_1540691693623_1_Bias_3_0.fill(VALUES); } static final class DeepLearning_model_1540691693623_1_Bias_3_0 implements java.io.Serializable { static final void fill(double[] sa) { sa[0] = -0.37334331766490575; sa[1] = -0.2192842820590019; sa[2] = -0.48037506449229245; sa[3] = -0.27829081354485186; sa[4] = -0.5348837641304954; ........ sa[499] = -0.38094144337852304; } } } // Neuron bias values for Softmax layer class DeepLearning_model_1540691693623_1_Bias_4 implements java.io.Serializable { public static final double[] VALUES = new double[2]; static { DeepLearning_model_1540691693623_1_Bias_4_0.fill(VALUES); } static final class DeepLearning_model_1540691693623_1_Bias_4_0 implements java.io.Serializable { static final void fill(double[] sa) { sa[0] = -0.11833918432774448; sa[1] = 0.08029026554573974; } } } class DeepLearning_model_1540691693623_1_Weight_0 implements java.io.Serializable { public static final float[] VALUES = null; } // Neuron weights connecting Input and RectifierDropout layer class DeepLearning_model_1540691693623_1_Weight_1 implements java.io.Serializable { public static final float[] VALUES = new float[14000]; static { DeepLearning_model_1540691693623_1_Weight_1_0.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_1_1.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_1_2.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_1_3.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_1_4.fill(VALUES); } static final class DeepLearning_model_1540691693623_1_Weight_1_0 implements java.io.Serializable { static final void fill(float[] sa) { sa[0] = -0.06823527f; sa[1] = 0.01967861f; sa[2] = -0.03716086f; sa[3] = -0.011376046f; sa[4] = -0.019753613f; sa[5] = -0.19310619f; ...... sa[13999] = -0.12823965f; } } } // Neuron weights connecting RectifierDropout and RectifierDropout layer class DeepLearning_model_1540691693623_1_Weight_2 implements java.io.Serializable { public static final float[] VALUES = new float[250000]; static { DeepLearning_model_1540691693623_1_Weight_2_0.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_1.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_2.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_3.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_4.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_5.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_6.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_7.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_8.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_9.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_10.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_11.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_12.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_13.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_14.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_15.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_16.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_17.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_18.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_19.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_20.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_21.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_22.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_23.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_24.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_25.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_26.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_27.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_28.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_29.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_30.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_31.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_32.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_33.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_34.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_35.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_36.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_37.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_38.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_39.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_40.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_41.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_42.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_43.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_44.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_45.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_46.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_47.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_48.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_49.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_50.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_51.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_52.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_53.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_54.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_55.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_56.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_57.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_58.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_59.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_60.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_61.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_62.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_63.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_64.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_65.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_66.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_67.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_68.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_69.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_70.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_71.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_72.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_73.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_74.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_75.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_76.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_77.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_78.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_79.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_80.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_81.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_82.fill(VALUES); DeepLearning_model_1540691693623_1_Weight_2_83.fill(VALUES); } static final class DeepLearning_model_1540691693623_1_Weight_2_0 implements java.io.Serializable { static final void fill(float[] sa) { sa[0] = -0.24805546f; sa[1] = -0.06499913f; sa[2] = -0.14989536f; sa[3] = -0.06383444f; sa[4] = 0.14076568f; sa[5] = -0.16730806f; ...... sa[249999] = 0.005610808f; } } } // Neuron weights connecting RectifierDropout and Softmax layer class DeepLearning_model_1540691693623_1_Weight_4 implements java.io.Serializable { public static final float[] VALUES = new float[1000]; static { DeepLearning_model_1540691693623_1_Weight_4_0.fill(VALUES); } static final class DeepLearning_model_1540691693623_1_Weight_4_0 implements java.io.Serializable { static final void fill(float[] sa) { sa[0] = 0.2789825f; sa[1] = 0.4297707f; sa[2] = -0.28039044f; sa[3] = -0.13956442f; sa[4] = -0.07300115f; sa[5] = 0.13860723f; ........ sa[999] = 0.043791886f; } } } // The class representing training column names class NamesHolder_DeepLearning_model_1540691693623_1 implements java.io.Serializable { public static final String[] VALUES = new String[28]; static { NamesHolder_DeepLearning_model_1540691693623_1_0.fill(VALUES); } static final class NamesHolder_DeepLearning_model_1540691693623_1_0 implements java.io.Serializable { static final void fill(String[] sa) { sa[0] = "features0"; sa[1] = "features1"; sa[2] = "features2"; sa[3] = "features3"; sa[4] = "features4"; sa[5] = "features5"; sa[6] = "features6"; sa[7] = "features7"; sa[8] = "features8"; sa[9] = "features9"; sa[10] = "features10"; sa[11] = "features11"; sa[12] = "features12"; sa[13] = "features13"; sa[14] = "features14"; sa[15] = "features15"; sa[16] = "features16"; sa[17] = "features17"; sa[18] = "features18"; sa[19] = "features19"; sa[20] = "features20"; sa[21] = "features21"; sa[22] = "features22"; sa[23] = "features23"; sa[24] = "features24"; sa[25] = "features25"; sa[26] = "features26"; sa[27] = "features27"; } } } // The class representing column label class DeepLearning_model_1540691693623_1_ColInfo_28 implements java.io.Serializable { public static final String[] VALUES = new String[2]; static { DeepLearning_model_1540691693623_1_ColInfo_28_0.fill(VALUES); } static final class DeepLearning_model_1540691693623_1_ColInfo_28_0 implements java.io.Serializable { static final void fill(String[] sa) { sa[0] = "0"; sa[1] = "1"; } } } |
Sparkling Water: Spark+H2O #4
Mastering Machine Learning with Spark 2.xを学習する(続編)。Giggs粒子の判定モデル構築へ ???????????????????? H2O Deep Learning モデル […]
Sparkling Water: Spark+H2O #3
Published on 2018年10月23 Mastering Machine Learning with Spark 2.xを学習する(続編)。Giggs粒子の判定モデル構築へ ——R […]
Sparkling Water: Spark+H2O #2
Mastering Machine Learning with Spark 2.xを学習する(続編)。Spark 2.3.1では、H2Oの導入で不具合発生! Spark-2.1.1-bin-hadoop2.7に落として、 […]
Sparkling Water: Spark+H2O #1
Mastering Machine Learning with Spark 2.xを学習する。 ————————— […]