This is the code used to create results for paper Cost-Efficient Hierarchical Knowledge Extraction with Deep Reinforcement Learning (https://arxiv.org/abs/1911.08756).
Directory structured as follows:
code: contains the code and datasets
In the code folder, there are three algorithms rl (the main agent), rw (random sampling), and mil (the hmil agent with all information) in their corresponding directories. The
data folder contains preprocessed datasets.
In each directory, the main.py is the main script.
python main.py [dataset] [target lambda]
python main.py carc 0.001
python main.py [dataset] [target budget]
python main.py carc 5.0
python main.py [dataset]
python main.py carc
With a trained rl model, you can create a json for visualization in the
python eval_vis.py [dataset] -model [model file]
The code requires numpy, pytorch and sklearn libraries.