zoukankan      html  css  js  c++  java
  • Caffe2:python -m caffe2.python.operator_test.relu_op_test

    1. 进行语句测试时候,出现问题,

          设置环境变量CUDA_VISIBLE_DEVICES

    参考: cuda设置指定可见方法

        

    在/etc/profile文件或者~/.bashrc末尾添加以下行:

           export CUDA_VISIBLE_DEVICES=0,1 ##仅显卡设备0,1GPU可见。可用的GPU可通过nvidia-smi -L命令查看


    2. 出现     ImportError: No module named hypothesis
         pip install hypothesis

    测试成功

    /usr/lib/python2.7/dist-packages/numpy/core/numeric.py:301: FutureWarning: in the future, full(9, True) will return an array of dtype('bool')
      format(shape, fill_value, array(fill_value).dtype), FutureWarning)
    Trying example: test_relu(self=<__main__.TestRelu testMethod=test_relu>, X=array([[-0.27628136, -0.27628136, -0.27628136],
           [-0.27628136, -0.27628136, -0.27628136],
           [-0.27628136, -0.27628136, -0.89451963]], dtype=float32), gc=, dc=[], engine=u'')
    .
    ----------------------------------------------------------------------
    Ran 1 test in 0.183s

    OK


  • 相关阅读:
    访问控制与封装
    构造函数
    定义抽象数据类型
    函数基础
    参数传递
    路径中 斜杠/和反斜杠 的区别
    【git】Github上面的开源代码怎么在本地编译运行
    IDEA及IDEA汉化包
    Java设计模式——工厂设计模式
    "/"程序中的服务器错误
  • 原文地址:https://www.cnblogs.com/wishchin/p/9199867.html
Copyright © 2011-2022 走看看