How to model machine learning problem for cache replacement policy?


I am trying to implement machine learning on Cache Replacement Policy. I want to train a ML model on labelled data acquire from Belady's Optimal Algorithm for Cache replacement policy.

For example, If X = [a,b,c,d,a,d,h,f,t,u,b,d,,t,u,i,k,h,w,r,t,b,v,c,d,,h,j,j,u,u,d,s,e,w,g,v,b,u,i,k,m,h,b] is sequential block request and my cache frame size is 3, then at given time my cache would have 3 blocks saved. Belady algorithm suggest which block from cache to remove for accomodating new block from the sequence.

So my labeled data would be current cache situation and label would be block which I want to remove for next new block.

For example,

| Cache   | Evict |
| [a,b,c] | c     |
| [e,g,v] | g     |
| [a,g,d] | a     |
| [w,t,p] | p     |
| [a,g,h] | h     |
| [q,f,v] | q     |
| [z,d,t] | z     |
| [t,g,m] | m     |
| [a,l,k] | l     |
| [p,d,q] | d     |

I want to train such data to predict the evict block given the cache configuration. (order of block in cache does not matter).

Please provide any material/resources that provide this type of ML models. I suspect it is a kind of scheduling or addignment problem but I could not find a good material that I can replicate.

Thank you in advance.

Jay Patel

Posted 2018-11-10T20:24:14.347

Reputation: 11

That's a very nice application! Maybe you wanna try LSTM/RNN with/without attention for this – Aditya – 2018-11-10T21:43:01.930

No answers