无法启动水

Cannot start h2o

正如标题所说。我不能 运行 h20.init.

我已经下载了 Java SE Development Kit 8u291. I also downloaded the xgboost library in R (install.packages("xgboost") ). Finally, I have updated all my NVIDIA drivers and downloaded the latest CUDA (although, tbh I don't even know what that does). I followed the steps described in the NVIDIA forums to avoid the crash I had when installing (i.e. remove integration with visual studio). FWIW I'm using a DELL Inspiron 15 Gaming 的 64 位版本,它有一个 4GB 的 NVIDIA GTX 1050。

这是我使用的完整代码(直接来自 h2o download instructions 除了第一行):

library(xgboost)
library(h2o)
localH2O = h2o.init()
demo(h2o.kmeans)

如有任何帮助,我们将不胜感激。

我在 运行 上面的代码块中得到的完整消息:

H2O is not running yet, starting it now...

Note:  In case of errors look at the following log files:
    C:\Users\<my username>\AppData\Local\Temp\RtmpcdvCce\file1a106074110b/h2o_<my username>_started_from_r.out
    C:\Users\<my username>\AppData\Local\Temp\RtmpcdvCce\file1a10253139db/h2o_<my username>_started_from_r.err

java version "15.0.2" 2021-01-19
Java(TM) SE Runtime Environment (build 15.0.2+7-27)
Java HotSpot(TM) 64-Bit Server VM (build 15.0.2+7-27, mixed mode, sharing)

Starting H2O JVM and connecting: ............................................................Diagnostic HTTP Request:
   HTTP Status Code: -1
HTTP Error Message: Failed to connect to localhost port 54321: Connection refused
Cannot load library from path lib/windows_64/xgboost4j_gpu.dll
Cannot load library from path lib/xgboost4j_gpu.dll
Failed to load library from both native path and jar!
Cannot load library from path lib/windows_64/xgboost4j_omp.dll
Cannot load library from path lib/xgboost4j_omp.dll
Failed to load library from both native path and jar!
Cannot load library from path lib/windows_64/xgboost4j_minimal.dll
Cannot load library from path lib/xgboost4j_minimal.dll
Failed to load library from both native path and jar!
Failed to add native path to the classpath at runtime
java.io.IOException: Failed to get field handle to set library path
    at ai.h2o.xgboost4j.java.NativeLibLoader.addNativeDir(NativeLibLoader.java:229)
    at ai.h2o.xgboost4j.java.NativeLibLoader.initXGBoost(NativeLibLoader.java:43)
    at ai.h2o.xgboost4j.java.NativeLibLoader.getLoader(NativeLibLoader.java:66)
    at hex.tree.xgboost.XGBoostExtension.initXgboost(XGBoostExtension.java:70)
    at hex.tree.xgboost.XGBoostExtension.isEnabled(XGBoostExtension.java:51)
    at water.ExtensionManager.isEnabled(ExtensionManager.java:189)
    at water.ExtensionManager.registerCoreExtensions(ExtensionManager.java:103)
    at water.H2O.main(H2O.java:2203)
    at water.H2OStarter.start(H2OStarter.java:22)
    at water.H2OStarter.start(H2OStarter.java:48)
    at water.H2OApp.main(H2OApp.java:12)
Cannot initialize XGBoost backend! Xgboost (enabled GPUs) needs: 
  - CUDA 8.0
XGboost (minimal version) needs: 
  - GCC 4.7+
For more details, run in debug mode: `java -Dlog4j.configuration=file:///tmp/log4j.properties -jar h2o.jar`


ERROR: Unknown argument (<my username>/AppData/Local/Temp/RtmpcdvCce)


Usage:  java [-Xmx<size>] -jar h2o.jar [options]
        (Note that every option has a default and is optional.)

    -h | -help
          Print this help.

    -version
          Print version info and exit.

    -name <h2oCloudName>
          Cloud name used for discovery of other nodes.
          Nodes with the same cloud name will form an H2O cloud
          (also known as an H2O cluster).

    -flatfile <flatFileName>
          Configuration file explicitly listing H2O cloud node members.

    -ip <ipAddressOfNode>
          IP address of this node.

    -port <port>
          Port number for this node (note: port+1 is also used by default).
          (The default port is 54321.)

    -network <IPv4network1Specification>[,<IPv4network2Specification> ...]
          The IP address discovery code will bind to the first interface
          that matches one of the networks in the comma-separated list.
          Use instead of -ip when a broad range of addresses is legal.
          (Example network specification: '10.1.2.0/24' allows 256 legal
          possibilities.)

    -ice_root <fileSystemPath>
          The directory where H2O spills temporary data to disk.

    -log_dir <fileSystemPath>
          The directory where H2O writes logs to disk.
          (This usually has a good default that you need not change.)

    -log_level <TRACE,DEBUG,INFO,WARN,ERRR,FATAL>
          Write messages at this logging level, or above.  Default is INFO.

    -max_log_file_size
          Maximum size of INFO and DEBUG log files. The file is rolled over after a specified size has been reached.
          (The default is 3MB. Minimum is 1MB and maximum is 99999MB)

    -flow_dir <server side directory or HDFS directory>
          The directory where H2O stores saved flows.
          (The default is 'C:\Users\<my username>\h2oflows'.)

    -nthreads <#threads>
          Maximum number of threads in the low priority batch-work queue.
          (The default is.)

    -client
          Launch H2O node in client mode.

    -notify_local <fileSystemPath>
          Specifies a file to write when the node is up. The file contains one line with the IP and
          port of the embedded web server. e.g. 192.168.1.100:54321

    -context_path <context_path>
          The context path for jetty.

Authentication options:

    -jks <filename>
          Java keystore file

    -jks_pass <password>
          (Default is 'h2oh2o')

    -jks_alias <alias>
          (Optional, use if the keystore has multiple certificates and you want to use a specific one.)

    -hostname_as_jks_alias
          (Optional, use if you want to use the machine hostname as your certificate alias.)

    -hash_login
          Use Jetty HashLoginService

    -ldap_login
          Use Jetty Ldap login module

    -kerberos_login
          Use Jetty Kerberos login module

    -spnego_login
          Use Jetty SPNEGO login service

    -pam_login
          Use Jetty PAM login module

    -login_conf <filename>
          LoginService configuration file

    -spnego_properties <filename>
          SPNEGO login module configuration file

    -form_auth
          Enables Form-based authentication for Flow (default is Basic authentication)

    -session_timeout <minutes>
          Specifies the number of minutes that a session can remain idle before the server invalidates
          the session and requests a new login. Requires '-form_auth'. Default is no timeout

    -internal_security_conf <filename>
          Path (absolute or relative) to a file containing all internal security related configurations

Cloud formation behavior:

    New H2O nodes join together to form a cloud at startup time.
    Once a cloud is given work to perform, it locks out new members
    from joining.

Examples:

    Start an H2O node with 4GB of memory and a default cloud name:
        $ java -Xmx4g -jar h2o.jar

    Start an H2O node with 6GB of memory and a specify the cloud name:
        $ java -Xmx6g -jar h2o.jar -name MyCloud

    Start an H2O cloud with three 2GB nodes and a default cloud name:
        $ java -Xmx2g -jar h2o.jar &
        $ java -Xmx2g -jar h2o.jar &
        $ java -Xmx2g -jar h2o.jar &

所以...经过一番摸索,我找到了答案。 Windows Defender ughhh 阻止了对 h2o.jar 的访问。解决方案是在 h2o java 文件夹和 运行 h2o.jar 文件夹上打开 PowerShell 使用 java -jar h2o.jar。然后你会收到安全提示,要求你授权该程序(我每次都必须这样做,所以你可能想检查你的设置)。一旦你这样做 h2o.init() 运行 在 R 中非常顺利。