Bitcoin Forum
April 18, 2024, 06:55:43 PM *
News: Latest Bitcoin Core release: 26.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: « 1 2 [3] 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 ... 56 »
  Print  
Author Topic: python OpenCL bitcoin miner  (Read 1238793 times)
m0mchil (OP)
Full Member
***
Offline Offline

Activity: 171
Merit: 127


View Profile
October 08, 2010, 01:47:26 PM
 #41

Right after these lines is there something like:

ProcessBlock: ACCEPTED
sending: inv (37 bytes)

If so (and you are sure this is the block in question) it was announced to the network, but another block got included in the chain instead. Do you have other blocks after that?

BTW, if you want poclbm to crunch slower, start it with something like -f 400. Experiment with the number.

You can see the statistics of your reports to moderators on the "Report to moderator" pages.
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
1713466543
Hero Member
*
Offline Offline

Posts: 1713466543

View Profile Personal Message (Offline)

Ignore
1713466543
Reply with quote  #2

1713466543
Report to moderator
lfm
Full Member
***
Offline Offline

Activity: 196
Merit: 104



View Profile
October 09, 2010, 09:27:08 PM
 #42

of course, but still
i'd like to know if that's a usual expectation on ati cards compared to nvidia,
no single-hd5870-users around that want to share their hash-count?

i'm gonna buy a new card sooner or later anyway and i don't mind if it says ati or nvidia on it,
both will surely run my game/s.
but if one of them is x times better crunching blocks and besides that, prolly cheaper too,
i already know what my next favourite brand is.

gflops is not really relevant to bitcoin mining since gflops is measure of floating point and bitcoin mining is fixed point. It think fixed point is relatively good to ati and hard for nvidia.

If you have an app that uses floating point more than fixed point the the disparity might vanish or at least diminish.

SmokeTooMuch
Legendary
*
Offline Offline

Activity: 860
Merit: 1021


View Profile
October 10, 2010, 12:27:28 AM
Last edit: October 10, 2010, 01:36:45 AM by SmokeTooMuch
 #43

It think fixed point is relatively good to ati and hard for nvidia.
That sounds interesting. Do you have any web-sources for this ?

@m0mchil:
Is your Python OpenCL client using priorization ? like, can I start a game while using your client and it will automatically slow down the hash rate and my card will focus on the game ?

Date Registered: 2009-12-10 | I'm using GPG, pm me for my public key. | Bitcoin on Reddit: https://www.reddit.com/r/btc
m0mchil (OP)
Full Member
***
Offline Offline

Activity: 171
Merit: 127


View Profile
October 10, 2010, 05:10:12 AM
 #44

It only tries to keep single kernel run under specific time by changing the number of 'global' threads. If you start a game, kernel execution will get slower. The number of threads will then be gradually adjusted to achieve the desired execution time.

By default this time is 1/60 of a second. If shorter i.e. 1/120 sec it will leave more time for other GPU tasks.

This is adjusted with the '-f' switch.

lfm
Full Member
***
Offline Offline

Activity: 196
Merit: 104



View Profile
October 11, 2010, 06:57:03 AM
 #45

I can't get the getwork patch to compile into bitcoin. Is that something satoshi has considered adding to the main trunk?

I've got PyOpenCL finally installed but without the patch in the client, I can't request anything.

try :

  svn co -r 161 https://bitcoin.svn.sourceforge.net/svnroot/bitcoin

It seems any other revision fails the patch.
lfm
Full Member
***
Offline Offline

Activity: 196
Merit: 104



View Profile
October 11, 2010, 07:15:45 AM
 #46


ok, I'm really new at this GPGPU stuff, I got this message when I try to run the thing:


Traceback (most recent call last):
  File "poclbm.py", line 28, in <module>
    miner = cl.Program(context, kernelFile.read()).build()
  File "/usr/lib/pymodules/python2.6/pyopencl/__init__.py", line 138, in program_build
    "Build on %s:\n\n%s" % (dev, log) for dev, log in build_logs))
pyopencl.RuntimeError: clBuildProgram failed: build program failure

Build on <pyopencl.Device 'GeForce 8400 GS' at 0xf16c40>:

Error: Code selection failed to select: 0x138fdc0: i32 = bswap 0x138fbc0

-------------------
This is on Linux 64 bit, does the "i32 = bswap" mean it wants linux 32?

btw I know the 8400 GS is slow, you don't have to tell me.
m0mchil (OP)
Full Member
***
Offline Offline

Activity: 171
Merit: 127


View Profile
October 11, 2010, 07:49:15 AM
 #47


Error: Code selection failed to select: 0x138fdc0: i32 = bswap 0x138fbc0


Try to update your GPU driver. See http://forums.nvidia.com/index.php?showtopic=150585

It seems OpenCL is still problematic on Nvidia GPUs. Unfortunately I don't have one to try to make a PyCuda miner.

