This repository contains implementation of two methods purposed for inferring Boolean networks from time-series data:
-
Approximative method:
./src/approximative_method.py
-
Deterministic method:
./src/deterministic_method.py
The scripts require at least Python 3.10 and specific packages listed in requirements.txt. To facilitate ease of use and ensure compatibility, a Docker image based on Ubuntu is provided, which comes pre-installed with all the necessary requirements.
-
install Docker documentation
-
build the docker image (it will take a few minutes):
sudo docker build -t {image-name} .
-
run the docker image:
sudo docker run -it {image-name}
-
display the content of directory:
ls
We are now ready to execute one of the methods. The ./evaluate
directory contains three examples of models along with their corresponding synthetic data sets, demonstrating the usage and capabilities of these methods.
- cell_division
- mir-9-neurogeneses
- tumor_cell_invasion_and_migration
Examples of running the methods are in ./test_approximative.py
and ./test_deterministic.py
. We can run them with command:
-
Approximative method:
python3 test_deterministic.py
-
Deterministic method:
python3 test_approximative.py
Or we can run the scripts directly:
-
Approximative method:
The model directory can be easily changed in the script.
./src/approximative_method.py --input_path {input_path} --psbn_path {psbn_path} --output_path {output_path} --max_k {max_k}
-
Deterministic method:
It is recommended to apply this method primarily to the 'cell division' example, as it represents the smallest and most manageable dataset for demonstrating the efficacy of the technique.
./src/deterministic_method.py --ts_path {input_path} --psbn_path {psbn_path}
The final script, evaluate_approximative.py
, executes the approximative method 30 times and assesses its performance using the benchmarks implemented in the ./benchmarks directory
. All the results are stored in the model directory.