microsoft / 0xdeca10b Goto Github PK
View Code? Open in Web Editor NEWSharing Updatable Models (SUM) on Blockchain
Home Page: https://aka.ms/0xDeCA10B-blog1
License: MIT License
Sharing Updatable Models (SUM) on Blockchain
Home Page: https://aka.ms/0xDeCA10B-blog1
License: MIT License
when I try to start the server from one terminal via
yarn server
the following error occured:
root@4b935555249c:~/workspace/demo# yarn server
yarn run v1.22.0
$ nodemon server.js --ignore client/
[nodemon] 2.0.2
[nodemon] to restart at any time, enter `rs`
[nodemon] watching dir(s): *.*
[nodemon] watching extensions: js,mjs,json
[nodemon] starting `node server.js`
[nodemon] Internal watch failed: ENOSPC: System limit for number of file watchers reached, watch '/root/workspace/demo/blockchain_db/!trie_db!0x98bc7528aec5dba65ab2272c2844b472118d4e17cce298ee58a3a2848d407c32'
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
Does anyone know where went wrong?
Hello, I used to run the linux virtual machine under vmware. The installation steps of your installation were unsuccessful. Now I want to implement it through WSL to see if I can do it. However, I have a few questions to ask you now: 1: What necessary configurations need to be prepared in WSL (except npm), can you provide detailed command steps? 2: Is docker installed in WSL? , You did not involve the installation of docker in the video demo. 3: I saw that your video demo used powershell to actually execute the command. I don't understand this point. How is it related to WSL? I am a beginner and appreciate your interest in this project. I hope I can run through it myself.
Looking forward to your reply,
sincerely thanks
(base) WorkSpace:~/Documents/projects/BC+AI/0xDeCA10B/d
at wrapSafe (internal/modules/cjs/loader.js:915:16)
at Module._compile (internal/modules/cjs/loader.js:963:27)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1027:10)
at Module.load (internal/modules/cjs/loader.js:863:32)
at Function.Module._load (internal/modules/cjs/loader.js:708:14)
at Module.require (internal/modules/cjs/loader.js:887:19)
at require (internal/modules/cjs/helpers.js:74:18)
at Object.webpack_require.f.require (/usr/local/lib/node_modules/truffle/build/cli.bundled.js:608:28)
at /usr/local/lib/node_modules/truffle/build/cli.bundled.js:538:40
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
The page to add models needs to be updated have it's route added back.
There are important files that Microsoft projects should all have that are not present in this repository. A pull request has been opened to add the missing file(s). When the pr is merged this issue will be closed automatically.
Microsoft teams can learn more about this effort and share feedback within the open source guidance available internally.
It should be faster.
The Factom blockchain is built for data storage, offering a fixed cost of $0.001 for 10kb of data. The Factom chain anchors to the Bitcoin and Ethereum blockchain giving it accountability.
I'm curious if this option has been explored for model storage instead of storing it in Etheruem?
Each Factom entry has a unique hash and that can be used in the smart contract to lookup the required model.
More information on Factom - https://www.factom.com
The chunk sizes are set pretty low but it's still possible that people run out of gas when deploying models.
For now, people should confirm that deployment works on a test chain before deploying elsewhere.
[demo]When I run the command "yarn client", somethings goes error which reminder me "bash: deploy_client.sh:No such file or directory and error command failed with exit code 127". Then I check the file directory by "find -name deploy_client.sh", it's a pity that there is no this file. I want to know whether there is that file?
When I visit http://localhost:5006/simulate_imdb_perceptron
, the page is blank.
Is this normal? If not, how can I fix it?
In the demo, normalization is done before updating the dense perceptron and dense nearest centroid classifiers, but the simulation doesn't use normalization.
Normalization is used to avoid submissions with large values that would corrupt the model. Using normalized vectors might be bad for these models but it seems like a necessary guard to have on-chain.
Currently an error is shown if something fails when loading the contract but it would be better to get more detailed errors for what is invalid.
Validate that:
Leaving this issue open since there's probably more to validate.
In database? On blockchain?
We now track the accuracy in the database (managed by the server). This is okay but it's centralized so it would be good to add some proof to that database.
Express >= 4.16.0, body parser has been re-added under the methods express.json() and express.urlencoded().
When a lot of data has been added, it might be annoying to find the data you want to refund/report. It would be good to have an easy way to search for the events.
Search params can be put into the customFilter
function that is passed to handleAddedData
.
Hi! I've recently started working and learning on SUM. I'm currently stuck with running the Simulation steps.
To direct you to the steps I've followed:
1 - I tried running the "docker run --rm -it -p 5006:5006 -v %cd%:/root/workspace/0xDeCA10B/simulation --name decai-simulation mcr.microsoft.com/samples/blockchain-ai/0xdeca10b-simulation bash" comman on my Git Cmd.
2 - Got my docker file up and running
3 - I then tried running "bokeh serve decai/simulation/simulate_imdb_perceptron.py"
This is where I got stuck and I get this:
I did quite some searches on google and tried some codes with regards to bokeh, and none worked.
Would be great if someone can guide me with what has happened and what needs to be done, new to this sort of tech!
Thank You
I wanted to see if a GSoC Open Source Contribution in this repository was possible. I'm hoping for a rapid response. Thank you very much.
This is just to remove data from the storage (local or service).
This wouldn't actually remove data from the blockchain.
There are plenty of toasts when adding a new model but for other pages just console logging or alerts are used. There are lots of TODOs on those pages for when toasts should be used.
When encoder === 'none'
, the text can be treated as JSON?
Just documenting some thoughts here.
It would be nice for the model storage and the model's update algorithm to be kept separate so that users updating the model can pick from different update functions.
In practice this could cause problems if any update algorithm can be used because a user can significantly change the entire model.
I'm also pretty sure that it would cost more gas to call methods from another contract.
So that the values don't have to be hidden when online safety is enabled.
See https://solidity.readthedocs.io/en/v0.6.0/060-breaking-changes.html#how-to-update-your-code
Should be pretty easy. Might need to sprinkle some virtual
s in abstract classes and override
s in the corresponding methods.
The test cases should catch any issues.
Currently models only get listed by getting added to the DB when they are deployed. There should be a way to list a model that is already deployed.
I started to do this but the image wouldn't display. I was doing stuff like:
img = document.getElementById('input-image');
canvas = document.createElement('canvas');
context = canvas.getContext('2d');
canvas.width = img.width;
canvas.height = img.height;
context.drawImage(img, 0, 0 );
img2 = document.createElement("img");
img2.src = canvas.toDataURL();
document.body.appendChild(img2);
I was trying to save canvas.toDataURL()
to the database of original data as text and then load it into an <img>
tag. It wouldn't display.
Remove the option to select the IMDB vocab and instead allow uploading a vocab locally or to the DB.
Not as important now that #88 is done which lets you hash words to a number which works well with sparse models.
Hello author. When I installed your demo, I encountered two problems, 1: I want to know under what environment do you run, window powershell or linux? 2: I am running under Linux and running to Listening on 0.0.0.0:7545 when executing to the yarn blockchain, I haven't executed any further. Attempt to execute yarn client or yarn server also fails
Add an option for a word hashing vocab for sparse models.
An analysis of hash functions: https://softwareengineering.stackexchange.com/a/145633/359613
Maybe use toast, or checkboxes in UI.
There are already TODOs in model.js.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.