lfm
Full Member
***
Offline Offline

Activity: 196
Merit: 104



View Profile
October 11, 2010, 07:56:43 AM
 #48

I think I have the newest stuff. Ill just have to wait for the next version by the looks of it. Maybe give up on it and find an ATI card.
SmokeTooMuch
Legendary
*
Offline Offline

Activity: 860
Merit: 1021


View Profile
October 11, 2010, 04:55:44 PM
 #49

Quote
SPARKLE SX84GS256D2LDPP GeForce 8400 GS 256MB 64-bit DDR2 PCI Express 2.0 x16 HDCP Ready Low Profile Ready Video Card
Well .. 256mb .. DDR2 with 64 bit interface
this even was crap when it came on the market ^^

Date Registered: 2009-12-10 | I'm using GPG, pm me for my public key. | Bitcoin on Reddit: https://www.reddit.com/r/btc
SmokeTooMuch
Legendary
*
Offline Offline

Activity: 860
Merit: 1021


View Profile
October 11, 2010, 10:16:59 PM
 #50


ok, I'm really new at this GPGPU stuff, I got this message when I try to run the thing:


Traceback (most recent call last):
  File "poclbm.py", line 28, in <module>
    miner = cl.Program(context, kernelFile.read()).build()
  File "/usr/lib/pymodules/python2.6/pyopencl/__init__.py", line 138, in program_build
    "Build on %s:\n\n%s" % (dev, log) for dev, log in build_logs))
pyopencl.RuntimeError: clBuildProgram failed: build program failure

Build on <pyopencl.Device 'GeForce 8400 GS' at 0xf16c40>:

Error: Code selection failed to select: 0x138fdc0: i32 = bswap 0x138fbc0

-------------------
This is on Linux 64 bit, does the "i32 = bswap" mean it wants linux 32?

btw I know the 8400 GS is slow, you don't have to tell me.

Got the same error on a Win7-64 with 8600 GTS.
Code:
Build on <pyopencl.Device 'GeForce 8600 GTS' at 0x2ed2f48>:

Error: Code selection failed to select: 0x5d57918: i32 = bswap 0x5d57808
Seems like poclbm doesn't work on nvidia cards.

Date Registered: 2009-12-10 | I'm using GPG, pm me for my public key. | Bitcoin on Reddit: https://www.reddit.com/r/btc
jimbobway
Legendary
*
Offline Offline

Activity: 1304
Merit: 1014



View Profile
October 12, 2010, 05:29:30 AM
 #51

hey, it's me .. again ...

python poclbm.py -->

Code:
Traceback (most recent call last):
  File "poclbm.py", line 5, in <module>
    import pyopencl as cl
  File "C:\Python26\lib\site-packages\pyopencl-0.92-py2.6-win32.egg\pyopencl\__init__.py", line 3, in <module>
    import pyopencl._cl as _cl
ImportError: DLL load failed: Das angegebene Modul wurde nicht gefunden.
Seems like a DLL is missing.

Copy your boost_python-vc90-mt-1_44.dll and boost_thread-vc90-mt-1_44.dll that you compiled with boost earlier directly into your directory where you are running poclbm.py from.

I don't speak German, but that looks like what it is saying to me.


I also get this error.  I tried copying boost_python-vc90-mt-1_44.dll and boost_thread-vc90-mt-1_44.dll directly into the directory where I am running poclbm.py but it has the same error (see below).  I copied it into Windows\System32 but still same error.  Any ideas???

Code:
C:\bitcoin_miner>python poclbm.py
Traceback (most recent call last):
  File "poclbm.py", line 5, in <module>
    import pyopencl as cl
  File "C:\Python26\lib\site-packages\pyopencl-0.92-py2.6-win32.egg\pyopencl\__i
nit__.py", line 3, in <module>
    import pyopencl._cl as _cl
ImportError: DLL load failed: The specified module could not be found.
SmokeTooMuch
Legendary
*
Offline Offline

Activity: 860
Merit: 1021


View Profile
October 12, 2010, 12:25:28 PM
 #52

looks like a dll is missing

which boost version are you using ?

best is to post your siteconf.py

Date Registered: 2009-12-10 | I'm using GPG, pm me for my public key. | Bitcoin on Reddit: https://www.reddit.com/r/btc
jimbobway
Legendary
*
Offline Offline

Activity: 1304
Merit: 1014



View Profile
October 12, 2010, 07:24:20 PM
 #53

Post your boost version, siteconf, and os. Should be able to help you more from there. Make sure you grabbed the right dll's because several of them are named close.

I am using Windows Vista 64-bit.  I used boost 1.44, but there was an error so I actually downloaded the binary versions of "boost_python-vc90-mt-1_44.dll" and "boost_thread-vc90-mt-1_44.dll". I used all 32-bit installations for compatibility.  Below is siteconf.py.  I was able to run "python setup.py install" ok without errors.

