Skip to content

Commit 04aa01f

Browse files
author
knabberknusperhaus
committed
Added batchprocessing to stdout
1 parent c347781 commit 04aa01f

File tree

2 files changed

+153
-118
lines changed

2 files changed

+153
-118
lines changed

cpyrit/cpyrit.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020

2121

2222
import _cpyrit
23-
import threading, time, hashlib, os
23+
import threading, time, hashlib, os, sys
2424

2525
class CUDACore(object):
2626
name = "Nvidia CUDA"
@@ -94,7 +94,6 @@ def __init__(self, ncpus=None):
9494
assert 'calc_pmk' in avail
9595
assert 'calc_pmklist' in avail
9696

97-
9897
# Each core is tested only the first time the CPyrit-class is instantiated for performance reasons
9998
if len(CPyrit.cores) == 0:
10099
md = hashlib.md5()
@@ -108,7 +107,7 @@ def __init__(self, ncpus=None):
108107
md = hashlib.md5()
109108
md.update(_cpyrit.calc_cuda('foo', ['bar'])[0][1])
110109
if md.hexdigest() != 'a99415725d7003510eb37382126338f3':
111-
print "WARNING: CPyrit's Nvidia-CUDA GPU-core is apparently broken and will be unavailable."
110+
print >>sys.stderr, "WARNING: CPyrit's Nvidia-CUDA GPU-core is apparently broken and will be unavailable."
112111
else:
113112
CPyrit.cores[CUDACore.name] = CUDACore
114113
self.core = CUDACore

0 commit comments

Comments
 (0)