提交 ac48aa42 authored 作者: Olivier Delalleau's avatar Olivier Delalleau

Fixed some typos

上级 3fc6e2d1
...@@ -198,15 +198,15 @@ def use(device, ...@@ -198,15 +198,15 @@ def use(device,
function is called. We need to be able to load this module only function is called. We need to be able to load this module only
to check if it is available! to check if it is available!
:param device: string "cpu", "gpu", "gpuN" N is the device number to use :param device: string "cpu", "gpu", "gpuN" (N is the device number to use)
:param force: Will always raise an exception if we can't use the gpu. :param force: Will always raise an exception if we can't use the gpu.
:param default_to_move_computation_to_gpu: If gpu init succeeded, enable by :param default_to_move_computation_to_gpu: If gpu init succeeded, enable by
default optimization to move default optimizations to move
computation to the gpu computations to the gpu
:param move_shared_float32_to_gpu: If gpu init succeeded, put new shared :param move_shared_float32_to_gpu: If gpu init succeeded, put new shared
variable in float32 on the gpu. variables in float32 on the gpu.
:param enable_cuda: If the gpu is correctly enabled, :param enable_cuda: If the gpu is correctly enabled,
set the the variable cuda_enabled to True. set the variable cuda_enabled to True.
""" """
global cuda_enabled, cuda_initialization_error_message global cuda_enabled, cuda_initialization_error_message
if force and not cuda_available and device.startswith('gpu'): if force and not cuda_available and device.startswith('gpu'):
......
...@@ -28,8 +28,8 @@ def test_nvidia_driver1(): ...@@ -28,8 +28,8 @@ def test_nvidia_driver1():
assert len(topo) == 2 assert len(topo) == 2
assert sum(isinstance(node.op, B.GpuSum) for node in topo) == 1 assert sum(isinstance(node.op, B.GpuSum) for node in topo) == 1
if not numpy.allclose(f(), a.sum()): if not numpy.allclose(f(), a.sum()):
raise Exception("The nvidia driver version installed with the OS " raise Exception("The nvidia driver version installed with this OS "
"don't give good result for reduction." "does not give good results for reduction."
"Installing the nvidia driver available on the same " "Installing the nvidia driver available on the same "
"download page as the cuda package will fix the " "download page as the cuda package will fix the "
"problem: http://developer.nvidia.com/cuda-downloads") "problem: http://developer.nvidia.com/cuda-downloads")
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论