{"id":34020814,"url":"https://github.com/mikecokina/elisa","last_synced_at":"2025-12-13T15:25:47.107Z","repository":{"id":47033936,"uuid":"185068734","full_name":"mikecokina/elisa","owner":"mikecokina","description":"ELISa (Eclipsing binary Learning and Interactive System) is a Python-based tool designed for efficient modeling of light and radial velocity curves of eclipsing binaries. It balances computational speed and accuracy, offering modular, cross-platform usability and built-in optimization methods like least squares and MCMC for parameter determination.","archived":false,"fork":false,"pushed_at":"2025-10-19T17:18:06.000Z","size":53892,"stargazers_count":17,"open_issues_count":3,"forks_count":6,"subscribers_count":5,"default_branch":"dev","last_synced_at":"2025-10-20T00:57:08.794Z","etag":null,"topics":["analysis","astronomy","eclipsing-binaries","modeling","physic"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/mikecokina.png","metadata":{"files":{"readme":"README.rst","changelog":"CHANGELOG.rst","contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2019-05-05T18:38:45.000Z","updated_at":"2025-10-19T17:18:10.000Z","dependencies_parsed_at":"2025-10-19T19:15:23.965Z","dependency_job_id":"e52c693e-58b1-41e4-85b4-503fb1e3061f","html_url":"https://github.com/mikecokina/elisa","commit_stats":{"total_commits":2149,"total_committers":4,"mean_commits":537.25,"dds":"0.40204746393671476","last_synced_commit":"0a8109eea7be61534cdaa2ab41d1b4c6bcb5c371"},"previous_names":[],"tags_count":8,"template":false,"template_full_name":null,"purl":"pkg:github/mikecokina/elisa","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mikecokina%2Felisa","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mikecokina%2Felisa/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mikecokina%2Felisa/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mikecokina%2Felisa/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mikecokina","download_url":"https://codeload.github.com/mikecokina/elisa/tar.gz/refs/heads/dev","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mikecokina%2Felisa/sbom","scorecard":{"id":645374,"data":{"date":"2025-08-11","repo":{"name":"github.com/mikecokina/elisa","commit":"0d2230fe0a4ea625b10846c1bf37f0de2a06efb1"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":1.7,"checks":[{"name":"Token-Permissions","score":-1,"reason":"No tokens found","details":null,"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Dangerous-Workflow","score":-1,"reason":"no workflows found","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Code-Review","score":0,"reason":"Found 0/30 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"SAST","score":0,"reason":"no SAST tool detected","details":["Warn: no pull requests merged into dev branch"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENCE:0","Info: FSF or OSI recognized license: GNU General Public License v3.0: LICENCE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'dev'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"Pinned-Dependencies","score":-1,"reason":"no dependencies found","details":null,"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"Vulnerabilities","score":0,"reason":"16 existing vulnerabilities detected","details":["Warn: Project is vulnerable to: GHSA-h2x6-5jx5-46hf","Warn: Project is vulnerable to: PYSEC-2018-34 / GHSA-2fc2-6r4j-p65h","Warn: Project is vulnerable to: PYSEC-2021-856 / GHSA-5545-2q6w-2gh6","Warn: Project is vulnerable to: PYSEC-2019-108 / GHSA-9fq2-x9r6-wfmf","Warn: Project is vulnerable to: PYSEC-2018-33 / GHSA-cw6w-4rcx-xphc","Warn: Project is vulnerable to: PYSEC-2021-857 / GHSA-f7c7-j99h-c22f","Warn: Project is vulnerable to: GHSA-fpfv-jqm9-f5jm","Warn: Project is vulnerable to: PYSEC-2017-1 / GHSA-frgw-fgh6-9g52","Warn: Project is vulnerable to: PYSEC-2020-73","Warn: Project is vulnerable to: GHSA-9hjg-9r4m-mvj7","Warn: Project is vulnerable to: GHSA-9wx4-h78v-vm56","Warn: Project is vulnerable to: PYSEC-2023-74 / GHSA-j8r2-6x86-q33q","Warn: Project is vulnerable to: PYSEC-2019-156 / GHSA-xp76-357g-9wqq","Warn: Project is vulnerable to: PYSEC-2023-102","Warn: Project is vulnerable to: PYSEC-2023-114","Warn: Project is vulnerable to: GHSA-g7vv-2v7x-gj9p"],"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}}]},"last_synced_at":"2025-08-21T12:00:57.882Z","repository_id":47033936,"created_at":"2025-08-21T12:00:57.882Z","updated_at":"2025-08-21T12:00:57.882Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":27707981,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-12-13T02:00:09.769Z","response_time":147,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["analysis","astronomy","eclipsing-binaries","modeling","physic"],"created_at":"2025-12-13T15:25:46.002Z","updated_at":"2025-12-13T15:25:47.101Z","avatar_url":"https://github.com/mikecokina.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"|GitHub version|  |Licence GPLv3| |Python version| |OS|\n\n.. |GitHub version| image:: https://img.shields.io/badge/version-0.6.0.rc1-yellow.svg\n   :target: https://github.com/mikecokina/elisa/commits/release/0.6.0.rc1\n\n.. |Python version| image:: https://img.shields.io/badge/python-3.6|3.7|3.8|3.9|3.10|3.11|3.12-orange.svg\n   :target: https://www.python.org/\n\n.. |Licence GPLv3| image:: https://img.shields.io/badge/license-GNU/GPLv3-blue.svg\n   :target: https://www.gnu.org/licenses/gpl-3.0.html\n\n.. |OS| image:: https://img.shields.io/badge/os-Linux|Windows-magenta.svg\n   :target: https://en.wikipedia.org/wiki/Operating_system\n\n.. _example_scripts: https://github.com/mikecokina/elisa/tree/master/scripts/analytics\n\nEclipsing binaries Learning \u0026 Interactive System\n================================================\n\nPublications\n------------\n\n`ELISa: A new tool for fast modelling of eclipsing binaries \u003chttps://arxiv.org/abs/2106.10116\u003e`_\n\nELISa\n-----\n\nLatest version\n~~~~~~~~~~~~~~\n\nELISa has been updated to work with the latest Python versions up to v3.12. However, the latest package\nreleased on PyPI is only compatible with Python versions up to v3.8. If you want to install ELISa with a\nnewer Python version, please install it from GitHub:\n\n    pip install git+https://github.com/mikecokina/elisa.git@release/0.6.0.rc1\n\nIn case of any installation issues, please do not hesitate to create an issue on GitHub.\n\n\n**ELISa** is a cross-platform python package dedicated to light curves modelling of close eclipsing binaries including\nsurface features such as spots (and pulsations which will be added soon). Current capabilities include:\n\n    - ``BinarySystem:`` class for modelling surfaces of detached, semi-detached and over-contact binaries\n    - ``SingleSystem:`` class for modelling surfaces of single star light curves with full implementation of spots and\n      pulsations\n    - ``Observer:`` class for generating light curves (and in future other observables)\n    - ``Spots:`` class for generating stellar spot with given longitude, latitude, radius and temperature factor\n    - ``Pulsations:`` class for modelling low amplitude pulsations based on spherical harmonics\n    - ``Fitting methods`` provide capabilities to fit radial velocities curves and light curves via implementaion of\n      ``non-linear least squares`` method and also via ``Markov Chain Monte Carlo`` method.\n    - radial velocity curve modelling in Observer class including ``Rossiter-McLaughlin`` effect, variation due to\n      spots and pulsations\n\n**ELISa** is currently still under development. Development of the following features is in progress:\n\n    - extension of ``LC`` and ``RV`` fitting methods using various additional methods and features such as\n      classification of eclipsing binaries via ``neural-networks`` aimed towards automatisation of the inverse problem,\n\nWe also plan to implement following features:\n\n    - addition of synthetic spectral line modelling\n\nRequirements\n------------\n\n**ELISa** is a python package which requires ``python v3.6+`` and has following dependencies::\n\n    astropy\u003e=4.0.1,\u003c=5.3.4\n    corner\u003e=2.2.1\n    emcee\u003e=3.0.1,\u003c=3.1.6\n    jsonschema\u003e=3.2.0\n    matplotlib\u003e=3.3.2,\u003c=3.7.5\n    numpy\u003e=1.16.2,\u003c=1.26.4\n    pandas\u003e=0.24.0,\u003c=1.5.3\n    packaging\u003c=24.2\n    pytest\u003e=3.2.3,\u003c=8.3.4\n    python-dateutil\u003e=2.6.1,\u003c=2.8.1\n    scipy\u003e=1.0.0,\u003c=1.10.1\n    tqdm\u003e4.43.0\n    parameterized\u003e=0.7.4\n    numba\u003e=0.51.2\n    requests\u003e=2.26.0\n\nand potentially also **python-tk** package or equivalent for matplotlib package to display the figures correctly.\n\n:note: although python distribution and package versions are specified precisely, that does not mean that the package\n       will not work with higher versions, only that the ELISa was not tested using newer versions. However, we highly\n       recommend sticking with the python distribution and package versions listed above.\n\nInstalling process\n------------------\n\nIn the case of ``ELISa``, the easiest and safest way to install is to create a python virtual\nenvironment and install all requirements into it. Below is a simple guide, how to do it. Details of installation differ\nin dependence on the selected operating system.\n\nUbuntu [or similar]\n~~~~~~~~~~~~~~~~~~~\n\nFirst, you have to install Python 3.6 or higher. In the latest stable version ``Ubuntu 18.04`` there is already preinstalled\npython `3.6.x`. In older versions, you will have to add the repository and install it manually. Several guides\non the internet will help you with installation, e.g. Python_3.6_\n\n.. _Python_3.6: http://ubuntuhandbook.org/index.php/2017/07/install-python-3-6-1-in-ubuntu-16-04-lts/\n\nInstall ``pip3`` python package manager if is not already installed on your system, usually by execution of the\ncommand::\n\n    apt install -y python3-pip\n\nor you can also use `raw` python script which provides installation via ``python``::\n\n    curl https://bootstrap.pypa.io/get-pip.py | python3.6\n\nInstall virtual environment by command::\n\n    pip3 install virtualenv\n\n\nTo create a virtual environment, create a directory where the python virtual environment will be stored,\ne.g. ``/\u003cany\u003e/\u003cpath\u003e/elisa/venv``\nand run the following command::\n\n    virtualenv /\u003cany\u003e/\u003cpath\u003e/elisa/venv --python=python3.6\n\nAfter few moments your virtual environment is created and ready for use. In the terminal window, activate virtual\nenvironment::\n\n    . /\u003cany\u003e/\u003cpath\u003e/elisa/venv/bin/activate\n\nWhen the virtual environment is activated, install the ``elisa`` package in the latest stable version::\n\n    pip install elisa\n\nor you can choose to install the current development version::\n\n    pip install git+https://github.com/mikecokina/elisa.git@dev\n\nYou will probably also need to install::\n\n    apt install -y python3-tk\n\nIf you would like to have a look at the jupyter notebooks covering the basic usage of this package, you should install\njupyterlab inside the previously created virtual environment::\n\n    pip3 install jupyterlab\n\nfollowed by installation of ipython kernel::\n\n    python3 -m pip install ipykernel\n\nNow you should be able to launch jupyter notebooks and run the tutorials stored in \u003celisa_dir\u003e/jupyter_tutorials/.\n\n\nWindows\n~~~~~~~\n\nTo install python in windows, download the ``python 3.6.x`` installation package from the official Python website.\nThe installation package will create all necessary dependencies except the virtual environment package.\nInstall virtual environment by execution of following command in the command line::\n\n    pip3 install virtualenv\n\nMake sure a correct version of python and pip is used. When done, create a directory where the virtual environment will be\nstored and run::\n\n    virtualenv /\u003cany\u003e/\u003cpath\u003e/elisa --python\u003cpath\u003e/\u003cto\u003e/python3.6/python.exe\n\nIt is common to specify the full path to the ``python.exe`` file under Windows, otherwise, It might not work.\n\nNow, when the virtual environment is prepared, run::\n\n    . /\u003cany\u003e/\u003cpath\u003e/elisa/Scripts/activate\n\nAnd finally install ``ELISa``::\n\n    pip install elisa\n\n\nHow to build API docs\n=====================\n\nRead this readme_ file to see detailed instruction how to generate up to date documentation.\n\n.. _readme: https://github.com/mikecokina/elisa/blob/master/docs/README.rst\n\nMinimal configuration\n---------------------\n\nFrom version **0.6**, ELISa provides a feature to make configuration easier for first time running users. We implemented\n`Settings Manager` and `Download Manager`. When any ELISa script is first time executed and there is missing configuration\nfile a wizzard will walk you through basic configuration (default configuration will be stored in path `~/.elisa/config.ini` file).\nIt asks you to supply a directories to store atmospheres and limb darkening files and default atmosphere atlas. It also gives\nyou a chance to automatically download given files without any futher needs to do it manually.\n\nManual configuration\n~~~~~~~~~~~~~~~~~~~~\n\n``ELISa`` requires minimal configuration before the first run provided by the config file. Initially, it is necessary to\ndownload Atmospheres_ models and Limb-Darkening_ tables.\n\n.. _Atmospheres: https://github.com/mikecokina/elisa/tree/dev/atmosphere\n.. _Limb-Darkening: https://github.com/mikecokina/elisa/tree/dev/limbdarkening\n\nDefault tables location\n~~~~~~~~~~~~~~~~~~~~~~~\n\nBy default, the Elisa will search for atmosphere and limb darkening tables in:\n\n - atmospheres: $HOME/.elisa/atmosphere/\n - limb darkening: $HOME/.elisa/limbdarkening/\n\ntherefore, atmosphere and limb darkening tables stored at those locations will be used by elisa by default.\n\nCustom tables location\n~~~~~~~~~~~~~~~~~~~~~~~\n\nAtmosphere models and LD coefficients can be stored on your machine in the directory of your choosing as well. Let's say you want to use ``Castelli-Kurucz 2004``\nmodels stored in the directory ``/home/user/castelli_kurucz/ck04`` and limb darkening models in the directory\n``/home/user/ld/``. You have to create a configuration ``ini`` file where\nthe model and directories will be specified. Now assume that name of our configuration file is ``elisa_config.ini`` located\nin path ``/home/user/.elisa/``. Then the content of your configuration file should at least look like the following\nexample::\n\n    [support]\n    ld_tables = /home/user/ld\n    castelli_kurucz_04_atm_tables = /home/user/castelli_kurucz/ck04\n    atlas = ck04\n\nFull content of configuration file with description might be found here:\nElisa-Configuration-File_\n\n.. _Elisa-Configuration-File: https://github.com/mikecokina/elisa/blob/master/src/elisa/conf/elisa_conf_docs.ini\n\n:warning: atmospheric models and limb darkening tables for this package are stored in industry standard ''.csv'' files.\n          Therefore, their native format is not suitable for Elisa and require\n          conversion to our standard format. Therefore the atmosphere models and LD coefficient tables have been altered\n          to form required by the Elisa.\n\nNow, you have to tell ELISa, where to find your configuration file. Environment variable\n`ELISA_CONFIG` is used to store a full path to the config file. In UNIX like operation systems it is done by the\nfollowing command::\n\n    export ELISA_CONFIG=/home/user/.elisa/elisa_config.ini\n\nThere are plenty ways how to setup environment variable which vary on operation system and also on the tool (IDE)\nthat you have in use. On Linux, as an example, you can copy the previous command to #HOME/.bashrc (depends on terminal\ntype). Optionally, you can use the ``config.ini`` file located in ``ELISa_folder/src/elisa/conf/`` without\nany need for setting an environmental variable.\n\nNow you are all setup and ready to code.\n\n\nTutorials\n-------\nIn-depth tutorials can be found here_. This directory is not a part of the elisa install \nand it should be downloaded separately from github.\n\n.. _here: https://github.com/mikecokina/elisa/tree/dev/jupyter_tutorials\n\n\nPhysics\n-------\n\nSee ELISa handbook_ to see how ELISa models single star and binary systems.\n\n.. _handbook: https://github.com/mikecokina/elisa/blob/dev/ELISa_handbook.pdf\n\n\nAvailable passbands\n-------------------\n\nELISa is currently capable of modelling light curves in the following photometric filters:\n\n::\n\n    bolometric\n    Generic.Bessell.U\n    Generic.Bessell.B\n    Generic.Bessell.V\n    Generic.Bessell.R\n    Generic.Bessell.I\n    SLOAN.SDSS.u\n    SLOAN.SDSS.g\n    SLOAN.SDSS.r\n    SLOAN.SDSS.i\n    SLOAN.SDSS.z\n    Generic.Stromgren.u\n    Generic.Stromgren.v\n    Generic.Stromgren.b\n    Generic.Stromgren.y\n    Kepler\n    Gaia.2010.G\n    Gaia.2010.BP\n    Gaia.2010.RP\n    TESS\n\n\nMultiprocessing\n---------------\n\nTo speed up the computation of light curves, parallelization of computations has been implemented. Computation\nof light curve points is separated into smaller batches and each batch is evaluated on a separate CPU core. Parallelization\nnecessarily brings some overhead to process and in some cases might cause even slower behaviour of the application.\nIt is important to choose wisely when using it, especially in the case of circular synchronous orbits which consist of\nspot-free components where multiprocessing is usually not as effective.\n\nDown below are shown some result of the multiprocessor approach for different binary system types. The absolute time necessary\nfor the calculation of the light curve is highly dependent on the type of the system and hardware. Therefore we have\nnormalized the time axis according to the maximum value in our datasets.\n\n.. figure:: ./docs/source/_static/readme/detached.circ.sync.svg\n  :width: 70%\n  :alt: detached.circ.sync.svg\n  :align: center\n\n  Paralellization benchmark for ``detached circular synchronous`` star system.\n\n.. figure:: ./docs/source/_static/readme/detached.circ.async.svg\n  :width: 70%\n  :alt: detached.circ.async.svg\n  :align: center\n\n  Paralellization benchmark for ``detached circular asynchronous`` star system.\n\n\n.. figure:: ./docs/source/_static/readme/detached.ecc.sync.svg\n  :width: 70%\n  :alt: detached.ecc.sync.svg\n  :align: center\n\n  Paralellization benchmark for ``eccentric synchronous`` star system.\n\n:note: outliers in charts are caused by curve symetrization process\n\nBuilding a simple model of a binary system - MWE\n----------------------------------------------------\n\nELISa enables fast modelling of binary systems based on parameters supplied in form of a dictionary (or json).\nParameters are divided into 'system', 'primary' and 'secondary' parameters. Binary system parameters can either supply\nmasses of the components with `mass` parameter or system's `mass_ratio` and `semi_major_axis` have to be provided\ninstead::\n\n    from elisa import BinarySystem\n\n\n    community_params = {\n        \"system\": {\n            \"inclination\": 86.0,\n            \"period\": 10.1,\n            \"argument_of_periastron\": 90.0,\n            \"gamma\": 0.0,\n            \"eccentricity\": 0.0,\n            \"primary_minimum_time\": 0.0,\n            \"phase_shift\": 0.0,\n            \"semi_major_axis\": 10.5,  # default unit is solRad\n            \"mass_ratio\": 0.5\n        },\n        \"primary\": {\n            \"surface_potential\": 7.1,\n            \"synchronicity\": 1.0,\n            \"t_eff\": \"6500.0 K\",  # parameters can be provided in string representation consistent with astropy unit format\n            \"gravity_darkening\": 1.0,\n            \"albedo\": 1.0,\n            \"metallicity\": 0.0\n        },\n        \"secondary\": {\n            \"surface_potential\": 7.1,\n            \"synchronicity\": 1.0,\n            \"t_eff\": 5000.0,\n            \"gravity_darkening\": 1.0,\n            \"albedo\": 1.0,\n            \"metallicity\": 0.0\n        }\n    }\n\n    community_binary = BinarySystem.from_json(community_params)\n\nSee tutorials 1, 2, 3, 4 for more information about this process.\n\nCalculating light curve\n-----------------------\n\nBinary system `community_binary` can be observed by utilizing a dedicated observer class::\n\n    from elisa import Observer\n\n    o = Observer(passband=[  # defining passbands at which calculate a light curve\n        'Generic.Bessell.B',\n        'Generic.Bessell.V',\n        'Generic.Bessell.R',\n        'Generic.Bessell.I'\n        ],\n    system=community_binary)  # specifying the binary system to use in light curve synthesis\n\n    # this will create a light curve containing 1200 points\n    phases, fluxes = o.observe.lc(\n        from_phase=-0.6,\n        to_phase=0.6,\n        phase_step=0.001,\n        # normalize=True  # this will produce observations normalized to 1\n    )\n\nVisualization of the results\n----------------------------\n\nElisa comes with a substantial graphic library for comfortable visualization of various results. Light curve calculated\nin the Observer instance `o` can be visualized::\n\n    o.plot.lc()\n\n.. figure:: ./docs/source/_static/readme/lc_bvri.png\n  :width: 70%\n  :alt: lc_bvri.png\n  :align: center\n\nSolving an inverse problem - general concepts\n---------------------------------------------\n\nELISa provides a built-in capability to infer binary system parameters from observations. Similar to the generating a\nbinary system demonstrated above, the fitting parameters are also supplied in form of a dictionary (json) in the\nfollowing format::\n\n    fit_params = {\n        'system': {\n            'mass_ratio': {...},\n            'eccentricity': {...},\n            ...\n        },\n        'primary: {\n            'surface_potential': {...},\n            ...\n        },\n        'secondary': {\n            'surface_potential': {...},\n            ...\n        }\n        'nuisance':{ # used only for MCMC method\n            'ln_f': {...}  # error underestimation factor\n        }\n    }\n\nEach model parameter (eg. `mass_ratio`) is additionally defined in form of a dictionary where the character and behaviour\nof the variable during the fitting procedure is specified. ELISa recognizes three main types of model variables:\n\n    - **fixed**: value of such parameter stays fixed during the whole process. A fixed-parameter can be defined as::\n\n        't_eff': {\n            'value': 5774,\n            'fixed': True,\n            'unit': 'K'\n        }\n\n    - **variable**: such parameter is optimized by the optimizer to provide the best fit to the data. This is an example\n      of the variable parameter expected from the (`min`, `max`) interval::\n\n        'surface_potential': {\n            'value': 5.2,  # initial value\n            'fixed': False,\n            'min': 4.0,\n            'max': 7.0,\n            'unit': None  # this line is not mandatory (default parameter unit is assumed in its absence)\n        }\n\n      Additionally, in the case of the MCMC method, the parameter can be sampled from the normal prior distribution. Let's say that\n      we want to take into account the errors of the effective temperature of the component 6300 +- 400 K inferred from\n      color indices::\n\n        't_eff': {\n            'value': 6300,  # mean value\n            'sigma': 400,  # standard deviation\n            'fixed': False,\n            'min': 3500,\n            'max': 50000,  # normal distribution can be additionally clipped to prevent a sampler from reaching\n            # invalid regions of parameter space\n            'unit': 'K'\n        }\n\n    - **constrained**: type of model parameter, which value is dependent on the current value of one or more variable\n      parameters. This feature is very helpful while utilizing parameters such as `a sin(i)` parameter derived during\n      radial velocity fit inside a light curve fit to constrain a semi-major axis of the system on system's\n      inclination::\n\n        'semi_major_axis': {\n           'value': 16.515,\n           'constraint': '16.515 / sin(radians(system@inclination))'\n        },\n\nOnce the model parameters are defined, we can initialize our optimization tasks that can utilize various optimizing\nmethods. The following example shows initialization of task for the fitting of the light curves::\n\n    from elisa.analytics import LCData, LCBinaryAnalyticsTask\n\n    # phased and normalized (to 1) light curve observed by the Kepler\n    kepler_data = LCData.load_from_file(filename='path/to/your/data.dat',\n                                        x_unit=None,\n                                        y_unit=None\n                                       )\n\n    task = LCBinaryAnalyticsTask(data={'Kepler': kepler_data}, method='least_squares', expected_morphology='detached')\n\nObserved data are supplied in form of a custom `Dataset` format for each filter. Optimizer task can for now use `least-squares` or `mcmc` method. The least squares method is specialized for the fast\ndetermination of a local minimum in the general vicinity of the initial parameters. On the other side the MCMC method is\nbest used as a tool for the determination of the confidence intervals of the model parameters around the solution found by\nthe least squares method. The optimizer in case of light curves requires the 'expected_morphology' of the fitted system\nwith 'detached' and 'over-contact' arguments available.\n\nSubsequently, the fitting procedure can be initiated by the following command::\n\n    task.fit(x0=fit_params, *kwargs)\n    task.save_result(param/file/name.json)  # storing results into json\n\nwhere initial parameters are provided and the fitting process can be managed by the additional keyword arguments.\nThe results can be visualised in form of a table::\n\n    lst_sqr_task.fit_summary()\n\nwhich would produce result similar to this::\n\n    BINARY SYSTEM\n    Parameter                                          value            -1 sigma            +1 sigma                unit    status\n    ------------------------------------------------------------------------------------------------------------------------------\n    Mass ratio (q=M_2/M_1):                             1.08                   -                   -                None    Fixed\n    Semi major axis (a):                               11.53                   -                   -              solRad    11.2 / sin(radians(system@inclination))\n    Inclination (i):                                   76.26                   -                   -                 deg    Variable\n    Eccentricity (e):                                   0.03                   -                   -                None    Variable\n    Argument of periastron (omega):                   197.93                   -                   -                 deg    Variable\n    Orbital period (P):                              2.47028                   -                   -                   d    Fixed\n    Additional light (l_3):                            0.014                   -                   -                None    Variable\n    Phase shift:                                   7.378e-05                   -                   -                None    Variable\n    ------------------------------------------------------------------------------------------------------------------------------\n    PRIMARY COMPONENT\n    Parameter                                          value            -1 sigma            +1 sigma                unit    status\n    ------------------------------------------------------------------------------------------------------------------------------\n    Mass (M_1):                                         1.62                   -                   -             solMass    Derived\n    Surface potential (Omega_1):                      5.8397                   -                   -                None    Variable\n    Critical potential at L_1:                        4.0162                   -                   -                   -    Derived\n    Synchronicity (F_1):                               1.067                   -                   -                None    (1 + system@eccentricity)**2 / (1 - system@eccentricity**2)**(3.0/2.0)\n    Polar gravity (log g):                             3.888                   -                   -            log(cgs)    Derived\n    Equivalent radius (R_equiv):                     0.21168                   -                   -                 SMA    Derived\n\n    Periastron radii\n    Polar radius:                                    0.20899                   -                   -                 SMA    Derived\n    Backward radius:                                 0.21457                   -                   -                 SMA    Derived\n    Side radius:                                      0.2113                   -                   -                 SMA    Derived\n    Forward radius:                                  0.21583                   -                   -                 SMA    Derived\n\n    Atmospheric parameters\n    Effective temperature (T_eff1):                   7022.0                   -                   -                   K    Fixed\n    Bolometric luminosity (L_bol):                     13.05                   -                   -               L_Sol    Derived\n    Gravity darkening factor (G_1):                      1.0                   -                   -                None    Fixed\n    Albedo (A_1):                                        1.0                   -                   -                None    Fixed\n    Metallicity (log10(X_Fe/X_H)):                       0.0                   -                   -                None    Fixed\n    ------------------------------------------------------------------------------------------------------------------------------\n    SECONDARY COMPONENT\n    Parameter                                          value            -1 sigma            +1 sigma                unit    status\n    ------------------------------------------------------------------------------------------------------------------------------\n    Mass (M_2):                                         1.75                   -                   -             solMass    Derived\n    Surface potential (Omega_2):                      5.7303                   -                   -                None    Variable\n    Critical potential at L_1:                         4.018                   -                   -                   -    Derived\n    Synchronicity (F_2):                               1.067                   -                   -                None    (1 + system@eccentricity)**2 / (1 - system@eccentricity**2)**(3.0/2.0)\n    Polar gravity (log g):                             3.857                   -                   -            log(cgs)    Derived\n    Equivalent radius (R_equiv):                     0.22835                   -                   -                 SMA    Derived\n\n    Periastron radii\n    Polar radius:                                    0.22512                   -                   -                 SMA    Derived\n    Backward radius:                                 0.23181                   -                   -                 SMA    Derived\n    Side radius:                                     0.22802                   -                   -                 SMA    Derived\n    Forward radius:                                  0.23343                   -                   -                 SMA    Derived\n\n    Atmospheric parameters\n    Effective temperature (T_eff2):                   6793.0                   -                   -                   K    Variable\n    Bolometric luminosity (L_bol):                      13.3                   -                   -               L_Sol    Derived\n    Gravity darkening factor (G_2):                      1.0                   -                   -                None    Fixed\n    Albedo (A_2):                                        1.0                   -                   -                None    Fixed\n    Metallicity (log10(X_Fe/X_H)):                       0.0                   -                   -                None    Fixed\n    ------------------------------------------------------------------------------------------------------------------------------\n\nwhere in the case of the MCMC method, the additional 1 sigma errors would be displayed.\n\nDetailed guides, how to perform a fit of radial velocities or photometric observations including working examples are\nstored in the Jupyter notebooks 11 and 12. See also notebook 10 that explains handling of ELISa's custom datasets.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmikecokina%2Felisa","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmikecokina%2Felisa","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmikecokina%2Felisa/lists"}