Giter VIP home page Giter VIP logo

trace's Introduction

trace

This repo contains different python implementations of cache replacement algorithms, working on a trace of strings that represents a page access order from a real system. These scripts where used to motivate which algorithm to implement in the Neo4j Kernel.

Notably the current eviction algorithm that Neo4j uses closely resembles the algorithm of clock_4_usage.py

The scripts run the algorithms single threaded and are therefore not exactly a carbon copy of what you would implement in reality

To implement your own replacement strategy you can start by copying the trace-scan.py file, where we show how to scan the page trace into a datastructure that you can then implement your strategy on.

to run all the replacement algorithms here on the default trace you can run the run.sh script. You may need to give the script executeable permissions.

chmod +x run.sh

The script will prompt you for what trace to run, cache size of the runs and if you want to run the "optimal" calculation according to the belady unrealizeable algorithm, which takes a while, scaling by nĀ² with trace size (roughly)

trace's People

Contributors

toraelding avatar lullebullelukas avatar

Watchers

 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.