0

Basically the question is to apply some gpu intensive tasks like machine learning algorithms etc using smart contracts, is this possible using any of the available ethereum clients like geth or parity which may use any of the GPU-accelerated library like cuDNN by nvidia for a parallelly processed gpu powered workflow?

1

Let's clarify some concepts first.

1) Ethereum is not a powerful execution environment. In fact it's a very inefficient one and it's not meant for any real computations. This applies directly to also smart contracts.

2) Ethereum is not meant for any sort of mass computing, be it however trivial. Computations are expensive (gas costs). Ethereum is much better suited for small and light weight logic contracts between multiple parties.

3) Blockchains are deterministic. They can only use information which has been input into them through a transaction.

So, no, you can't use Ethereum for gpu intensive tasks. So all code processing done by clients is always very light. Speeding it up with a faster computer or better resources would not help you much as you would still need to be able to solve the mining puzzle before submitting the actual computation results to the blockchain. Solving the mining puzzle is a lot more effort than running the actual transaction computations.

When you mention "GPUs" you are probably thinking of mining. Mining is typically performed with GPUs for performance reasons. But, as I tried to point out, mining efficiency is not directly related to the transaction computations. If you want to boost your mining capabilities you can use GPUs to do that and that's reasonable.

Furthermore you can't use external libraries with Ethereum clients because the type of work clients can do is very limited.

| improve this answer | |
  • what about processing in parallel without gpus ? – asing177 Nov 14 '19 at 10:44
  • There is no parallelism in Ethereum. So, no – Lauri Peltonen Nov 14 '19 at 10:50
  • is extension possible in ethereum to use external libraries ? – asing177 Nov 14 '19 at 11:05
  • you can't use external libraries in your client. Smart contract libraries are then completely different topic. – Lauri Peltonen Nov 14 '19 at 11:17
  • so basically we can use inside smart contracts but not clients? – asing177 Nov 14 '19 at 11:27

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.