GWDALI


NameGWDALI JSON
Version 0.1.0 PyPI version JSON
download
home_page
SummaryA Fisher-Based Software for Parameter Estimation from Gravitational Waves
upload_time2024-01-19 02:44:11
maintainer
docs_urlNone
authorJosiel Mendonça Soares de Souza
requires_python
licenseMIT License
keywords fisher matrix gravitational waves gw dali
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # **GWDALI Software**

Software developed to perform parameter estimations of gravitational waves from compact objects coalescence (CBC) via Gaussian and Beyond-Gaussian approximation of GW likelihood. The Gaussian approximation is related to Fisher Matrix, from which it is direct to compute the covariance matrix by inverting the Fisher Matrix **[1]**. GWDALI also deals with the not-so-infrequent cases of Fisher Matrix with zero-determinant. The Beyond-Gaussian approach uses the Derivative Approximation for LIkelihoods (DALI) algorithm proposed in **[2]** and applied to gravitational waves in **[3]**, whose model parameter uncertainties are estimated via Monte Carlo sampling but less costly than using the GW likelihood with no approximation.


## Installation

To install the software run the command below:

```
$ pip install gwdali
```

## Documentation

Available in [https://gwdali.readthedocs.io/en/latest/](https://gwdali.readthedocs.io/en/latest/)
    
## Usage [example]
    import numpy as np
    #-------------------
    import GWDALI as gw
    #-------------------
    from tqdm import trange
    from astropy.cosmology import FlatLambdaCDM
    cosmo = FlatLambdaCDM(70,0.3)

    rad = np.pi/180 ; deg = 1./rad
    #--------------------------------------------
    # Detector, position and orientation
    #--------------------------------------------
    FreeParams = ['DL','iota','psi','phi_coal']

    # Cosmic Explorer:
    det0 = {"name":"CE","lon":-119,"lat":46,"rot":45,"shape":90}
    # Einstein Telescope:
    det1 = {"name":"ET","lon":10,"lat":43,"rot":0,"shape":60}
    det2 = {"name":"ET","lon":10,"lat":43,"rot":120,"shape":60}
    det3 = {"name":"ET","lon":10,"lat":43,"rot":-120,"shape":60}

    #------------------------------------------------------
    # Setting Injections (Single detection)
    #------------------------------------------------------
    z = 0.1 # Redshift

    params = {}
    params['m1']  = 1.3*(1+z) # mass of the first object [solar mass]
    params['m2']  = 1.5*(1+z) # mass of the second object [solar mass]
    params['z']   = z
    params['RA']       = np.random.uniform(-180,180)
    params['Dec']      = (np.pi/2-np.arccos(np.random.uniform(-1,1)))*deg
    params['DL']       = cosmo.luminosity_distance(z).value/1.e3 # Gpc
    params['iota']     = np.random.uniform(0,np.pi)          # Inclination angle (rad)
    params['psi']      = np.random.uniform(-np.pi,np.pi) # Polarization angle (rad)
    params['t_coal']   = 0  # Coalescence time
    params['phi_coal'] = 0  # Coalescence phase
    # Spins:
    params['sx1'] = 0
    params['sy1'] = 0
    params['sz1'] = 0
    params['sx2'] = 0
    params['sy2'] = 0
    params['sz2'] = 0

    #----------------------------------------------------------------------
    # "approximant" options:
    #               [Leading_Order, TaylorF2_py, ...] or any lal approximant
    #----------------------------------------------------------------------
    # "dali_method" options:
    #               [Fisher, Fisher_Sampling, Doublet, Triplet, Standard]
    #----------------------------------------------------------------------
    res = gw.GWDALI( Detection_Dict = params,
                     FreeParams     = FreeParams,
                     detectors      = [det0,det1,det2,det3], # Einstein Telescope + Cosmic Explorer
                     approximant    = 'TaylorF2_py',
                     dali_method    = 'Doublet',
                     sampler_method = 'nestle', # Same as Bilby sampling method
                     save_fisher    = False,
                     save_cov       = False,
                     plot_corner    = False,
                     save_samples   = False,
                     hide_info      = True,
                     index          = 1,
                     rcond          = 1.e-4,
                     npoints=300) # points for "nested sampling" or steps/walkers for "MCMC"

    Samples = res['Samples']
    Fisher  = res['Fisher']
    CovFish = res['CovFisher']
    Cov     = res['Covariance']
    Rec     = res['Recovery']
    Err     = res['Error']
    SNR     = res['SNR']

## References

[1] L. S. Finn and D. F. Chernoff, “Observing binary inspiral in gravitational radiation: One interferometer,” Phys. Rev. D, vol. 47, pp. 2198–2219, 1993.

[2] E. Sellentin, M. Quartin, and L. Amendola, “Breaking the spell of gaussianity: forecasting with higher order fisher matrices,” Monthly Notices of the Royal Astronomical Society, vol. 441, no. 2, pp. 1831–1840, 2014.

[3] Z. Wang, C. Liu, J. Zhao, and L. Shao, “Extending the fisher information matrix in gravitational-wave data analysis,” arXiv preprint arXiv:2203.02670, 2022.

## Authors

- **Josiel Mendonça Soares de Souza** (developer)
- **Riccardo Sturani** (collaborator)

## License

MIT License

            

Raw data

            {
    "_id": null,
    "home_page": "",
    "name": "GWDALI",
    "maintainer": "",
    "docs_url": null,
    "requires_python": "",
    "maintainer_email": "",
    "keywords": "fisher matrix,gravitational waves,gw,dali",
    "author": "Josiel Mendon\u00e7a Soares de Souza",
    "author_email": "jmsdsouza.phd@gmail.com",
    "download_url": "https://files.pythonhosted.org/packages/e6/16/010937487c387af87d7713e266fb13f8914a9e732d5e9982e491590cb038/GWDALI-0.1.0.tar.gz",
    "platform": null,
    "description": "# **GWDALI Software**\n\nSoftware developed to perform parameter estimations of gravitational waves from compact objects coalescence (CBC) via Gaussian and Beyond-Gaussian approximation of GW likelihood. The Gaussian approximation is related to Fisher Matrix, from which it is direct to compute the covariance matrix by inverting the Fisher Matrix **[1]**. GWDALI also deals with the not-so-infrequent cases of Fisher Matrix with zero-determinant. The Beyond-Gaussian approach uses the Derivative Approximation for LIkelihoods (DALI) algorithm proposed in **[2]** and applied to gravitational waves in **[3]**, whose model parameter uncertainties are estimated via Monte Carlo sampling but less costly than using the GW likelihood with no approximation.\n\n\n## Installation\n\nTo install the software run the command below:\n\n```\n$ pip install gwdali\n```\n\n## Documentation\n\nAvailable in [https://gwdali.readthedocs.io/en/latest/](https://gwdali.readthedocs.io/en/latest/)\n    \n## Usage [example]\n    import numpy as np\n    #-------------------\n    import GWDALI as gw\n    #-------------------\n    from tqdm import trange\n    from astropy.cosmology import FlatLambdaCDM\n    cosmo = FlatLambdaCDM(70,0.3)\n\n    rad = np.pi/180 ; deg = 1./rad\n    #--------------------------------------------\n    # Detector, position and orientation\n    #--------------------------------------------\n    FreeParams = ['DL','iota','psi','phi_coal']\n\n    # Cosmic Explorer:\n    det0 = {\"name\":\"CE\",\"lon\":-119,\"lat\":46,\"rot\":45,\"shape\":90}\n    # Einstein Telescope:\n    det1 = {\"name\":\"ET\",\"lon\":10,\"lat\":43,\"rot\":0,\"shape\":60}\n    det2 = {\"name\":\"ET\",\"lon\":10,\"lat\":43,\"rot\":120,\"shape\":60}\n    det3 = {\"name\":\"ET\",\"lon\":10,\"lat\":43,\"rot\":-120,\"shape\":60}\n\n    #------------------------------------------------------\n    # Setting Injections (Single detection)\n    #------------------------------------------------------\n    z = 0.1 # Redshift\n\n    params = {}\n    params['m1']  = 1.3*(1+z) # mass of the first object [solar mass]\n    params['m2']  = 1.5*(1+z) # mass of the second object [solar mass]\n    params['z']   = z\n    params['RA']       = np.random.uniform(-180,180)\n    params['Dec']      = (np.pi/2-np.arccos(np.random.uniform(-1,1)))*deg\n    params['DL']       = cosmo.luminosity_distance(z).value/1.e3 # Gpc\n    params['iota']     = np.random.uniform(0,np.pi)          # Inclination angle (rad)\n    params['psi']      = np.random.uniform(-np.pi,np.pi) # Polarization angle (rad)\n    params['t_coal']   = 0  # Coalescence time\n    params['phi_coal'] = 0  # Coalescence phase\n    # Spins:\n    params['sx1'] = 0\n    params['sy1'] = 0\n    params['sz1'] = 0\n    params['sx2'] = 0\n    params['sy2'] = 0\n    params['sz2'] = 0\n\n    #----------------------------------------------------------------------\n    # \"approximant\" options:\n    #               [Leading_Order, TaylorF2_py, ...] or any lal approximant\n    #----------------------------------------------------------------------\n    # \"dali_method\" options:\n    #               [Fisher, Fisher_Sampling, Doublet, Triplet, Standard]\n    #----------------------------------------------------------------------\n    res = gw.GWDALI( Detection_Dict = params,\n                     FreeParams     = FreeParams,\n                     detectors      = [det0,det1,det2,det3], # Einstein Telescope + Cosmic Explorer\n                     approximant    = 'TaylorF2_py',\n                     dali_method    = 'Doublet',\n                     sampler_method = 'nestle', # Same as Bilby sampling method\n                     save_fisher    = False,\n                     save_cov       = False,\n                     plot_corner    = False,\n                     save_samples   = False,\n                     hide_info      = True,\n                     index          = 1,\n                     rcond          = 1.e-4,\n                     npoints=300) # points for \"nested sampling\" or steps/walkers for \"MCMC\"\n\n    Samples = res['Samples']\n    Fisher  = res['Fisher']\n    CovFish = res['CovFisher']\n    Cov     = res['Covariance']\n    Rec     = res['Recovery']\n    Err     = res['Error']\n    SNR     = res['SNR']\n\n## References\n\n[1] L. S. Finn and D. F. Chernoff, \u201cObserving binary inspiral in gravitational radiation: One interferometer,\u201d Phys. Rev. D, vol. 47, pp. 2198\u20132219, 1993.\n\n[2] E. Sellentin, M. Quartin, and L. Amendola, \u201cBreaking the spell of gaussianity: forecasting with higher order fisher matrices,\u201d Monthly Notices of the Royal Astronomical Society, vol. 441, no. 2, pp. 1831\u20131840, 2014.\n\n[3] Z. Wang, C. Liu, J. Zhao, and L. Shao, \u201cExtending the fisher information matrix in gravitational-wave data analysis,\u201d arXiv preprint arXiv:2203.02670, 2022.\n\n## Authors\n\n- **Josiel Mendon\u00e7a Soares de Souza** (developer)\n- **Riccardo Sturani** (collaborator)\n\n## License\n\nMIT License\n",
    "bugtrack_url": null,
    "license": "MIT License",
    "summary": "A Fisher-Based Software for Parameter Estimation from Gravitational Waves",
    "version": "0.1.0",
    "project_urls": null,
    "split_keywords": [
        "fisher matrix",
        "gravitational waves",
        "gw",
        "dali"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "a695990dd0bcb7e9f2b0c3af7a54231c0aac882ecb1b7df2c966a19656dd3608",
                "md5": "ba3064cb02a5597933df68bdec6d8a29",
                "sha256": "e6641b49c376ab3618c5cd29386021195eca16f82d589e6e16bb8cc4e1f76119"
            },
            "downloads": -1,
            "filename": "GWDALI-0.1.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "ba3064cb02a5597933df68bdec6d8a29",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": null,
            "size": 153158,
            "upload_time": "2024-01-19T02:44:08",
            "upload_time_iso_8601": "2024-01-19T02:44:08.622414Z",
            "url": "https://files.pythonhosted.org/packages/a6/95/990dd0bcb7e9f2b0c3af7a54231c0aac882ecb1b7df2c966a19656dd3608/GWDALI-0.1.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "e616010937487c387af87d7713e266fb13f8914a9e732d5e9982e491590cb038",
                "md5": "7e2ceb770c92755f8027bb15ee725031",
                "sha256": "1c1f5df1c4cae2a19e1bd184075ba76ec257a66a1ee8c8e4ef43ed0cb49df929"
            },
            "downloads": -1,
            "filename": "GWDALI-0.1.0.tar.gz",
            "has_sig": false,
            "md5_digest": "7e2ceb770c92755f8027bb15ee725031",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": null,
            "size": 151546,
            "upload_time": "2024-01-19T02:44:11",
            "upload_time_iso_8601": "2024-01-19T02:44:11.169148Z",
            "url": "https://files.pythonhosted.org/packages/e6/16/010937487c387af87d7713e266fb13f8914a9e732d5e9982e491590cb038/GWDALI-0.1.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-01-19 02:44:11",
    "github": false,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "lcname": "gwdali"
}
        
Elapsed time: 0.31982s