================================================
Burst style MDCs
================================================

Instructions for running burst-style MDCs in which a signal is injected from a :code:`.gwf` frame file.

Making an MDC cache
---------------------

:code:`BayesWave` requires a path to the cache file of the MDC frames.
If you have specific MDC frames you want to run on, you can make a cache file via

.. code:: console

    $ lal_path2cache [directory_with_frames]/*gwf > MDC.cache


Injecting into real noise
---------------------------

In this example we will inject a white noise burst into real H1 and L1 data from O2.
Here we already have an MDC cache made on CIT.

.. todo:: 
    Put parameters of WNB here

Config file
~~~~~~~~~~~~~~~

.. literalinclude:: test_suite/MDC_injections/MDC_realNoise.ini
    :language: cfg

:download:`Download .ini file <test_suite/MDC_injections/MDC_realNoise.ini>`



Call to :code:`bayeswave_pipe`
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

.. literalinclude:: test_suite/MDC_injections/runpipe_simNoise.sh
    :language: bash

:download:`Download bash script <test_suite/MDC_injections/runpipe_simNoise.sh>`

Injecting into simulated data
--------------------------------------

In this example we will inject a white noise burst simulated H1 and L1 data.


Config file
~~~~~~~~~~~~~~~

.. literalinclude:: test_suite/MDC_injections/MDC_simNoise.ini
    :language: cfg

:download:`Download .ini file <test_suite/MDC_injections/MDC_simNoise.ini>`



Call to :code:`bayeswave_pipe`
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

.. literalinclude:: test_suite/MDC_injections/runpipe_simNoise.sh
    :language: bash

:download:`Download bash script <test_suite/MDC_injections/runpipe_simNoise.sh>`