Code:
BOOST_INC_DIR = ['C:\\boost_1_44_0']
BOOST_LIB_DIR = ['C:\\boost_1_44_0\\lib']
BOOST_COMPILER = 'msvc'
BOOST_PYTHON_LIBNAME = ['boost_python-vc90-mt-1_44']
USE_SHIPPED_BOOST = False
CL_TRACE = False
CL_ENABLE_GL = False
CL_INC_DIR = ['C:\\Program Files (x86)\\NVIDIA GPU Computing Toolkit\\CUDA\\v3.2\\include']
CL_LIB_DIR = ['C:\\Program Files (x86)\\NVIDIA GPU Computing Toolkit\\CUDA\\v3.2\\lib\\Win32']
CL_LIBNAME = ['OpenCL']
CXXFLAGS = ['/EHsc', '/DBOOST_PYTHON_NO_PY_SIGNATURES']
LDFLAGS = ['/FORCE']

Thanks for your help!  Smiley

jimbobway
Legendary
*
Offline Offline

Activity: 1304
Merit: 1014



View Profile
October 12, 2010, 07:40:46 PM
 #54

Awesome, so you got it working with a CUDA card?

Specs and hash rate?


Oh, not yet...sorry if it sounded like I declared victory too early.  I still get:

Code:
ImportError: DLL load failed: The specified module could not be found.

Any ideas?
jimbobway
Legendary
*
Offline Offline

Activity: 1304
Merit: 1014



View Profile
October 12, 2010, 08:05:39 PM
 #55

I went home for lunch to debug but now I am at work. I am hardcore to get this to work.  Will work in it tonite.
jimbobway
Legendary
*
Offline Offline

Activity: 1304
Merit: 1014



View Profile
October 13, 2010, 01:04:23 AM
 #56

I did not do the bootstrap methon.  I used the win installer with the precompiled binaries from here http://www.boostpro.com/download/ (that was what the boost site said to do). 

I reinstalled Python26, Numpy, SciPi, and boost 1_39.  I copied all the dlls into the same folder as poclmb.py. 

Still same error.

Hmmm...
jimbobway
Legendary
*
Offline Offline

Activity: 1304
Merit: 1014



View Profile
October 13, 2010, 01:09:45 AM
 #57

I completely misunderstood you sorry.

So you did not compile the dll's yourself for boost? So you might have a problem with your boost path.

What happens when you run the bootstrap in the boost directory?

Then here is what I used to build the boost libraries after bootstrapping:

Code:
bjam.exe toolset=msvc --with-python --with-date_time --with-thread threading=multi link=shared

That then created a directory starting from c:/boost called C:\boost\stage\lib that had the dll's in it, and is how I pointed it inside my site.conf

Then I copied those dll's over. I am wondering if the dll's you downloaded aren't the right ones or don't have all the right flags or something.


I believe I have the right flags.  In the installer I picked msvc 2008, python, date time, and thread.  There is no option for threading or link.
jimbobway
Legendary
*
Offline Offline

Activity: 1304
Merit: 1014



View Profile
October 13, 2010, 04:26:08 PM
 #58

bitcoin-getwork-svn166-win32.7z - with key pool support (see SVN)

poclbm_py2exe.7z - this is the miner, packed with py2exe. Must be able to run without installing python, PyOpenCL, boost etc. Needs only ATI Stream SDK. Windows only. See command line options with -h to change your

The miner itself has been improved slightly, doing first 3 sha256 rounds in python. http://github.com/m0mchil/poclbm/


OMG!  Thx david and momchil!  I was about to give up...gonna try it when I get home.
jimbobway
Legendary
*
Offline Offline

Activity: 1304
Merit: 1014



View Profile
October 13, 2010, 04:51:51 PM
 #59

I have an nVidia card...I hope I can install the nVidia sdk instead of the ati sdk. (Fingers crossed)
jimbobway
Legendary
*
Offline Offline

Activity: 1304
Merit: 1014



View Profile
October 13, 2010, 07:27:21 PM
 #60

bitcoin-getwork-svn166-win32.7z - with key pool support (see SVN)

poclbm_py2exe.7z - this is the miner, packed with py2exe. Must be able to run without installing python, PyOpenCL, boost etc. Needs only ATI Stream SDK. Windows only. See command line options with -h to change your

The miner itself has been improved slightly, doing first 3 sha256 rounds in python. http://github.com/m0mchil/poclbm/


OMG!  Thx david and momchil!  I was about to give up...gonna try it when I get home.


I get this error:

Code:

C:\Users\Bitcoin GPU\Desktop\poclbm_py2exe>poclbm
Traceback (most recent call last):
  File "poclbm.py", line 40, in <module>
pyopencl.LogicError: clGetPlatformIDs failed: invalid/unknown error code

[\code]
Pages: « 1 2 [3] 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 ... 56 »
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!