2015-12-02 23 views
8

Tôi tương đối mới để theano và tôi muốn chạy ví dụ mnist trên GPU của tôi, nhưng tôi nhận được kết quả như sau:Theano CUDA ngoại lệ

Using gpu device 0: GeForce GTX 970M (CNMeM is disabled) 
Loading data... 
Building model and compiling functions... 
WARNING (theano.gof.compilelock): 
    Overriding existing lock by dead process '9700' (I am process '10632') 

DEBUG: nvcc STDOUT mod.cu 
Creating library 
    C:/Users/user/AppData/Local/Theano 
    /compiledir_Windows-8-6.2.9200-Intel64_Family_6_Model_71_Stepping_1_GenuineIntel-3.4.3-64 
    /tmp55nlvvvo/m25b839e7715203be227800f03e7c8fe8.lib 
and object 
    C:/Users/user/AppData/Local/Theano 
    /compiledir_Windows-8-6.2.9200-Intel64_Family_6_Model_71_Stepping_1_GenuineIntel-3.4.3-64 
    /tmp55nlvvvo/m25b839e7715203be227800f03e7c8fe8.exp 

Nó giữ xuất ra thông điệp DEBUG không có đầu ra của mnist. Tôi có một phiên bản làm việc của nvcc:

C:\Users\user>nvcc --version 
nvcc: NVIDIA (R) Cuda compiler driver 
Copyright (c) 2005-2015 NVIDIA Corporation 
Built on Tue_Aug_11_14:49:10_CDT_2015 
Cuda compilation tools, release 7.5, V7.5.17 

.theanorc tập tin của tôi:

[global] 
floatX = float32 
device = gpu0 

[nvcc] 
fastmath = True 

Làm thế nào tôi có thể giải quyết này?

+0

Tôi cũng gặp sự cố này, mặc dù không phải với chương trình mẫu đó. Anaconda python 3.4, GeForce GTX970, Windows 10, theano 0.8rc1. Tìm kiếm một giải pháp ... – cb4

Trả lời

1

Tôi gặp sự cố tương tự. Tìm kiếm google và lấy mã. https://github.com/Theano/Theano/blob/master/theano/sandbox/cuda/nvcc_compiler.py

 p = subprocess.Popen(
       cmd, stdout=subprocess.PIPE, stderr=subprocess.PIPE) 
     nvcc_stdout_raw, nvcc_stderr_raw = p.communicate()[:2] 
     console_encoding = getpreferredencoding() 
     nvcc_stdout = decode_with(nvcc_stdout_raw, console_encoding) 
     nvcc_stderr = decode_with(nvcc_stderr_raw, console_encoding) 

    if nvcc_stdout: 
     # this doesn't happen to my knowledge 
     print("DEBUG: nvcc STDOUT", nvcc_stdout, file=sys.stderr) 

Dường như không có đầu ra lỗi.

Nhưng trong dịp tôi, sản lượng của nó trông giống như

DEBUG: nvcc STDOUT mod.cu

DEBUG: nvcc STDOUT mod.cu

Đôi khi làm việc tốt chương trình sau này , đôi khi không hoạt động. Nó thật lạ. Xin lỗi tôi không thể bình luận, vì vậy tôi chỉ đăng câu trả lời.

+0

Tôi chỉ thấy rằng nếu tôi vô hiệu hóa đồ họa tích hợp, mọi thứ diễn ra tốt đẹp. Nếu bạn có hai đồ họa, bạn có thể thử điều này. –