{ "info": { "author": "Daniel Tamayo", "author_email": "tamayo.daniel@gmail.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 3 - Alpha", "Intended Audience :: Developers", "Intended Audience :: Science/Research", "License :: OSI Approved :: GNU General Public License v3 or later (GPLv3+)", "Programming Language :: Python :: 3", "Topic :: Scientific/Engineering :: Astronomy", "Topic :: Software Development :: Build Tools" ], "description": "# SPOCK \ud83d\udd96\n\n**Stability of Planetary Orbital Configurations Klassifier**\n\n[![image](https://badge.fury.io/py/spock.svg)](https://badge.fury.io/py/spock)\n[![image](https://travis-ci.com/dtamayo/spock.svg?branch=master)](https://travis-ci.com/dtamayo/spock)\n[![image](http://img.shields.io/badge/license-GPL-green.svg?style=flat)](https://github.com/dtamayo/spock/blob/master/LICENSE)\n[![image](https://img.shields.io/badge/launch-binder-ff69b4.svg?style=flat)](http://mybinder.org/repo/dtamayo/spock)\n[![image](http://img.shields.io/badge/arXiv-2007.06521-green.svg?style=flat)](http://arxiv.org/abs/2007.06521)\n[![image](http://img.shields.io/badge/arXiv-2101.04117-green.svg?style=flat)](https://arxiv.org/abs/2101.04117)\n[![image](http://img.shields.io/badge/arXiv-2106.14863-green.svg?style=flat)](https://arxiv.org/abs/2106.14863)\n![image](https://raw.githubusercontent.com/dtamayo/spock/master/paper_plots/spockpr.jpg)\n\n[Documentation](https://spock-instability.readthedocs.io/en/latest/)\n\nThe SPOCK package incorporates several machine learning and analytical tools for estimating the stability of compact planetary configurations.\nAll estimators use a common API to facilitate comparisons between them and with N-body integrations.\n\n# Quickstart\n\nLet's predict the probability that a given 3-planet system is stable\npast 1 billion orbits with the XGBoost-based classifier of [Tamayo et al., 2020](http://arxiv.org/abs/2007.06521).\n\n```python\nimport rebound\nfrom spock import FeatureClassifier\nfeature_model = FeatureClassifier()\n\nsim = rebound.Simulation()\nsim.add(m=1.)\nsim.add(m=1.e-5, P=1., e=0.03, pomega=2., l=0.5)\nsim.add(m=1.e-5, P=1.2, e=0.03, pomega=3., l=3.)\nsim.add(m=1.e-5, P=1.5, e=0.03, pomega=1.5, l=2.)\nsim.move_to_com()\n\nprint(feature_model.predict_stable(sim))\n# >>> 0.06591137\n```\n\nThat model provides a simple scalar probability of stability over a billion orbits. \nWe can instead estimate its median expected instability time using the deep regressor from [Cranmer et al., 2021](https://arxiv.org/abs/2101.04117).\n\n```python\nfrom spock import DeepRegressor\ndeep_model = DeepRegressor()\n\nmedian, lower, upper = deep_model.predict_instability_time(sim, samples=10000)\nprint(int(median))\n# >>> 242570.1378387966\n```\n\nThe returned time is expressed in the time units used in setting up the REBOUND Simulation above.\nSince we set the innermost planet orbit to unity, this corresponds to 242570 innermost planet orbits.\n\nFinally, we can compare these results to the semi-analytic criterion of [Tamayo et al., 2021](https://arxiv.org/abs/2106.14863) for how likely the configuration is to be dynamically chaotic. .\nThis is not a one-to-one comparison, but configurations that are chaotic through two-body MMR overlap are generally unstable on long timescales (see paper and examples).\n\n```python\nfrom spock import AnalyticalClassifier\nanalytical_model = AnalyticalClassifier()\n\nprint(analytical_model.predict_stable(sim))\n# >>> 0.0\n```\n\nTo match up with the above classifiers, the analytical classifier returns the probability the configuration is *regular*, i.e., not chaotic.\nA probability of zero therefore corresponds to confidently chaotic.\nSee [this example](https://github.com/dtamayo/spock/blob/master/jupyter_examples/QuickStart.ipynb) for more information about the analytical model.\n\n# Examples\n\n[Colab tutorial](https://colab.research.google.com/drive/1R3NrPmtI5DZFq_VZtv8gowINBrXM85Zv?usp=sharing)\nfor the deep regressor.\n\nThe example notebooks contain many additional examples:\n[jupyter\\_examples/](https://github.com/dtamayo/spock/tree/master/jupyter_examples).\n\n# Installation\n\nSPOCK is compatible with both Linux and Mac. SPOCK relies on XGBoost, which has installation issues with OpenMP on\nMac OSX. If you have problems (), the easiest way is\nprobably to install [homebrew](brew.sh), and:\n\n```\nbrew install libomp\n```\n\nThe most straightforward way to avoid any version conflicts is to download the Anaconda Python distribution and make a separate conda environment.\n\nHere we create we create a new conda environment called `spock` and install all the required dependencies\n```\nconda create -q --name spock -c pytorch -c conda-forge python=3.7 numpy scipy pandas scikit-learn matplotlib torchvision pytorch xgboost rebound einops jupyter pytorch-lightning ipython h5py\nconda activate spock\npip install spock\n```\n\nEach time you want to use spock you will first have to activate this `spock` conda environment (google conda environments).", "description_content_type": "text/markdown", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/dtamayo/spock", "keywords": "astronomy astrophysics exoplanets stability", "license": "GPL", "maintainer": "", "maintainer_email": "", "name": "spock", "package_url": "https://pypi.org/project/spock/", "platform": "", "project_url": "https://pypi.org/project/spock/", "project_urls": { "Homepage": "https://github.com/dtamayo/spock" }, "release_url": "https://pypi.org/project/spock/1.5.2/", "requires_dist": null, "requires_python": "", "summary": "Stability of Planetary Orbital Configurations Klassifier", "version": "1.5.2", "yanked": false, "yanked_reason": null }, "last_serial": 10799849, "releases": { "1.0.0": [], "1.0.1": [ { "comment_text": "", "digests": { "md5": "a66023d62c954f06dcd6dfc79ce9b17e", "sha256": "d8623f8cc8dd8650965125fcaab0ed578595fb1ae85c1dde5137ae88bb00337e" }, "downloads": -1, "filename": "spock-1.0.1.tar.gz", "has_sig": false, "md5_digest": "a66023d62c954f06dcd6dfc79ce9b17e", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 4591931, "upload_time": "2020-07-02T14:15:17", "upload_time_iso_8601": "2020-07-02T14:15:17.892216Z", "url": "https://files.pythonhosted.org/packages/b0/7a/50aed33a6ad7ea53544bfa8474462cd607725f6aa833b724a0ae98e9c5b9/spock-1.0.1.tar.gz", "yanked": false, "yanked_reason": null } ], "1.0.2": [ { "comment_text": "", "digests": { "md5": "3dc850fe7e81631813fcc9079bed763d", "sha256": "be229940d47ec58a8e89b9a5662beb8e7e0d164b008bd19395539ebbb00b0a76" }, "downloads": -1, "filename": "spock-1.0.2.tar.gz", "has_sig": false, "md5_digest": "3dc850fe7e81631813fcc9079bed763d", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 4605112, "upload_time": "2020-07-03T05:44:25", "upload_time_iso_8601": "2020-07-03T05:44:25.964495Z", "url": "https://files.pythonhosted.org/packages/dd/8f/abb3dec55c7de879ab511ee8d536099b7203039f0d275695cf232f4f2629/spock-1.0.2.tar.gz", "yanked": false, "yanked_reason": null } ], "1.0.3": [ { "comment_text": "", "digests": { "md5": "56005cdb039f74a86fe932ca2dd409f8", "sha256": "46f792190e1639c0d2aa9f62845c0d9524de3bec6c7249e85edaa08f41f23487" }, "downloads": -1, "filename": "spock-1.0.3.tar.gz", "has_sig": false, "md5_digest": "56005cdb039f74a86fe932ca2dd409f8", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 4605846, "upload_time": "2020-07-11T17:45:52", "upload_time_iso_8601": "2020-07-11T17:45:52.110624Z", "url": "https://files.pythonhosted.org/packages/b0/e9/f8616b0e371e8936123a4243e8861ca708f326014ed0cc1c934f66716b34/spock-1.0.3.tar.gz", "yanked": false, "yanked_reason": null } ], "1.0.4": [ { "comment_text": "", "digests": { "md5": "64cc8321d30175e4bd056f67d5895e58", "sha256": "a8746d5d02291050bae6ca39cae91a15144674d4f62645b2b6a312577d0de424" }, "downloads": -1, "filename": "spock-1.0.4.tar.gz", "has_sig": false, "md5_digest": "64cc8321d30175e4bd056f67d5895e58", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 4605832, "upload_time": "2020-07-12T14:37:47", "upload_time_iso_8601": "2020-07-12T14:37:47.661802Z", "url": "https://files.pythonhosted.org/packages/38/d9/9844f54636fbad1a2075805fd24363081013fbd1918d8f443529a9b1d1ca/spock-1.0.4.tar.gz", "yanked": false, "yanked_reason": null } ], "1.0.5": [ { "comment_text": "", "digests": { "md5": "90588e10d01f916f816e1c4c475087cf", "sha256": "5f28c5ff76b25180d5acd164f534bad85603bb1a16c9c9dfe2c048de95b6cd40" }, "downloads": -1, "filename": "spock-1.0.5.tar.gz", "has_sig": false, "md5_digest": "90588e10d01f916f816e1c4c475087cf", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 4605852, "upload_time": "2020-07-12T15:50:49", "upload_time_iso_8601": "2020-07-12T15:50:49.721891Z", "url": "https://files.pythonhosted.org/packages/29/92/b90e61b0d56424ea0f6a1e04541432c4cc53c9f3def847a3f29360c4386c/spock-1.0.5.tar.gz", "yanked": false, "yanked_reason": null } ], "1.0.6": [ { "comment_text": "", "digests": { "md5": "00e5e0505176d445a72e72f974a75345", "sha256": "24bc8f607bc4cca9fea0b72706fb9dd7c1b00eb46565eeef4984cc36a36fd67e" }, "downloads": -1, "filename": "spock-1.0.6.tar.gz", "has_sig": false, "md5_digest": "00e5e0505176d445a72e72f974a75345", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 4605749, "upload_time": "2020-07-12T15:57:34", "upload_time_iso_8601": "2020-07-12T15:57:34.157531Z", "url": "https://files.pythonhosted.org/packages/2d/3f/91811ed6c3bc2ae37d983ac3bd58fd468a349eb1e5a21b275c80f71acd93/spock-1.0.6.tar.gz", "yanked": false, "yanked_reason": null } ], "1.2.0": [ { "comment_text": "", "digests": { "md5": "c5cf8fe5b60fdce18bfbd15a50a15b6e", "sha256": "8541a9c3aa093d899d65bf595d04c8b0733797e6cfd348755ac1d06321773fa0" }, "downloads": -1, "filename": "spock-1.2.0.tar.gz", "has_sig": false, "md5_digest": "c5cf8fe5b60fdce18bfbd15a50a15b6e", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 41173817, "upload_time": "2021-01-13T15:32:19", "upload_time_iso_8601": "2021-01-13T15:32:19.611779Z", "url": "https://files.pythonhosted.org/packages/ad/c5/12f1076ed337a13dc0b464d0291dec3331033227ebb14a2b31ffdc74b294/spock-1.2.0.tar.gz", "yanked": false, "yanked_reason": null } ], "1.2.1": [ { "comment_text": "", "digests": { "md5": "0309a577054be76157e0ff9e070a916e", "sha256": "f021f90a0ceb67361beb0f73d3a0c052d0a3573627f363b04ca7cd3d305b063d" }, "downloads": -1, "filename": "spock-1.2.1.tar.gz", "has_sig": false, "md5_digest": "0309a577054be76157e0ff9e070a916e", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 41173699, "upload_time": "2021-02-03T02:43:04", "upload_time_iso_8601": "2021-02-03T02:43:04.337323Z", "url": "https://files.pythonhosted.org/packages/93/59/ee7f2dd44cbabaef33b065bbd5d932a22781bada9ab86c8974e6057d48e4/spock-1.2.1.tar.gz", "yanked": false, "yanked_reason": null } ], "1.3.0": [ { "comment_text": "", "digests": { "md5": "fece73e7fa83b2623b3282f89ee23471", "sha256": "1dbdc3bd8538a53a78610abda1ca8f3f2832ffe0fcdf8b648224694b8d41fa51" }, "downloads": -1, "filename": "spock-1.3.0.tar.gz", "has_sig": false, "md5_digest": "fece73e7fa83b2623b3282f89ee23471", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 41173593, "upload_time": "2021-01-19T03:04:33", "upload_time_iso_8601": "2021-01-19T03:04:33.992246Z", "url": "https://files.pythonhosted.org/packages/19/7a/3d66f256647762c619414f21c79db96d1fbc1f7775fcb3011ce52255c394/spock-1.3.0.tar.gz", "yanked": false, "yanked_reason": null } ], "1.3.1": [ { "comment_text": "", "digests": { "md5": "4730f4fb5d2c58bce29bd20e753d3b42", "sha256": "05ea01caf158a57b80470533c949a531b7f39f52395ffefc3acab01fc806b534" }, "downloads": -1, "filename": "spock-1.3.1.tar.gz", "has_sig": false, "md5_digest": "4730f4fb5d2c58bce29bd20e753d3b42", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 41173642, "upload_time": "2021-02-03T03:04:28", "upload_time_iso_8601": "2021-02-03T03:04:28.328612Z", "url": "https://files.pythonhosted.org/packages/b1/a8/2d526ff07c1adf646e550bdc4b80fd0a0f6f18d5d2fac339501155048042/spock-1.3.1.tar.gz", "yanked": false, "yanked_reason": null } ], "1.4.0": [ { "comment_text": "", "digests": { "md5": "88279ee2a1aced00b4c6d0e28b52ef0d", "sha256": "a11c9af08d120fcdb70c1152cc34e787a205e844d0e71358dc299a3bdee05454" }, "downloads": -1, "filename": "spock-1.4.0.tar.gz", "has_sig": false, "md5_digest": "88279ee2a1aced00b4c6d0e28b52ef0d", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 41182875, "upload_time": "2021-06-28T23:18:06", "upload_time_iso_8601": "2021-06-28T23:18:06.940689Z", "url": "https://files.pythonhosted.org/packages/26/10/d1ae150ae9eb688fb5fd0ca61400cc8ac8382127edb0def9fb1ebca2a56d/spock-1.4.0.tar.gz", "yanked": false, "yanked_reason": null } ], "1.5.0": [ { "comment_text": "", "digests": { "md5": "9976186215c4350de82159798d7feb46", "sha256": "96d14d144326d21fa87c19ac5853281dd1b6c344b33751c7b0ce78007d8f20a1" }, "downloads": -1, "filename": "spock-1.5.0.tar.gz", "has_sig": false, "md5_digest": "9976186215c4350de82159798d7feb46", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 41182891, "upload_time": "2021-06-29T01:33:07", "upload_time_iso_8601": "2021-06-29T01:33:07.700987Z", "url": "https://files.pythonhosted.org/packages/89/17/44c26146838e005bcf07ac0b892484b74b0b314f49e6a5b8129c074d3b6c/spock-1.5.0.tar.gz", "yanked": false, "yanked_reason": null } ], "1.5.2": [ { "comment_text": "", "digests": { "md5": "238e1b234e27bd324bf9ebd2235a9ccb", "sha256": "32eb91ff9f89847756691c1feb817baf51aabf56a507e847a032493ba553a8b1" }, "downloads": -1, "filename": "spock-1.5.2.tar.gz", "has_sig": false, "md5_digest": "238e1b234e27bd324bf9ebd2235a9ccb", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 41182936, "upload_time": "2021-07-01T19:37:03", "upload_time_iso_8601": "2021-07-01T19:37:03.451280Z", "url": "https://files.pythonhosted.org/packages/d8/7c/7774ad32077dd4f318a3f01cbb56ef19ce92f0af24eb4d56a4d7d98ca47b/spock-1.5.2.tar.gz", "yanked": false, "yanked_reason": null } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "238e1b234e27bd324bf9ebd2235a9ccb", "sha256": "32eb91ff9f89847756691c1feb817baf51aabf56a507e847a032493ba553a8b1" }, "downloads": -1, "filename": "spock-1.5.2.tar.gz", "has_sig": false, "md5_digest": "238e1b234e27bd324bf9ebd2235a9ccb", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 41182936, "upload_time": "2021-07-01T19:37:03", "upload_time_iso_8601": "2021-07-01T19:37:03.451280Z", "url": "https://files.pythonhosted.org/packages/d8/7c/7774ad32077dd4f318a3f01cbb56ef19ce92f0af24eb4d56a4d7d98ca47b/spock-1.5.2.tar.gz", "yanked": false, "yanked_reason": null } ], "vulnerabilities": [] }