Implementing a machine learning algorithm in smart contract

Hello,

i want to implement a clustering algorithm (k-means for example) in a smart contract.

for the traning data (big Data Set) , i want to use IPFS(off-chain) to save my dataset.

  1. is this Idea Correct?
  2. How and with what can i start?
  3. can i use IDE remix solidity to implement all this.

thanks.

1 Like

Hi,

Welcome to the community :wave:

Not to be discouraging but I am not sure about this idea.
Why do you want to implement this algorithm in a smart contract? A clustering algorithm (as I understand it, is iterative) sounds very expensive to run on-chain.

Blockchains are (relatively) expensive, so we want to keep processing and data storage off chain wherever possible.

Remix IDE is great for simple contracts and experimenting. This is a good place to start.

For production smart contracts appropriate testing and auditing is required so suggest moving to OpenZeppelin SDK or Truffle etc and storing code and tests in version control e.g. GitHub.

1 Like

can i use oraclize to implement a clustering algorithm (k-means for example) with a smart contract.

1 Like

Responded to your question in a separate topic: