arnav257 / spock

πŸ–– A package to determine whether planetary orbital configurations will live long and prosper

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

SPOCK πŸ––

Stability of Planetary Orbital Configurations Klassifier

https://travis-ci.com/dtamayo/spock.svg?branch=master http://img.shields.io/badge/license-GPL-green.svg?style=flat https://img.shields.io/badge/launch-binder-ff69b4.svg?style=flat http://img.shields.io/badge/arXiv-2007.06521-green.svg?style=flat

paper_plots/spockpr.jpg

Quickstart

Let's predict the probability that a given 3-planet system is stable:

import rebound
from spock import FeatureClassifier
model = FeatureClassifier()

sim = rebound.Simulation()
sim.add(m=1.)
sim.add(m=1.e-5, P=1., e=0.03, l=0.3)
sim.add(m=1.e-5, P=1.2, e=0.03, l=2.8)
sim.add(m=1.e-5, P=1.5, e=0.03, l=-0.5)
sim.move_to_com()

model.predict_stable(sim)
>>> 0.011505529

Examples

The best place to start is the example notebooks in jupyter_examples/.

Installation

SPOCK is compatible with both Linux and Mac.

Install with:

pip install spock

SPOCK relies on XGBoost, which has installation issues with OpenMP on Mac OSX. If you have problems (dmlc/xgboost#4477), the easiest way is probably to install homebrew, and:

brew install libomp
pip install spock

About

πŸ–– A package to determine whether planetary orbital configurations will live long and prosper

License:GNU General Public License v3.0


Languages

Language:Jupyter Notebook 97.8%Language:Python 2.2%