Code Monkey home page Code Monkey logo

cfootprint_bitcoin's Introduction

The Carbon Footprint of Bitcoin

Christian Stoll, Lena Klaaßen, Ulrich Gallersdörfer

This project provides additional information (source code, database scheme) for the article The Carbon Footprint of Bitcoin by Christian Stoll, Lena Klaaßen, and Ulrich Gallersdörfer. This project consists out of two applications:

  • SlushPool data generation (can be found in /SlushPool)
  • BlockCypher data generation (can be found in /BlockCypher)

SlushPool

This tool crawls the hash rate per location and hash rate distribution data from Slushpool and saves it into a local folder as .csv files. The UML-model can be viewed here.

Prerequisites

  • Java 8 JDK
  • JavaFX (Oracle JDK has JavaFX included)
  • Google GSON

Installation

  • Install the Google GSON library from here
cd /cfootprint_bitcoin/SlushPool/
wget -O gson-2.8.5.jar https://search.maven.org/remotecontent?filepath=com/google/code/gson/gson/2.8.5/gson-2.8.5.jar
  • Compile files
javac -cp gson-2.8.5.jar src/model/distribution/*.java src/model/location/*.java src/controller/*.java

Execution

cd src/
java -cp ../gson-2.8.5.jar:. controller.App

BlockCypher

This tool crawls blockdata from BlockCypher and stores it into a MySQL-database. It later queries IPInfo for location information about the miners.

Prerequisites

  • PHP 7
  • any MySQL version

Installation

  • import scheme.sql into your database
  • adapt settings in config.php

Execution

  • use CLI (e.g. php) to execute
    • php getBlocks.php to generate block data
    • php getLocation.php to generate location data

cfootprint_bitcoin's People

Contributors

uligall avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.