├── .gitignore ├── .gitmodules ├── .idea ├── SPRINT.iml ├── encodings.xml ├── misc.xml ├── modules.xml └── workspace.xml ├── README.md ├── documentation ├── SPRINT_Documentation_v3.0.pdf └── architecture │ ├── InputConfigHeirarchy.draw_io.xml │ ├── README.md │ └── v1 │ ├── circinus_pipeline_arch.draw_io.xml │ └── constellation_sim_arch.draw_io.xml ├── inputs ├── README.md ├── SRP_Zhou_scripts │ ├── analyze_multirun_tests.py │ └── test_runner.py ├── analyze_multirun_tests.py ├── cases │ ├── .gitignore │ ├── ONLINE_OPS │ │ ├── README.md │ │ ├── constellation_config.json │ │ ├── ground_station_network_config.json │ │ ├── operational_profile_config.json │ │ └── sim_case_config.json │ ├── ONLINE_OPS_1_SAT │ │ ├── README.md │ │ ├── constellation_config.json │ │ ├── ground_station_network_config.json │ │ ├── operational_profile_config.json │ │ └── sim_case_config.json │ ├── SPRINT_nominal │ │ ├── constellation_config-lite.json │ │ ├── constellation_config.json │ │ ├── ground_station_network_config.json │ │ ├── operational_profile_config.json │ │ └── sim_case_config.json │ ├── case_config_READMEs │ │ └── constellation_config.md │ ├── circinus_zhou_2_sats │ │ ├── README.md │ │ ├── constellation_config.json │ │ ├── ground_station_network_config.json │ │ ├── operational_profile_config.json │ │ └── sim_case_config.json │ ├── circinus_zhou_3_sats │ │ ├── README.md │ │ ├── constellation_config.json │ │ ├── ground_station_network_config.json │ │ ├── operational_profile_config.json │ │ └── sim_case_config.json │ ├── circinus_zhou_4_sats │ │ ├── README.md │ │ ├── constellation_config.json │ │ ├── ground_station_network_config.json │ │ ├── operational_profile_config.json │ │ └── sim_case_config.json │ ├── circinus_zhou_5_sats │ │ ├── README.md │ │ ├── constellation_config.json │ │ ├── ground_station_network_config.json │ │ ├── operational_profile_config.json │ │ └── sim_case_config.json │ ├── orig_circinus_zhou │ │ ├── README.md │ │ ├── constellation_config.json │ │ ├── ground_station_network_config.json │ │ ├── operational_profile_config.json │ │ └── sim_case_config.json │ ├── sprint_lp_demo │ │ ├── constellation_config.json │ │ ├── ground_station_network_config.json │ │ ├── operational_profile_config.json │ │ └── sim_case_config.json │ ├── walker15_inc30 │ │ ├── README.md │ │ ├── autogen_files │ │ │ └── README.md │ │ ├── constellation_config.json │ │ ├── ground_station_network_config.json │ │ ├── operational_profile_config.json │ │ └── sim_case_config.json │ ├── walker18_inc30_simple │ │ ├── README.md │ │ ├── autogen_files │ │ │ └── README.md │ │ ├── constellation_config.json │ │ ├── ground_station_network_config.json │ │ ├── operational_profile_config.json │ │ ├── operational_profile_config_100_obs.json │ │ └── sim_case_config.json │ ├── walker30_inc30 │ │ ├── README.md │ │ ├── autogen_files │ │ │ └── README.md │ │ ├── constellation_config.json │ │ ├── ground_station_network_config.json │ │ ├── operational_profile_config.json │ │ └── sim_case_config.json │ └── walker30_inc30_NEN │ │ ├── README.md │ │ ├── constellation_config.json │ │ ├── ground_station_network_config.json │ │ ├── operational_profile_config.json │ │ └── sim_case_config.json ├── failure_analysis.py ├── general_config │ ├── README.md │ ├── gp_general_params_inputs.json │ ├── lp_general_params_inputs.json │ └── sim_general_config.json ├── multi_True_SRP_and_True_tx_status.json └── reference_model_definitions │ ├── gs_refs │ ├── GEO_Cape.json │ ├── KSAT.json │ ├── KSAT_Lite.json │ ├── NASA_Nen.json │ ├── NASA_Nen_extended.json │ ├── README.md │ ├── SpaceFlight.json │ ├── Zhou_Original.json │ ├── nen_nom_gs.json │ └── zhou_original_gs.json │ ├── obs_refs │ ├── Chesapeake_Bay.json │ ├── Tropics_100.json │ ├── Tropics_20.json │ ├── Zhou_2017.json │ ├── blank.json │ ├── mid_earth20.json │ └── rem.py │ ├── payload_refs │ ├── README.md │ ├── tropics_payload.json │ └── zhou_original_payload.json │ └── sat_refs │ ├── README.md │ ├── sprint_nom_xsat.json │ ├── tropics.json │ └── zhou_original_sat.json ├── multirun_tests ├── SRP_Zhou_scripts │ ├── analyze_multirun_tests.py │ └── test_runner.py ├── analyze_multirun_tests.py └── failure_analysis.py ├── requirements.txt ├── scripts ├── run_const_sim.sh ├── run_const_sim_win.sh ├── run_gp.sh ├── run_ind_gp.sh ├── run_orbit_viz.sh ├── test_runner.py ├── tools │ ├── .gitignore │ ├── case_generator │ │ ├── case_gen.py │ │ ├── constellation_blank.xlsx │ │ ├── cubesat_blank.xlsx │ │ ├── excelgen.py │ │ ├── ground_station_blank.xlsx │ │ ├── gs_gen.py │ │ ├── injected_obs_generator.py │ │ ├── json_gen.py │ │ ├── obs_gen.py │ │ ├── op_blank.xlsx │ │ ├── payload_blank.xlsx │ │ └── sim_blank.xlsx │ └── injected_obs_creator │ │ ├── injected_obs_generator.py │ │ └── injected_obs_plotter.py └── windows_launcher.bat └── source ├── Ground_Sim ├── Ground_Client.py ├── Ground_Server.py ├── Ground_Sim.py ├── Satellite_Ground_Protocol └── __init__.py ├── Removed_Satellite ├── BlockingDict.py ├── LightControl.py ├── Message_ID_Assigner.py ├── Removed_Satellite.py ├── Removed_Satellite_Client.py └── Removed_Satellite_Server.py ├── central_global_planner ├── IP_Client.py ├── IP_Server.py ├── __init__.py ├── certs │ ├── .gitignore │ └── README.md ├── cgp_main.py └── cgp_main.yaml └── sprint_tools ├── Constellation_STN.py ├── OEnum.py ├── Sprint_Types.py ├── __init__.py └── demo_ruby_client.rb /.gitignore: -------------------------------------------------------------------------------- 1 | # Byte-compiled / optimized / DLL files 2 | __pycache__/ 3 | *.py[cod] 4 | *$py.class 5 | 6 | # C extensions 7 | *.so 8 | 9 | # Distribution / packaging 10 | .Python 11 | env/ 12 | build/ 13 | develop-eggs/ 14 | dist/ 15 | downloads/ 16 | eggs/ 17 | .eggs/ 18 | lib/ 19 | lib64/ 20 | parts/ 21 | sdist/ 22 | var/ 23 | *.egg-info/ 24 | .installed.cfg 25 | *.egg 26 | 27 | # PyInstaller 28 | # Usually these files are written by a python script from a template 29 | # before PyInstaller builds the exe, so as to inject date/other infos into it. 30 | *.manifest 31 | *.spec 32 | *.pylintrc 33 | 34 | # Installer logs 35 | pip-log.txt 36 | pip-delete-this-directory.txt 37 | 38 | # Unit test / coverage reports 39 | htmlcov/ 40 | .tox/ 41 | .coverage 42 | .coverage.* 43 | .cache 44 | nosetests.xml 45 | coverage.xml 46 | *,cover 47 | .hypothesis/ 48 | 49 | # Translations 50 | *.mo 51 | *.pot 52 | 53 | # Django stuff: 54 | *.log 55 | local_settings.py 56 | 57 | # Flask stuff: 58 | instance/ 59 | .webassets-cache 60 | 61 | # Scrapy stuff: 62 | .scrapy 63 | 64 | # Sphinx documentation 65 | docs/_build/ 66 | 67 | # PyBuilder 68 | target/ 69 | 70 | # IPython Notebook 71 | .ipynb_checkpoints 72 | 73 | # pyenv 74 | .python-version 75 | 76 | # celery beat schedule file 77 | celerybeat-schedule 78 | 79 | # dotenv 80 | .env 81 | 82 | # virtualenv 83 | venv/ 84 | ENV/ 85 | 86 | # Spyder project settings 87 | .spyderproject 88 | 89 | # Rope project settings 90 | .ropeproject 91 | 92 | # For macOS users 93 | .DS_Store 94 | **/.DS_Store 95 | 96 | # files intended as local only 97 | *.local 98 | 99 | # VSCode 100 | .vscode 101 | 102 | # multirun_tests outputs and script 103 | multirun_tests/SRP_zhou_tests 104 | multirun_tests/15_Walker 105 | multirun_tests/30_Walker 106 | multirun_tests/*.json 107 | 108 | # windows env_var_setup 109 | scripts/windows_env_var_setup.bat 110 | 111 | # gurobi/planners 112 | *.lp 113 | 114 | # logs & such: 115 | *.txt 116 | *.log 117 | -------------------------------------------------------------------------------- /.gitmodules: -------------------------------------------------------------------------------- 1 | [submodule "source/circinus_sim"] 2 | path = source/circinus_sim 3 | url = git@github.com:MIT-STARLab/circinus_sim.git 4 | branch = master 5 | [submodule "source/circinus_orbit_propagation"] 6 | path = source/circinus_orbit_propagation 7 | url = git@github.com:MIT-STARLab/circinus_orbit_propagation.git 8 | branch = master 9 | [submodule "source/circinus_orbit_viz"] 10 | path = source/circinus_orbit_viz 11 | url = git@github.com:MIT-STARLab/circinus_orbit_viz.git 12 | branch = master 13 | branch = master 14 | [submodule "source/circinus_global_planner"] 15 | path = source/circinus_global_planner 16 | url = git@github.com:MIT-STARLab/circinus_global_planner.git 17 | branch = master 18 | [submodule "source/circinus_orbit_link"] 19 | path = source/circinus_orbit_link 20 | url = git@github.com:MIT-STARLab/circinus_orbit_link.git 21 | [submodule "source/circinus_tools"] 22 | path = source/circinus_tools 23 | url = git@github.com:MIT-STARLab/circinus_tools.git 24 | -------------------------------------------------------------------------------- /.idea/SPRINT.iml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /.idea/encodings.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /.idea/misc.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /.idea/modules.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /.idea/workspace.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 28 | 29 | 30 | 31 | 32 | 33 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # SPRINT 2 | **S**cheduling 3 | **P**lanning 4 | **R**outing 5 | **I**nter-satellite 6 | **N**etworking 7 | **T**ool 8 | 9 | Incorporating the **C**onstellation **I**nvestigation **R**epository with **C**ommunications, **I**nter-agent **N**etworking, **U**ncertainty, and **S**cheduling 10 | 11 | For details on the structure of SPRINT, please see the SPRINT Documentation document located in the documentation folder. 12 | 13 | # General Setup 14 | 15 | 1. Clone the repo: `git clone git@github.mit.edu:star-lab/SPRINT.git` 16 | 1. Init the appropriate submodules: 17 | 1. `cd SPRINT/source` 18 | 1. `git submodule init circinus_global_planner circinus_orbit_link_public circinus_orbit_propagation circinus_orbit_viz circinus_sim circinus_tools` 19 | 1. `git submodule update` 20 | 1. Set up your environment: 21 | 1. Install and configure your default `python` and pip to Python **3.6**, (recommended in a virtual environment, see next step). 22 | 1. Recommended: Direct installation, if needed: Download from https://www.python.org/downloads/. Note that the global planner code is currently tested with Python 3.6.7. 23 | 1. Not recommended: alternatively Homebrew, [pyenv to set to 3.6](https://github.com/pyenv/pyenv). 24 | 1. Pick your poison and stick with it or it'll get messy. 25 | 1. Confirm your version of Python (`python --version`) & location of the installation (`which python`) is the same for all subsequent steps. 26 | 1. Consider upgrading pip: `python3.6 -m pip install --upgrade pip` 27 | 1. Make a virtual environment: 28 | 1. Install virtualenv: `python3.6 -m pip install virtualenv` 29 | 1. Create virtual environment:
OS X: `python3.6 -m virtualenv --python=/usr/local/bin/python3.6 venv_dir/`,
Windows: `virtualenv --python=/c/Users/STARLab/AppData/Local/Programs/Python/Python35/python.exe venv_dir`,
Ubuntu: `virtualenv -p /usr/bin/python3.6 venv_dir`
*`python=` reflects path to the Python 3.6 executable*
*`venv_dir` is the directory of your choosing to intall this particular virtualenv instance (not in git repo)* 30 | 1. Activate the virtual environment:
OS X or Ubuntu: `source venv_dir/bin/activate`,
Windows: `source venv_dir/Scripts/activate` 31 | 1. Install required python packages. 32 | 1. cd to SPRINT base directory 33 | 2. `pip install -r requirements.txt` 34 | 1. Install Gurobi: 35 | 1. Download and install [Gurobi 8.0.0](http://www.gurobi.com/downloads/gurobi-optimizer) 36 | 1. Acquire and activate Gurobi License ([Academic is free if appropriate](https://www.gurobi.com/downloads/end-user-license-agreement-academic/)) 37 | 1. Framework setting: 38 | 1. `nano ~/.matplotlib/matplotlibrc` 39 | 1. add line: `backend: TkAgg` 40 | 41 | # Simulation Pipeline Demo: 42 | 1. Navigate to `SPRINT/scripts` 43 | 1. Run simulation:
44 | a. `./run_const_sim.sh --use orig_circinus_zhou` to specify a case corresponding to `inputs/cases/orig_circinus_zhou`.
45 | b. `./run_const_sim.sh --help` for a description of the other options.
46 | 47 | ## Separated Simulation Demo 48 | This simulation can be run such that each satellite runs on separate hardware, say a Raspberry Pi. The following demo is for a 2-satellite constellation. 49 | 1. For the ground station network:
50 | a. Navigate to `SRPINT/scripts` 51 | b. `./run_const_sim.sh --use circinus_zhou_2_sats --ground` to specify a two-satellite case and to run the ground station network part 52 | 2. For each satellite:
53 | a. Navigate to `SPRINT/scripts` 54 | b. `./run_const_sim.sh --use circinus_zhou_2_sats --satellite` to specify a two-satellite case and to run the satellite part 55 | 56 | The satellites can be initialized before the ground station network; however, satellites are given 100 tries to connect to the ground station network, once every second. If the ground station network isn't initialized in time, the satellite program exits. 57 | 58 | 59 | 60 | # Submodule dependencies 61 | * [circinus_global_planner](https://github.com/MIT-STARLab/circinus_global_planner) 62 | * [circinus_orbit_link](https://github.com/MIT-STARLab/circinus_orbit_link) 63 | * [circinus_orbit_propagation](https://github.com/MIT-STARLab/circinus_orbit_propagation) 64 | * [circinus_orbit_viz](https://github.com/MIT-STARLab/circinus_orbit_viz) 65 | * [circinus_sim](https://github.com/MIT-STARLab/circinus_sim) 66 | * [circinus_tools](https://github.com/MIT-STARLab/circinus_tools) 67 | 68 | These should be managed as if they are independent and up to date with their own master, before committing the folder from the the SPRINT main repository (which then tracks the commit of the subrepo). 69 | 70 | # History 71 | SPRINT was initiated by CIRCINUS, by [apollokit](https://github.com/apollokit). 72 | -------------------------------------------------------------------------------- /documentation/SPRINT_Documentation_v3.0.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MIT-STARLab/SPRINT/a70939ada4f49923aa06f8264d492a443338ff19/documentation/SPRINT_Documentation_v3.0.pdf -------------------------------------------------------------------------------- /documentation/architecture/InputConfigHeirarchy.draw_io.xml: -------------------------------------------------------------------------------- 1 | 7Vxbk5s2FP41nmkfdgcQGHjcW7aZSdNMnE7Tpx0ZZKwsIAryXvLrKwkJA9JeGmObTcnDBh8kEJ90vnMTzMBF9nBdwmL9O4lROnOs+GEGLmeOY9u2xf7jksdaErhOLUhKHMtGW8ECf0dSKPslGxyjqtOQEpJSXHSFEclzFNGODJYlue82W5G0e9cCJkgTLCKY6tK/cEzX6rksa3viN4STtbx14MkTSxjdJiXZ5PJ+MwesxL/6dAbVtWT7ag1jct8SgasZuCgJofVR9nCBUo6tgq3u9+6Js824S5TT13SQ03IH04189Pd5saHVzJmn7ALny5IdJfxokkySn0si9I8+Kp0XWou4Xljs9P0aU7QoYMTP3jOWY7I1zVL2y2aHMazWoq3dXKqtdFIP71BJ0UNLJJXwGpEM0fKRNXlQBFL3UHwp9fJ+Sz6hFdaydYt35koIJeElzZW3Ss8OpN6bOcC3NRK4gBWaOGCSvGnJmPTbttyOgtu2p2m4E1i6hnuut7uGz11Nw0cGD5h34QE6PHbo6fC4PhgAHk+HR4I0HoTcHkLuaxEKhkBoriH0Z4WYgBsK9t/7vKIw51Cc6ZqITpNT1mbx6fP7j1/YwUeS4RymTe+x8cYkeVuSUamp11NT77VqGg6gpjqPfUYrtGLPE3EtFXH65NZNkjerXq7TjZOYG3X6SkfKBQOESq4eKinIYnzXAWr+z4Yncc7Zk9ETmOIkF8bRStGKbs/2ga8KmCvZAlJ2d4ZvW3VhxiHOl1UhelmT6DCienrY+mjP0NMKxBqKBdGVDr9Gnh2BqeE0sGlgb3RgT2nk3kA4rFq/fLdRWWJlCpt4FJgssevqltgGzu6WONQMMTOXLUO5C1ZDwDNv4FAAqRi6HQnMDY6Kbw0Qr/saAihO0EL+JCVdk4SwIPxqKz2PNuVds0S6gLXAQQ+Yfm0d/82bsGdlv3I2yq+yh/ixPfcNUfoo63xwQwkTbQfxgZDiJegrsikjVZ2Tk09hmSDaWQ/8KZ+dnxKlkOK7bp1vp+x5oLuE3rnNh0fYn3zm6ZkkTgxdVEtU4e9wKRpw+AqCcypG5Z3zK4BzySOXEUMGlUzAFyOOYHomT2Q4jsU8pnCJ0vOmEHlBUlKK+6pSpAlmtWK0Jd4UWeXoZu1CpWnpW6eWY/udtX8iY9tXgy8v/omjsL1yV6FOev3JalWx1dCfumaAr5pNW+eVC5JX3BFnIyfM1FmXaIVzXP84MsvYvtVjGccyBUR74xlHzwteL3iKD9F7Ut6OHq3QPSRaQM/PjMto+ZrR8g9otIC+mFrwHB+dQEMnOCA6rqmGsy+X/1qAW1HFeVP64cX8wJQvmAY2DWxMAxthvmBcEbzVsWauHRojeEOxynYGiODd0XtDQRcf1+gseqZtWf4A8DzrDY0AnqAb47mec0hf2vU1eETkMRJfMeyBMz8sOIacxN7o/hN8TAmMJy/x+KLJCZ0GNg1sVAObnNDnDSUI+jm5wDe6oQY3y3bcAWzl2CtJvtdDCNgHdSbUq02jBSjQAHIOC5C+KajnEx0fo1DDCBwWIz2a+aNApcgviq3An0qywqlhN/AvkD98iUmJZ/wFuuoW58mvT7MdVoJLVCAGsiggiSRmv5DTsHP9l0l6tYu4qV1ULS7FzzHu6Eoc4JA56nmgIfATlZ1VsatddlZJjCPUnXW71a47Z2+l7qxC1SHqzpaMun+0zjxoKdk32E2cbRr6WTBEIeM1A+WVCKYUZ2givP9OeK5v8h/3Rnm+s3fKkzQnSc8emtaAidaOtp0m0B0FQWvgzH4jjKZWxO6MdmKd2iHoZqHVrpdxUBzQJusszhiFVLSsRydIaIWTTSlJaGxvN/yskjEF+T7QXn41hvgGinaCIV5w17dORNw03lQ4u2FPBrPqZrVJ0xg+nn6rRrBTyVdFpWZzra9btND4kssAaOkMTMolpjcpzm9vsPg8yDhhciyj6d8bUHoJqgaqKEkxbqDmplLv3oAKdE/4HUljVI6duEDY9S19O9BRswyogQESk+obIG3UjBmSoy8vzz4mTLoP8oEk3J2b8ffSo3RTmTafdlxwFjad8a9GcacwhVWFo1di9KJ/3ELAMwCgZDtujJ57vQmY9yKb2t+XvbbYahfyrf5M9i5UBwnahRh68LHVTDrdTw5Yu8/cenZc2gPanfbsoB7BjzqygU7l/NsEJ1WBIrxiy8GxhGNriNVZaFBVxvD86KFxf7+qd8hXUAJ9D4KMOkfnK/9f/XLbUpb56c9OARNvO4rgd1ogegKTrtFNUnD/6Rv/qt/oJu/NTXBjdVUgoa7RjrtMDNBsa9vpHT29MBaJbMDRv0Exrkmy+98M0d0nR5W6O5NkOQNMku6cMxVMUI5KmKroWAUzpDp+MGPboLeo1SO08TLRljuAuxnqXvmXNWYL2pp5V7wdP6xLlqQglfBC64IMEemwRgGslm8hGkDRKN6YXfzuRhLRYYnEM7NHZldYi5K86n/BR8KT/6IGTVbcVc2WKObz1PSJ+Ef+TrX5/KGU6oaSqs5H8w4qwyp2quj5VcoT1Hy3ToTz5IvIVp+4Q5m0sLs4gGMKdYFjikYG8HpCPRrhSSalTvXsy6TA6DzGfpoAuAZ/caAkAfu5/cpt7bFvPyUMrv4F -------------------------------------------------------------------------------- /documentation/architecture/README.md: -------------------------------------------------------------------------------- 1 | Goto draw.io website, then open .xml file from File -> Open From -> Device...
2 | 3 | # Content: 4 | * `InputConfigHeirarchy.draw_io.xml` - describes the structure and relationship of the new input file structure.
5 | * `/v1` - snapshot of architecture as it existed at 1.0. -------------------------------------------------------------------------------- /documentation/architecture/v1/constellation_sim_arch.draw_io.xml: -------------------------------------------------------------------------------- 1 | 7V1Zk+I4Ev41PLZDtnw+1tmzEb07HVu7MTuPBlTgKYMI23RVza9fCUu2LoMBYSiq6IhunJYPlJlfnlKP4N3i7XuRrub/xFOUjzwwfRvB+5HnJV5A/qaE95oQ+lFNmBXZtCa5LeEp+xsxImDUdTZFpTSwwjivspVMnODlEk0qiZYWBX6Vhz3jXH7qKp0hjfA0SXOd+kc2reY1NQKgpf+GstmcPTnmJ8bp5GVW4PWSPW7kwefNpz69SPmt2Phynk7xq0CCDyN4V2Bc1d8Wb3copzPLZ62+7rHjbPPaBVpWfS7w6gt+pfma/fKnbEEIT2lFBmYVYq9ZvfOZ2fw4RC8HI3j7OidjnlbphJ59JaJAaPNqkZMjl3wtqwK/NDNIKc9Znt/hHBebu8F7/8F9DCgdL6vHdJHlVGB+Q/kvVGWTlJxI82y2JLQJ+UWIXHX7CxX0VH7DTlR4xa5/Ym9pmAVGoteiN4HEZuU7wgtUFe9kCDsbuEyCmQAHSX342koDBLCmzQVJgJBLIZPAWXPrlg3kC+NEBxs9X5t3NCUCyg5xUc3xDC/T/KGl3racoRP913qx4uPTYiLzBb1l1f8YC+n3P+l3Jwo2LEuL6oaqEJ30PC3LbMLJj1ne3GE55YPGOZ681CRhwF+oqt6ZYqfrChNS+9o/MGVaLRBdjCe8K96bl6QH9VsG/PAnKjIytVQoNmM6uU5efYYYKWGKR6dzqxwUKE+r7JeMByamskt/4ow8VpCfUJIfCCL5FiVeFxPErhI1VLlRmHjyjQLlXepfp92IcCd9F4at6ICy+4XDGBhfuPO91PGBhDTkS/0GrcA3k9tLB/wuaPpewyvBqIowCC/Jt3+h6hUXL58Vq1xPZkUIDFgFTFgFjseqKOnNpwvhTlHPwFDM8WXmuL5uSTxo4I4b2bAkbrTVkqB8jF/tG5G9sftirE4nx2u8lrwm0a7EiW270pfFyVGuAujN5Zp5jM/DzbWvz3Vwrqnm0YmAdeVkjqbrXPeTCTxU8kwWqMz+TsebAXTamUUmo4PbUXDfx34ssul0w8A8HaP8tgk2BBxk4caWaa+vxcUUFcJ1YPMxcoUjvIp5TfjFftRIjGFMWPgNOMQ4yf7MN3Z4qL/Fh+Dn5xJVGjf3czo4WgoMJvNboXIYHXNHIpJ625B0c/JoDdxbFPopqOv29bKZYJDfA6AsF/wWFyEXvu7jNHoPbopxRtX1tP7N3d0j+ezlfVrwXgIfSlxJdNey8T5F58W34Fm6rjalVrXu+Ai1MY2eahtbtRXU+M/RjkBVVKtAV6vwbHZPj8XSCXlCVmUUGsOcWrox0YBwVjW/7zptodulQocYQzcCcpbJvSDM41HksEbPilk7VMHis3mWIRcrs4Zdrz5xKbOiTzDhMbMdfeKpLseopVa1LdD4//CGJuvNW1+nYxGosxoP6VvAYcCN50M4vtlNjAvJFu549IK+UIc+68jXoUrQc+LQA2GchEHgRrLP7/mJdJaHBDtS3YcEerpHX1apodx1RVDLZf54qAUOidbkwODbJbkuPEG3k7sXFk/smzW1Eb4bsOCMbpDGt6eab+ApW6zJw/C1htmqNTQVcU5nDeOBrOGou1LgyjIfDRcINNkqUQf8c6mAq9fT1qspUYKpHmjz3OT1BuAl0eRsOSNUrz36z4bxHQgX2zJym2S178s+6nFGjt/Zharvm8j3sGIFY02QfmDCPkL6madkKk4NpYTz3mSyF5TW99zLlvUH2ShUJj3whoNYXw/wvioLuyoLpjgl6gnMrasKuCZcZGXB4PKw0sJ1ujruGSsKga6EjW0F3eb1Kl0jGwrKlVFynM5XpQDhDo05JGWjVHMirZojta7wrpQLbVwxMcwFZwv3Ar3c/v0nOf6DgNnq0/knMDwfMsY6MvLI+99oskEJjRv6BIuzP09XdNzibUYXCDjPOX6dzIlSOARv03Faog4OKkx6COmfvZjUGadI4UNycneTlwp5RM/7aAR+JonOzgBagEKezz11A7levKNHap5qqyX7WK1/vM9PRFDPNn5uLt27gTtUOs7lhuzd49WlIsr4ZvHLoePlhvKjG8RjPVGyiWtpusAD/1g+Y/LPvZ4L+diwFZ8atgK+Uqthc5OsGAC4uM0TmPr7uKSMJNM/or3kuNDT+B+bpSe3RGGi5puGZarLq217WaPt9udDWJT9rKRsfntZo8SwwokvnDmzOfJV+A/CreZCGw9iq+aCT9WXubCKLR5INGwZ0M919ZD/y8+14efyVYcXiCzEs5QEzou3r1RUx/O1cF3jYXLseLuOLmfFl09kEbfcQInODfX2kzm5UGPoPX5d5tnypaQ30RLR/12xcyqPGRufc/TGQEPEDwVkdLIgEQpjwWMMttcGzMgY8RWY7RLK7koTg0WRy0u8RH0hyjdAVF+EaqtDgdrIBKEmCIEh6xYcWUXibo+ydheGSjav7zrxwN1xo47muVOtpAI6at0VuCyHluTHx+ghSmxJ8k7fQigVGCoFh4q6QdJd0LdFpe1nACBSuoz8IWU9diMnals/uf62+VFHaAz1eSfHvooQx4o/qubHj1CEfV2VWGk5sO0auEA3JZ0rUu3WLbctcJKUlMm56OeCQaNvw/KsU3Un8Bb2fXQyAYkkI8EhuravYLqRbPX4LgVdSuVG8bbxsiC3VysdF5YtjN7D/Xs1p4UqUPLti3RLc/Y9QWxvMBFDFe88DdTDE5UNm9qxWMHN8fgTd5nBWM6fG7vM3FPxw7BDwY/PW1GPfDU5Nez6ZX0B81c/yu7W67inDT028vJjBxIHivzrRUEcagbREZ1RX759X2fUD31ncz2MEvowpQM19Bx+hr6G4vFaXO7k6n6i7h/qMiGGVV2M7itv0lF3kGRc6LIlRDugamKIpnpvCzdUpKTYdNWD6r173Fb5gzBw2nM+35nK8s5y0fb8qD5e6RC13jig28jrXmvrUjMYw/ajLGowLbzlAmi90ezEm3psKdhsAZ2BeocG2nsSAugI3FaUnryHEwqfSDFt9qxOrKcAP8emBnGXih60SYh/nEmxHHQbtnv8ahQ9roQeyAmgZhnsII2i+vqTmxnaCM4dXqzwEjEYuDajCEPZCvouMLREcQiTtk21ERsaVucJ5Vy6O/mXFu3FTz+UM5Q+CA385GlM67G+p+Oi0F40GUiVLi0BE4QytA2sZFD39AknFs7ItNrrw5bYpc6j3iV2ghPTjIw0lUr5ufusIL4K3bsZ3qO0rLr9qF3FzD0K8r6y4bmrW8MTRt7EHXbcNu0D5WSu74UOzRXxOqWnmOC+YXkUJg7s3AaHPmVL7mngQj7fhEdMKSPiIpDzN5q66E68UfhEVWCk/nbFBJIyjHZq1EZt6jDP9Ub2azEeAErC2QeBAfF8gwB7VhBPz/PVu7Ezp+6k1uckG+R37w+ncaq3h31SM0QO2/+/pVa49r/IgQ//Bw== -------------------------------------------------------------------------------- /inputs/SRP_Zhou_scripts/test_runner.py: -------------------------------------------------------------------------------- 1 | # this file is intended for setting up and running multiple SPRINT runs, where the config is changed 2 | # in between runs 3 | import json 4 | from subprocess import Popen 5 | # things to modify 6 | # r'..\inputs\reference_model_definitions\sat_refs\zhou_original_sat.json': NVM - only doing Xlnk-always 7 | 8 | # setup things to step through 9 | # r'..\inputs\cases\orig_circinus\zhou\sim_case_config.json': ['scenario_params']['sim_run_perturbations']['schedule_disruptions'] 10 | schedule_disruptions_list = [ 11 | {"G0": [["2016-02-14T04:00:00.000000Z","2016-02-15T04:00:00.000000Z"]]}, 12 | {"G1": [["2016-02-14T04:00:00.000000Z","2016-02-14T16:00:00.000000Z"]]}, 13 | {"G2": [["2016-02-14T04:00:00.000000Z","2016-02-15T04:00:00.000000Z"]]} 14 | ] 15 | 16 | # r'..\inputs\general_config\lp_general_params_inputs.json': ['lp_general_params']['use_self_replanner'] 17 | SRP_settings_list = [True, False] 18 | 19 | SD_file = r'C:\Users\User\circinusGit\SPRINT\inputs\cases\orig_circinus_zhou\sim_case_config.json' 20 | SRP_file = r'C:\Users\User\circinusGit\SPRINT\inputs\\general_config\lp_general_params_inputs.json' 21 | scripts_folder = r"C:\Users\User\circinusGit\SPRINT\scripts" 22 | # NOTE: NEED TO BE IN SCRIPTS DIRECTORY TO FIND windows_env_var_setup.bat 23 | for SD_setting in schedule_disruptions_list: 24 | 25 | with open(SD_file, "r") as jsonFile: 26 | data = json.load(jsonFile) 27 | 28 | data['scenario_params']['sim_run_perturbations']['schedule_disruptions'] = SD_setting 29 | 30 | print('Setting schedule disruptions to: %s' % SD_setting) 31 | with open(SD_file, "w") as jsonFile: 32 | json.dump(data, jsonFile, indent=4, separators=(',', ': ')) 33 | 34 | for SRP_setting in SRP_settings_list: 35 | with open(SRP_file, "r") as jsonFile: 36 | data = json.load(jsonFile) 37 | 38 | data['lp_general_params']['use_self_replanner'] = SRP_setting 39 | 40 | print('Setting SRP to: %s' % SRP_setting) 41 | with open(SRP_file, "w") as jsonFile: 42 | json.dump(data, jsonFile, indent=4, separators=(',', ': ')) 43 | 44 | print('New Settings Set - run batch file') 45 | 46 | # python runner_const_sim.py --inputs_location /c/Users/wcgru/Documents/GitHubClones/SPRINT/scripts/../inputs --case_name orig_circinus_zhou --restore_pickle "" --remote_debug false 47 | 48 | p = Popen(r"C:\Users\User\circinusGit\SPRINT\scripts\windows_launcher.bat") 49 | stdout, stderr = p.communicate() -------------------------------------------------------------------------------- /inputs/cases/.gitignore: -------------------------------------------------------------------------------- 1 | # Autogen files shan't be carried around, except as example nominal files only (at this level so if a new case is made the user isn't responsible for copying this.) 2 | 3 | */autogen_files/*.json 4 | */output_files/* -------------------------------------------------------------------------------- /inputs/cases/ONLINE_OPS/README.md: -------------------------------------------------------------------------------- 1 | # Instructions for ONLINE_OPS 2 | 3 | Use of ONLINE OPS still requires the basic case-configs as a normal case. They can be empty of some specifics (satellites, groundstations, start/stop time), which can be filled in by users via provided TCP interface, but the files and structures should still be created. 4 | 5 | - constellation_config.json 6 | - ground_station_network_config.json 7 | - operational_profile_config.json 8 | - sim_case_config.json -------------------------------------------------------------------------------- /inputs/cases/ONLINE_OPS/ground_station_network_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "config_title":"ground_station_network_config", 3 | "version-gsndef":"0.0.1", 4 | "verbose_details":"https://github.mit.edu/star-lab/CIRCINUS/blob/SPRINT-restructuring-1/inputs/nom_sprint/groundstation_network/README.md", 5 | 6 | "network_definition":{ 7 | "version-gsn":"0.0.1", 8 | 9 | "default_gs_ref_model_name":"zhou_original_gs", 10 | 11 | "gs_net_params":{ 12 | "num_stations": 4, 13 | "gs_network_name": "Zhou 2017 GS", 14 | "gs_network_version": "1", 15 | "elevation_cutoff_deg":10, 16 | "stations": [ 17 | {"id": "G0", "name": "Beijing","name_pretty": "Beijing 0","latitude_deg":40.0,"longitude_deg":116.0,"height_m":0,"comm_type":"Zhou_2017_dlnk"}, 18 | {"id": "G1", "name": "Kashi","name_pretty": "Kashi 1", "latitude_deg":39.5,"longitude_deg":76.0,"height_m":0,"comm_type":"Zhou_2017_dlnk"}, 19 | {"id": "G2", "name": "Sanya","name_pretty": "Sanya 2", "latitude_deg":18.0,"longitude_deg":109.5,"height_m":0,"comm_type":"Zhou_2017_dlnk"}, 20 | {"id": "G3", "name": "Xi'an","name_pretty": "Xi'an 3", "latitude_deg":34.0,"longitude_deg":108.0,"height_m":0,"comm_type":"Zhou_2017_dlnk"} 21 | ] 22 | }, 23 | "sim_gs_network_params": { 24 | "_comments":"TODO: Reevaluate the location of these params. (Should they go in the sim file? Or GP? I think they are describing the behavior of the network, so this should be ok)", 25 | "time_epsilon_s": 1, 26 | "gsn_ps_params" : { 27 | "_comments": [ 28 | "replan_release_wait_time_s simulates the amount of time required to actually run the global planner in real life. from the perspective of this code the global planner will run instantaneously. After it runs, the sim will wait this amount of time before making those plans available", 29 | "release_first_plans_immediately = True means that global planner will immediately make its first set of global plans available (they won't be queued up for release at a later time)", 30 | "6300 seconds is 105 minutes, about the length of an orbit at 1000 km altitude", 31 | "replan release time is conservative here" 32 | ], 33 | "replan_interval_s": 6300, 34 | "replan_release_wait_time_s": 60, 35 | "release_first_plans_immediately": true 36 | } 37 | } 38 | 39 | 40 | } 41 | 42 | 43 | } -------------------------------------------------------------------------------- /inputs/cases/ONLINE_OPS/operational_profile_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "version":"0.0.1", 3 | "which_config":"operational_profile_config", 4 | "where_should_i_be":"inputs/cases/", 5 | "what_goes_here":"things that only matter to the choices to be made about the current case.", 6 | 7 | "ops_profile_params": { 8 | "obs_params": { 9 | "num_targets": 5, 10 | "target_set_name": "Zhou 2017 Missions", 11 | "target_set_version": "1", 12 | "target_set_id": "2018-4-14", 13 | "elevation_cutoff_deg":60, 14 | "targets": [ 15 | {"id": "targ0","name": "Himalaya","name_pretty": "obs0", "latitude_deg": 28.0, "longitude_deg": 87.0,"height_m": 0}, 16 | {"id": "targ1","name": "Mamiraus","name_pretty": "obs1", "latitude_deg": -2.0, "longitude_deg": -66.0,"height_m": 0}, 17 | {"id": "targ2","name": "Cape York","name_pretty": "obs2", "latitude_deg": -11.0, "longitude_deg": 142.5,"height_m": 0}, 18 | {"id": "targ3","name": "Alaska Coast","name_pretty": "obs3", "latitude_deg": 60.0, "longitude_deg": -148,"height_m": 0}, 19 | {"id": "targ4","name": "Greenland","name_pretty": "obs4", "latitude_deg": 69.0, "longitude_deg": -49,"height_m": 0} 20 | ] 21 | }, 22 | "link_disables": { 23 | "_comment": "The satellite and GS ids below will always be interpreted as strings. if the ids are specified as integers in other files, they will be considered the same if their string representation is the same", 24 | "dlnk_direc_disabled_gs_ID_by_sat_IDstr": { 25 | }, 26 | "xlnk_direc_disabled_xsat_ID_by_sat_IDstr": { 27 | } 28 | } 29 | 30 | } 31 | 32 | } -------------------------------------------------------------------------------- /inputs/cases/ONLINE_OPS_1_SAT/README.md: -------------------------------------------------------------------------------- 1 | # Instructions for ONLINE_OPS 2 | 3 | Use of ONLINE OPS still requires the basic case-configs as a normal case. They can be empty of some specifics (satellites, groundstations, start/stop time), which can be filled in by users via provided TCP interface, but the files and structures should still be created. 4 | 5 | - constellation_config.json 6 | - ground_station_network_config.json 7 | - operational_profile_config.json 8 | - sim_case_config.json -------------------------------------------------------------------------------- /inputs/cases/ONLINE_OPS_1_SAT/constellation_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "config_type":"constellation_config", 3 | "version-const_def":"0.0.1", 4 | "verbose_details":"https://github.mit.edu/star-lab/CIRCINUS/blob/SPRINT-restructuring-1/inputs/nom_sprint/constellation/README.md", 5 | 6 | "constellation_definition":{ 7 | "version-const":"0.0.1", 8 | 9 | "sat_ref_model_name":"zhou_original_sat", 10 | 11 | "constellation_params":{ 12 | "num_satellites": 1, 13 | "sat_id_prefix": "S", 14 | "sat_ids": "duplicate,range_inclusive,0,0", 15 | "sat_id_order": "default", 16 | 17 | "_comments" : [ 18 | "orbit_neighbor_direction_method specifies how to figure out which direction an orbit neighbor is in, for determining activity transition times. by_increasing_sat_index means that if the receive sat index is larger than tx sat index (i.e. further in sat_id_order list) then the crosslink is in an INCREASING direction", 19 | "" 20 | ], 21 | "intra-orbit_neighbor_direction_method": "by_increasing_sat_index", 22 | 23 | "orbit_params" : { 24 | "sat_ids_by_orbit_name": { 25 | "orbit0": ["S0"] 26 | }, 27 | "sat_orbital_elems": [ 28 | { 29 | "sat_id": "S0", 30 | "def_type":"indv", 31 | "kepler_meananom": { 32 | "a_km": 7378, 33 | "e": 0, 34 | "i_deg": 97.86, 35 | "RAAN_deg": 0, 36 | "arg_per_deg": 0, 37 | "M_deg": 90 38 | }, 39 | "propagation_method": "matlab_delkep" 40 | } 41 | ] 42 | } 43 | } 44 | 45 | } 46 | 47 | 48 | } 49 | -------------------------------------------------------------------------------- /inputs/cases/ONLINE_OPS_1_SAT/ground_station_network_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "config_title":"ground_station_network_config", 3 | "version-gsndef":"0.0.1", 4 | "verbose_details":"https://github.mit.edu/star-lab/CIRCINUS/blob/SPRINT-restructuring-1/inputs/nom_sprint/groundstation_network/README.md", 5 | 6 | "network_definition":{ 7 | "version-gsn":"0.0.1", 8 | 9 | "default_gs_ref_model_name":"zhou_original_gs", 10 | 11 | "gs_net_params":{ 12 | "num_stations": 1, 13 | "gs_network_name": "Zhou 2017 GS", 14 | "gs_network_version": "1", 15 | "elevation_cutoff_deg":10, 16 | "stations": [ 17 | {"id": "G0", "name": "Beijing","name_pretty": "Beijing 0","latitude_deg":40.0,"longitude_deg":116.0,"height_m":0,"comm_type":"Zhou_2017_dlnk"} 18 | ] 19 | }, 20 | "sim_gs_network_params": { 21 | "_comments":"TODO: Reevaluate the location of these params. (Should they go in the sim file? Or GP? I think they are describing the behavior of the network, so this should be ok)", 22 | "time_epsilon_s": 1, 23 | "gsn_ps_params" : { 24 | "_comments": [ 25 | "replan_release_wait_time_s simulates the amount of time required to actually run the global planner in real life. from the perspective of this code the global planner will run instantaneously. After it runs, the sim will wait this amount of time before making those plans available", 26 | "release_first_plans_immediately = True means that global planner will immediately make its first set of global plans available (they won't be queued up for release at a later time)", 27 | "6300 seconds is 105 minutes, about the length of an orbit at 1000 km altitude", 28 | "replan release time is conservative here" 29 | ], 30 | "replan_interval_s": 6300, 31 | "replan_release_wait_time_s": 60, 32 | "release_first_plans_immediately": true 33 | } 34 | } 35 | 36 | 37 | } 38 | 39 | 40 | } 41 | -------------------------------------------------------------------------------- /inputs/cases/ONLINE_OPS_1_SAT/operational_profile_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "version":"0.0.1", 3 | "which_config":"operational_profile_config", 4 | "where_should_i_be":"inputs/cases/", 5 | "what_goes_here":"things that only matter to the choices to be made about the current case.", 6 | 7 | "ops_profile_params": { 8 | "obs_params": { 9 | "num_targets": 5, 10 | "target_set_name": "Zhou 2017 Missions", 11 | "target_set_version": "1", 12 | "target_set_id": "2018-4-14", 13 | "elevation_cutoff_deg":60, 14 | "targets": [ 15 | {"id": "targ0","name": "Himalaya","name_pretty": "obs0", "latitude_deg": 28.0, "longitude_deg": 87.0,"height_m": 0}, 16 | {"id": "targ1","name": "Mamiraus","name_pretty": "obs1", "latitude_deg": -2.0, "longitude_deg": -66.0,"height_m": 0}, 17 | {"id": "targ2","name": "Cape York","name_pretty": "obs2", "latitude_deg": -11.0, "longitude_deg": 142.5,"height_m": 0}, 18 | {"id": "targ3","name": "Alaska Coast","name_pretty": "obs3", "latitude_deg": 60.0, "longitude_deg": -148,"height_m": 0}, 19 | {"id": "targ4","name": "Greenland","name_pretty": "obs4", "latitude_deg": 69.0, "longitude_deg": -49,"height_m": 0} 20 | ] 21 | }, 22 | "link_disables": { 23 | "_comment": "The satellite and GS ids below will always be interpreted as strings. if the ids are specified as integers in other files, they will be considered the same if their string representation is the same", 24 | "dlnk_direc_disabled_gs_ID_by_sat_IDstr": { 25 | }, 26 | "xlnk_direc_disabled_xsat_ID_by_sat_IDstr": { 27 | } 28 | } 29 | 30 | } 31 | 32 | } -------------------------------------------------------------------------------- /inputs/cases/ONLINE_OPS_1_SAT/sim_case_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": "0.0.1", 3 | "which_config": "sim_case_config", 4 | "where_should_i_be": "inputs/cases/", 5 | "what_goes_here": "things that only matter to the simulation, or definition of time, that is relatively likely to vary per case. Things which vary for tweaks and will stay the same otherwise should go in /inputs/admin_config/sim_general_config.json instead", 6 | "scenario_params": { 7 | "start_utc": "2016-02-14T04:00:00.000000Z", 8 | "end_utc": "2016-02-15T04:00:00.000000Z", 9 | "use_crosslinks": true, 10 | "all_sats_same_time_system": true, 11 | "restore_pkl_name": "pickles/", 12 | "sat_schedule_hotstart": true, 13 | "lookup_params": { 14 | "xlnk_range_rates": { 15 | "_comment": "The names here should be different from built-in comm type names", 16 | "Zhou_2017_xlnk": { 17 | "range_units": "km", 18 | "rates_units": "Mbps", 19 | "interpolation_method": "floor", 20 | "range_rates_table": [ 21 | [ 22 | 0, 23 | 10 24 | ] 25 | ] 26 | } 27 | }, 28 | "dlnk_range_rates": { 29 | "_comment1": "The names here should be different from built-in comm type names", 30 | "_comment2": "they say this rate is a random distribution over {0,20,40} Mbps for each downlink timeslot. I'll just use the average...", 31 | "Zhou_2017_dlnk": { 32 | "range_units": "km", 33 | "rates_units": "Mbps", 34 | "interpolation_method": "floor", 35 | "range_rates_table": [ 36 | [ 37 | 0, 38 | 20 39 | ] 40 | ] 41 | } 42 | } 43 | }, 44 | "sim_run_perturbations": { 45 | "do_inject_obs": true, 46 | "schedule_disruptions": { 47 | "G0": [ 48 | [ 49 | "2016-02-14T04:00:00.000000Z", 50 | "2016-02-14T16:00:00.000000Z" 51 | ] 52 | ] 53 | }, 54 | "injected_observations": [ 55 | { 56 | "indx": 8, 57 | "end_utc": "2016-02-14T15:12:02.827026Z", 58 | "sat_id": "S0", 59 | "type": "hardcoded", 60 | "start_utc": "2016-02-14T15:11:02.827026Z" 61 | }, 62 | { 63 | "indx": 20, 64 | "end_utc": "2016-02-14T18:46:56.198028Z", 65 | "sat_id": "S0", 66 | "type": "hardcoded", 67 | "start_utc": "2016-02-14T18:45:56.198028Z" 68 | }, 69 | { 70 | "indx": 22, 71 | "end_utc": "2016-02-14T15:13:31.779520Z", 72 | "sat_id": "S0", 73 | "type": "hardcoded", 74 | "start_utc": "2016-02-14T15:12:31.779520Z" 75 | }, 76 | { 77 | "indx": 24, 78 | "end_utc": "2016-02-14T14:12:12.058434Z", 79 | "sat_id": "S0", 80 | "type": "hardcoded", 81 | "start_utc": "2016-02-14T14:11:12.058434Z" 82 | }, 83 | { 84 | "indx": 28, 85 | "end_utc": "2016-02-14T05:02:51.509312Z", 86 | "sat_id": "S0", 87 | "type": "hardcoded", 88 | "start_utc": "2016-02-14T05:01:51.509312Z" 89 | }, 90 | { 91 | "indx": 31, 92 | "end_utc": "2016-02-14T19:26:09.145608Z", 93 | "sat_id": "S0", 94 | "type": "hardcoded", 95 | "start_utc": "2016-02-14T19:25:09.145608Z" 96 | }, 97 | { 98 | "indx": 34, 99 | "end_utc": "2016-02-14T14:00:13.611338Z", 100 | "sat_id": "S0", 101 | "type": "hardcoded", 102 | "start_utc": "2016-02-14T13:59:13.611338Z" 103 | } 104 | 105 | ] 106 | } 107 | } 108 | } 109 | -------------------------------------------------------------------------------- /inputs/cases/SPRINT_nominal/operational_profile_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "version":"0.0.1", 3 | "which_config":"operational_profile_config", 4 | "where_should_i_be":"inputs/cases/", 5 | "what_goes_here":"things that only matter to the choices to be made about the current case.", 6 | 7 | "ops_profile_params": { 8 | "obs_params": { 9 | "num_targets": 19, 10 | "target_set_name": "GEO-CAPE Scenes", 11 | "target_set_version": "1", 12 | "target_set_id": "2019-2-20", 13 | "elevation_cutoff_deg":60, 14 | "_comment":"Scene numbers listed correspond to GEO-CAPE FR scenes. Lat/long correspond to the center of each scene.", 15 | "targets": [ 16 | {"id": "targ0", "name": "scene1", "name_pretty": "obs0", "latitude_deg": 47.9395, "longitude_deg": -126.8506, "height_m": 0}, 17 | {"id": "targ1", "name": "scene2", "name_pretty": "obs1", "latitude_deg": 43.4326, "longitude_deg": -127.9426, "height_m": 0}, 18 | {"id": "targ2", "name": "scene3", "name_pretty": "obs2", "latitude_deg": 36.8907, "longitude_deg": -121.5899, "height_m": 0}, 19 | {"id": "targ3", "name": "scene4", "name_pretty": "obs3", "latitude_deg": 31.8694, "longitude_deg": -119.7753, "height_m": 0}, 20 | {"id": "targ4", "name": "scene5", "name_pretty": "obs4", "latitude_deg": 26.9929, "longitude_deg": -95.3666, "height_m": 0}, 21 | {"id": "targ5", "name": "scene6", "name_pretty": "obs5", "latitude_deg": 28.3815, "longitude_deg": -89.9399, "height_m": 0}, 22 | {"id": "targ6", "name": "scene7", "name_pretty": "obs6", "latitude_deg": 27.7502, "longitude_deg": -84.8929, "height_m": 0}, 23 | {"id": "targ7", "name": "scene8", "name_pretty": "obs7", "latitude_deg": 30.3431, "longitude_deg": -72.8011, "height_m": 0}, 24 | {"id": "targ8", "name": "scene9", "name_pretty": "obs8", "latitude_deg": 30.7858, "longitude_deg": -79.1106, "height_m": 0}, 25 | {"id": "targ9", "name": "scene10", "name_pretty": "obs9", "latitude_deg": 24.7100, "longitude_deg": -77.3878, "height_m": 0}, 26 | {"id": "targ10", "name": "scene11", "name_pretty": "obs10", "latitude_deg": 34.9294, "longitude_deg": -69.5721, "height_m": 0}, 27 | {"id": "targ11", "name": "scene12", "name_pretty": "obs11", "latitude_deg": 43.4378, "longitude_deg": -74.9875, "height_m": 0}, 28 | {"id": "targ12", "name": "scene13", "name_pretty": "obs12", "latitude_deg": 44.9772, "longitude_deg": -83.2117, "height_m": 0}, 29 | {"id": "targ13", "name": "scene14", "name_pretty": "obs13", "latitude_deg": 45.7600, "longitude_deg": -87.0750, "height_m": 0}, 30 | {"id": "targ14", "name": "scene15", "name_pretty": "obs14", "latitude_deg": 22.2823, "longitude_deg": -94.9570, "height_m": 0}, 31 | {"id": "targ15", "name": "scene16", "name_pretty": "obs15", "latitude_deg": 42.4901, "longitude_deg": -64.4311, "height_m": 0}, 32 | {"id": "targ16", "name": "scene17", "name_pretty": "obs16", "latitude_deg": 35.4907, "longitude_deg": -75.4724, "height_m": 0}, 33 | {"id": "targ17", "name": "scene18", "name_pretty": "obs17", "latitude_deg": 24.4862, "longitude_deg": -82.5786, "height_m": 0}, 34 | {"id": "targ18", "name": "scene19", "name_pretty": "obs18", "latitude_deg": 41.7472, "longitude_deg": -68.6284, "height_m": 0} 35 | ] 36 | }, 37 | "link_disables": { 38 | "_comment": "The satellite and GS ids below will always be interpreted as strings. if the ids are specified as integers in other files, they will be considered the same if their string representation is the same", 39 | "dlnk_direc_disabled_gs_ID_by_sat_IDstr": { 40 | }, 41 | "xlnk_direc_disabled_xsat_ID_by_sat_IDstr": { 42 | } 43 | } 44 | } 45 | 46 | } -------------------------------------------------------------------------------- /inputs/cases/SPRINT_nominal/sim_case_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "version":"0.0.1", 3 | "which_config":"sim_case_config", 4 | "where_should_i_be":"inputs/cases/", 5 | "what_goes_here":"things that only matter to the simulation, or definition of time, that is relatively likely to vary per case. Things which vary for tweaks and will stay the same otherwise should go in /inputs/admin_config/sim_general_config.json instead", 6 | 7 | "scenario_params": { 8 | "start_utc": "2016-02-14T04:00:00.000000Z", 9 | "end_utc": "2016-02-14T08:00:00.000000Z", 10 | "use_crosslinks": true, 11 | "all_sats_same_time_system": true, 12 | 13 | "restore_pkl_name": "pickles/", 14 | 15 | "sat_schedule_hotstart": true, 16 | 17 | "lookup_params": { 18 | "xlnk_range_rates" : { 19 | "_comment": "The names here should be different from built-in comm type names", 20 | "Zhou_2017_xlnk": { 21 | "range_units": "km", 22 | "rates_units": "Mbps", 23 | "interpolation_method": "floor", 24 | "range_rates_table": [ 25 | [0, 10] 26 | ] 27 | } 28 | }, 29 | "dlnk_range_rates" : { 30 | "_comment1": "The names here should be different from built-in comm type names", 31 | "_comment2": "they say this rate is a random distribution over {0,20,40} Mbps for each downlink timeslot. I'll just use the average...", 32 | "Zhou_2017_dlnk": { 33 | "range_units": "km", 34 | "rates_units": "Mbps", 35 | "interpolation_method": "floor", 36 | "range_rates_table": [ 37 | [0, 20] 38 | ] 39 | } 40 | } 41 | }, 42 | "sim_run_perturbations": { 43 | "do_inject_obs": true, 44 | "schedule_disruptions": { 45 | "_comment": "each key is the global UID of a sim agent, time windows correspond to outage periods" 46 | }, 47 | "injected_observations": [ 48 | ] 49 | } 50 | 51 | } 52 | } -------------------------------------------------------------------------------- /inputs/cases/case_config_READMEs/constellation_config.md: -------------------------------------------------------------------------------- 1 | # Defining satellite orbits in the Constellation Configuration. 2 | 3 | Valid entries in constellation_config.json, (for a particular case), 4 | in constellation_definition > constellation_params > orbit_params > sat_orbital_elems 5 | 6 | ### Definition by Plane 7 | In this case you define each plane of sats in a constellation, by giving the shape of the orbit and the count and position of the sats within the orbit. This is for ease of definition: early in the sim, this is automatically broken into the individual format. 8 | ``` 9 | { 10 | "def_type":"plane", 11 | "orbit_indx" : 0, 12 | "plane_def": { 13 | "a_km" : 7378, 14 | "e" : 0, 15 | "i_deg" : 97.86, 16 | "RAAN_deg" : 0, 17 | "arg_per_deg" : 0 18 | }, 19 | 20 | "first_M_deg" : 90, "_comment1" : "anomaly of first sat, which subsequent will follow", 21 | "spacing_type" : "progressive", "_comment2" : "spacing: 'even', or 'progressive', or 'set'; indicate whether the sats in the plane are evenly spaced (val ignored/not needed), or should space progressively by the subsequently provided 'spacing_val', or should fix each to a anomoly in a set (array) to allow arbitrary values ", 22 | "spacing_val" : 90, "_comment3" : "for example, this combo would result in 3 sats in this plane, with the first at 90 deg anomaly, followed by 2 more at 180 and 270." 23 | 24 | "first_sat_id" : 0, "_comment4" : "the comnbo of first_sat_id, and sats_in_plane must not result in conflicting indices, and should be 'in order' without gaps, and in total match 'num_satellites' and 'sat_ids' field above. Sorry for the restrictions for now, will make a validation function.", 25 | "sats_in_plane" : 3, 26 | 27 | "propagation_method": "matlab_delkep" 28 | } 29 | ``` 30 | 31 | ### Definition by individual enumeration 32 | In this case it is required to list each satellite and its elements individually. This matches the "original" format given by CIRCINUS, excepting the addition of the "def_type" field. 33 | ``` 34 | { 35 | "sat_id": "S0", 36 | "def_type":"indv", 37 | "kepler_meananom": { 38 | "a_km": 7378, 39 | "e": 0, 40 | "i_deg": 97.86, 41 | "RAAN_deg": 0, 42 | "arg_per_deg": 0, 43 | "M_deg": 90 44 | }, 45 | "propagation_method": "matlab_delkep" 46 | }, 47 | ``` 48 | 49 | ### Definition by constellation type 50 | There exist expansions for descriptions of "Walker" constellations, but these will need to be updated to not catch on assertions around the prior two here. Walker constellations can also be specified by the above plane-wise definition. -------------------------------------------------------------------------------- /inputs/cases/circinus_zhou_2_sats/README.md: -------------------------------------------------------------------------------- 1 | # Original CIRCINUS use-case 2 | 3 | ## Description of Original Zhou use-case: 4 | Cases are fundamentally defined by a constellation and set ground stations, and further specified by an operational profile which defines intended up-time, as well as targets; and by a simulation scenario which defines actual up-time and performance. The SPRINT zhou use case is one of several use cases demonstrated with the first version of CIRCINUS. 5 | 6 | ## Required Case-specific Configuration Files, in this directory: 7 | * `constellation_config.json` 8 | * `ground_station_network_config.json` 9 | * `operational_profile_config.json` 10 | * `sim_case_config.json` 11 | 12 | ## Further required in the model definition directory `inputs/reference_model_definitions`: 13 | * `/gs_refs/zhou_original_gs.json` 14 | * `/payload_refs/zhou_original_payload.json` 15 | * `/sat_refs/zhou_original_sat.json` 16 | 17 | ### Hold on where do I find all these files? 18 | [New file structure](https://drive.google.com/open?id=1CQP91ySWmHOgwE4s4TaXmAkO5aoH4krC) 19 | 20 | 21 | [Original file dataflow](https://drive.google.com/open?id=18GtxUUbO9V40Ifl_81Cpz0z-GL1XkV4R) 22 | 23 | 24 | -------------------------------------------------------------------------------- /inputs/cases/circinus_zhou_2_sats/constellation_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "config_type": "constellation_config", 3 | "version-const_def": "0.0.1", 4 | "verbose_details": "https://github.mit.edu/star-lab/CIRCINUS/blob/SPRINT-restructuring-1/inputs/nom_sprint/constellation/README.md", 5 | "constellation_definition": { 6 | "version-const": "0.0.1", 7 | "constellation_params": { 8 | "num_satellites": 2, 9 | "sat_id_prefix": "S", 10 | "sat_ids": "duplicate,range_inclusive,0,1", 11 | "sat_id_order": "default", 12 | "_comments": [ 13 | "orbit_neighbor_direction_method specifies how to figure out which direction an orbit neighbor is in, for determining activity transition times. by_increasing_sat_index means that if the receive sat index is larger than tx sat index (i.e. further in sat_id_order list) then the crosslink is in an INCREASING direction", 14 | "" 15 | ], 16 | "intra-orbit_neighbor_direction_method": "by_increasing_sat_index", 17 | "orbit_params": { 18 | "sat_ids_by_orbit_name": { 19 | "orbit0": [ 20 | "S0" 21 | ], 22 | "orbit1": [ 23 | "S1" 24 | ] 25 | }, 26 | "sat_orbital_elems": [ 27 | { 28 | "sat_id": "S0", 29 | "def_type": "indv", 30 | "kepler_meananom": { 31 | "a_km": 7378, 32 | "e": 0, 33 | "i_deg": 97.86, 34 | "RAAN_deg": 0, 35 | "arg_per_deg": 0, 36 | "M_deg": 90 37 | }, 38 | "propagation_method": "matlab_delkep" 39 | }, 40 | { 41 | "sat_id": "S1", 42 | "def_type": "indv", 43 | "kepler_meananom": { 44 | "a_km": 7378, 45 | "e": 0, 46 | "i_deg": 83.86, 47 | "RAAN_deg": 0, 48 | "arg_per_deg": 0, 49 | "M_deg": 120 50 | }, 51 | "propagation_method": "matlab_delkep" 52 | } 53 | ] 54 | } 55 | }, 56 | "sat_ref_model_name": "zhou_original_sat" 57 | } 58 | } -------------------------------------------------------------------------------- /inputs/cases/circinus_zhou_2_sats/ground_station_network_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "config_title":"ground_station_network_config", 3 | "version-gsndef":"0.0.1", 4 | "verbose_details":"https://github.mit.edu/star-lab/CIRCINUS/blob/SPRINT-restructuring-1/inputs/nom_sprint/groundstation_network/README.md", 5 | 6 | "network_definition":{ 7 | "version-gsn":"0.0.1", 8 | 9 | "default_gs_ref_model_name":"zhou_original_gs", 10 | 11 | "gs_net_params":{ 12 | "num_stations": 4, 13 | "gs_network_name": "Zhou 2017 GS", 14 | "gs_network_version": "1", 15 | "elevation_cutoff_deg":10, 16 | "stations": [ 17 | {"id": "G0", "name": "Beijing","name_pretty": "Beijing 0","latitude_deg":40.0,"longitude_deg":116.0,"height_m":0,"comm_type":"Zhou_2017_dlnk"}, 18 | {"id": "G1", "name": "Kashi","name_pretty": "Kashi 1", "latitude_deg":39.5,"longitude_deg":76.0,"height_m":0,"comm_type":"Zhou_2017_dlnk"}, 19 | {"id": "G2", "name": "Sanya","name_pretty": "Sanya 2", "latitude_deg":18.0,"longitude_deg":109.5,"height_m":0,"comm_type":"Zhou_2017_dlnk"}, 20 | {"id": "G3", "name": "Xi'an","name_pretty": "Xi'an 3", "latitude_deg":34.0,"longitude_deg":108.0,"height_m":0,"comm_type":"Zhou_2017_dlnk"} 21 | ] 22 | }, 23 | "sim_gs_network_params": { 24 | "_comments":"TODO: Reevaluate the location of these params. (Should they go in the sim file? Or GP? I think they are describing the behavior of the network, so this should be ok)", 25 | "time_epsilon_s": 1, 26 | "gsn_ps_params" : { 27 | "_comments": [ 28 | "replan_release_wait_time_s simulates the amount of time required to actually run the global planner in real life. from the perspective of this code the global planner will run instantaneously. After it runs, the sim will wait this amount of time before making those plans available", 29 | "release_first_plans_immediately = True means that global planner will immediately make its first set of global plans available (they won't be queued up for release at a later time)", 30 | "6300 seconds is 105 minutes, about the length of an orbit at 1000 km altitude", 31 | "replan release time is conservative here" 32 | ], 33 | "replan_interval_s": 6300, 34 | "replan_release_wait_time_s": 60, 35 | "release_first_plans_immediately": true 36 | } 37 | } 38 | 39 | 40 | } 41 | 42 | 43 | } -------------------------------------------------------------------------------- /inputs/cases/circinus_zhou_2_sats/operational_profile_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "version":"0.0.1", 3 | "which_config":"operational_profile_config", 4 | "where_should_i_be":"inputs/cases/", 5 | "what_goes_here":"things that only matter to the choices to be made about the current case.", 6 | 7 | "ops_profile_params": { 8 | "obs_params": { 9 | "num_targets": 5, 10 | "target_set_name": "Zhou 2017 Missions", 11 | "target_set_version": "1", 12 | "target_set_id": "2018-4-14", 13 | "elevation_cutoff_deg":60, 14 | "targets": [ 15 | {"id": "targ0","name": "Himalaya","name_pretty": "obs0", "latitude_deg": 28.0, "longitude_deg": 87.0,"height_m": 0}, 16 | {"id": "targ1","name": "Mamiraus","name_pretty": "obs1", "latitude_deg": -2.0, "longitude_deg": -66.0,"height_m": 0}, 17 | {"id": "targ2","name": "Cape York","name_pretty": "obs2", "latitude_deg": -11.0, "longitude_deg": 142.5,"height_m": 0}, 18 | {"id": "targ3","name": "Alaska Coast","name_pretty": "obs3", "latitude_deg": 60.0, "longitude_deg": -148,"height_m": 0}, 19 | {"id": "targ4","name": "Greenland","name_pretty": "obs4", "latitude_deg": 69.0, "longitude_deg": -49,"height_m": 0} 20 | ] 21 | }, 22 | "link_disables": { 23 | "_comment": "The satellite and GS ids below will always be interpreted as strings. if the ids are specified as integers in other files, they will be considered the same if their string representation is the same", 24 | "dlnk_direc_disabled_gs_ID_by_sat_IDstr": { 25 | }, 26 | "xlnk_direc_disabled_xsat_ID_by_sat_IDstr": { 27 | } 28 | } 29 | 30 | } 31 | 32 | } -------------------------------------------------------------------------------- /inputs/cases/circinus_zhou_3_sats/README.md: -------------------------------------------------------------------------------- 1 | # Original CIRCINUS use-case 2 | 3 | ## Description of Original Zhou use-case: 4 | Cases are fundamentally defined by a constellation and set ground stations, and further specified by an operational profile which defines intended up-time, as well as targets; and by a simulation scenario which defines actual up-time and performance. The SPRINT zhou use case is one of several use cases demonstrated with the first version of CIRCINUS. 5 | 6 | ## Required Case-specific Configuration Files, in this directory: 7 | * `constellation_config.json` 8 | * `ground_station_network_config.json` 9 | * `operational_profile_config.json` 10 | * `sim_case_config.json` 11 | 12 | ## Further required in the model definition directory `inputs/reference_model_definitions`: 13 | * `/gs_refs/zhou_original_gs.json` 14 | * `/payload_refs/zhou_original_payload.json` 15 | * `/sat_refs/zhou_original_sat.json` 16 | 17 | ### Hold on where do I find all these files? 18 | [New file structure](https://drive.google.com/open?id=1CQP91ySWmHOgwE4s4TaXmAkO5aoH4krC) 19 | 20 | 21 | [Original file dataflow](https://drive.google.com/open?id=18GtxUUbO9V40Ifl_81Cpz0z-GL1XkV4R) 22 | 23 | 24 | -------------------------------------------------------------------------------- /inputs/cases/circinus_zhou_3_sats/constellation_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "config_type": "constellation_config", 3 | "version-const_def": "0.0.1", 4 | "verbose_details": "https://github.mit.edu/star-lab/CIRCINUS/blob/SPRINT-restructuring-1/inputs/nom_sprint/constellation/README.md", 5 | "constellation_definition": { 6 | "version-const": "0.0.1", 7 | "constellation_params": { 8 | "num_satellites": 3, 9 | "sat_id_prefix": "S", 10 | "sat_ids": "duplicate,range_inclusive,0,2", 11 | "sat_id_order": "default", 12 | "_comments": [ 13 | "orbit_neighbor_direction_method specifies how to figure out which direction an orbit neighbor is in, for determining activity transition times. by_increasing_sat_index means that if the receive sat index is larger than tx sat index (i.e. further in sat_id_order list) then the crosslink is in an INCREASING direction", 14 | "" 15 | ], 16 | "intra-orbit_neighbor_direction_method": "by_increasing_sat_index", 17 | "orbit_params": { 18 | "sat_ids_by_orbit_name": { 19 | "orbit0": [ 20 | "S0", 21 | "S1" 22 | ], 23 | "orbit1": [ 24 | "S2" 25 | ] 26 | }, 27 | "sat_orbital_elems": [ 28 | { 29 | "sat_id": "S0", 30 | "def_type": "indv", 31 | "kepler_meananom": { 32 | "a_km": 7378, 33 | "e": 0, 34 | "i_deg": 97.86, 35 | "RAAN_deg": 0, 36 | "arg_per_deg": 0, 37 | "M_deg": 90 38 | }, 39 | "propagation_method": "matlab_delkep" 40 | }, 41 | { 42 | "sat_id": "S1", 43 | "def_type": "indv", 44 | "kepler_meananom": { 45 | "a_km": 7378, 46 | "e": 0, 47 | "i_deg": 97.86, 48 | "RAAN_deg": 0, 49 | "arg_per_deg": 0, 50 | "M_deg": 180 51 | }, 52 | "propagation_method": "matlab_delkep" 53 | }, 54 | { 55 | "sat_id": "S2", 56 | "def_type": "indv", 57 | "kepler_meananom": { 58 | "a_km": 7378, 59 | "e": 0, 60 | "i_deg": 83.86, 61 | "RAAN_deg": 0, 62 | "arg_per_deg": 0, 63 | "M_deg": 120 64 | }, 65 | "propagation_method": "matlab_delkep" 66 | } 67 | ] 68 | } 69 | }, 70 | "sat_ref_model_name": "zhou_original_sat" 71 | } 72 | } -------------------------------------------------------------------------------- /inputs/cases/circinus_zhou_3_sats/ground_station_network_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "config_title":"ground_station_network_config", 3 | "version-gsndef":"0.0.1", 4 | "verbose_details":"https://github.mit.edu/star-lab/CIRCINUS/blob/SPRINT-restructuring-1/inputs/nom_sprint/groundstation_network/README.md", 5 | 6 | "network_definition":{ 7 | "version-gsn":"0.0.1", 8 | 9 | "default_gs_ref_model_name":"zhou_original_gs", 10 | 11 | "gs_net_params":{ 12 | "num_stations": 4, 13 | "gs_network_name": "Zhou 2017 GS", 14 | "gs_network_version": "1", 15 | "elevation_cutoff_deg":10, 16 | "stations": [ 17 | {"id": "G0", "name": "Beijing","name_pretty": "Beijing 0","latitude_deg":40.0,"longitude_deg":116.0,"height_m":0,"comm_type":"Zhou_2017_dlnk"}, 18 | {"id": "G1", "name": "Kashi","name_pretty": "Kashi 1", "latitude_deg":39.5,"longitude_deg":76.0,"height_m":0,"comm_type":"Zhou_2017_dlnk"}, 19 | {"id": "G2", "name": "Sanya","name_pretty": "Sanya 2", "latitude_deg":18.0,"longitude_deg":109.5,"height_m":0,"comm_type":"Zhou_2017_dlnk"}, 20 | {"id": "G3", "name": "Xi'an","name_pretty": "Xi'an 3", "latitude_deg":34.0,"longitude_deg":108.0,"height_m":0,"comm_type":"Zhou_2017_dlnk"} 21 | ] 22 | }, 23 | "sim_gs_network_params": { 24 | "_comments":"TODO: Reevaluate the location of these params. (Should they go in the sim file? Or GP? I think they are describing the behavior of the network, so this should be ok)", 25 | "time_epsilon_s": 1, 26 | "gsn_ps_params" : { 27 | "_comments": [ 28 | "replan_release_wait_time_s simulates the amount of time required to actually run the global planner in real life. from the perspective of this code the global planner will run instantaneously. After it runs, the sim will wait this amount of time before making those plans available", 29 | "release_first_plans_immediately = True means that global planner will immediately make its first set of global plans available (they won't be queued up for release at a later time)", 30 | "6300 seconds is 105 minutes, about the length of an orbit at 1000 km altitude", 31 | "replan release time is conservative here" 32 | ], 33 | "replan_interval_s": 6300, 34 | "replan_release_wait_time_s": 60, 35 | "release_first_plans_immediately": true 36 | } 37 | } 38 | 39 | 40 | } 41 | 42 | 43 | } -------------------------------------------------------------------------------- /inputs/cases/circinus_zhou_3_sats/operational_profile_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "version":"0.0.1", 3 | "which_config":"operational_profile_config", 4 | "where_should_i_be":"inputs/cases/", 5 | "what_goes_here":"things that only matter to the choices to be made about the current case.", 6 | 7 | "ops_profile_params": { 8 | "obs_params": { 9 | "num_targets": 5, 10 | "target_set_name": "Zhou 2017 Missions", 11 | "target_set_version": "1", 12 | "target_set_id": "2018-4-14", 13 | "elevation_cutoff_deg":60, 14 | "targets": [ 15 | {"id": "targ0","name": "Himalaya","name_pretty": "obs0", "latitude_deg": 28.0, "longitude_deg": 87.0,"height_m": 0}, 16 | {"id": "targ1","name": "Mamiraus","name_pretty": "obs1", "latitude_deg": -2.0, "longitude_deg": -66.0,"height_m": 0}, 17 | {"id": "targ2","name": "Cape York","name_pretty": "obs2", "latitude_deg": -11.0, "longitude_deg": 142.5,"height_m": 0}, 18 | {"id": "targ3","name": "Alaska Coast","name_pretty": "obs3", "latitude_deg": 60.0, "longitude_deg": -148,"height_m": 0}, 19 | {"id": "targ4","name": "Greenland","name_pretty": "obs4", "latitude_deg": 69.0, "longitude_deg": -49,"height_m": 0} 20 | ] 21 | }, 22 | "link_disables": { 23 | "_comment": "The satellite and GS ids below will always be interpreted as strings. if the ids are specified as integers in other files, they will be considered the same if their string representation is the same", 24 | "dlnk_direc_disabled_gs_ID_by_sat_IDstr": { 25 | }, 26 | "xlnk_direc_disabled_xsat_ID_by_sat_IDstr": { 27 | } 28 | } 29 | 30 | } 31 | 32 | } -------------------------------------------------------------------------------- /inputs/cases/circinus_zhou_4_sats/README.md: -------------------------------------------------------------------------------- 1 | # Original CIRCINUS use-case 2 | 3 | ## Description of Original Zhou use-case: 4 | Cases are fundamentally defined by a constellation and set ground stations, and further specified by an operational profile which defines intended up-time, as well as targets; and by a simulation scenario which defines actual up-time and performance. The SPRINT zhou use case is one of several use cases demonstrated with the first version of CIRCINUS. 5 | 6 | ## Required Case-specific Configuration Files, in this directory: 7 | * `constellation_config.json` 8 | * `ground_station_network_config.json` 9 | * `operational_profile_config.json` 10 | * `sim_case_config.json` 11 | 12 | ## Further required in the model definition directory `inputs/reference_model_definitions`: 13 | * `/gs_refs/zhou_original_gs.json` 14 | * `/payload_refs/zhou_original_payload.json` 15 | * `/sat_refs/zhou_original_sat.json` 16 | 17 | ### Hold on where do I find all these files? 18 | [New file structure](https://drive.google.com/open?id=1CQP91ySWmHOgwE4s4TaXmAkO5aoH4krC) 19 | 20 | 21 | [Original file dataflow](https://drive.google.com/open?id=18GtxUUbO9V40Ifl_81Cpz0z-GL1XkV4R) 22 | 23 | 24 | -------------------------------------------------------------------------------- /inputs/cases/circinus_zhou_4_sats/constellation_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "config_type": "constellation_config", 3 | "version-const_def": "0.0.1", 4 | "verbose_details": "https://github.mit.edu/star-lab/CIRCINUS/blob/SPRINT-restructuring-1/inputs/nom_sprint/constellation/README.md", 5 | "constellation_definition": { 6 | "version-const": "0.0.1", 7 | "constellation_params": { 8 | "num_satellites": 4, 9 | "sat_id_prefix": "S", 10 | "sat_ids": "duplicate,range_inclusive,0,3", 11 | "sat_id_order": "default", 12 | "_comments": [ 13 | "orbit_neighbor_direction_method specifies how to figure out which direction an orbit neighbor is in, for determining activity transition times. by_increasing_sat_index means that if the receive sat index is larger than tx sat index (i.e. further in sat_id_order list) then the crosslink is in an INCREASING direction", 14 | "" 15 | ], 16 | "intra-orbit_neighbor_direction_method": "by_increasing_sat_index", 17 | "orbit_params": { 18 | "sat_ids_by_orbit_name": { 19 | "orbit0": [ 20 | "S0", 21 | "S1" 22 | ], 23 | "orbit1": [ 24 | "S2", 25 | "S3" 26 | ] 27 | }, 28 | "sat_orbital_elems": [ 29 | { 30 | "sat_id": "S0", 31 | "def_type": "indv", 32 | "kepler_meananom": { 33 | "a_km": 7378, 34 | "e": 0, 35 | "i_deg": 97.86, 36 | "RAAN_deg": 0, 37 | "arg_per_deg": 0, 38 | "M_deg": 90 39 | }, 40 | "propagation_method": "matlab_delkep" 41 | }, 42 | { 43 | "sat_id": "S1", 44 | "def_type": "indv", 45 | "kepler_meananom": { 46 | "a_km": 7378, 47 | "e": 0, 48 | "i_deg": 97.86, 49 | "RAAN_deg": 0, 50 | "arg_per_deg": 0, 51 | "M_deg": 180 52 | }, 53 | "propagation_method": "matlab_delkep" 54 | }, 55 | { 56 | "sat_id": "S3", 57 | "def_type": "indv", 58 | "kepler_meananom": { 59 | "a_km": 7378, 60 | "e": 0, 61 | "i_deg": 83.86, 62 | "RAAN_deg": 0, 63 | "arg_per_deg": 0, 64 | "M_deg": 60 65 | }, 66 | "propagation_method": "matlab_delkep" 67 | }, 68 | { 69 | "sat_id": "S2", 70 | "def_type": "indv", 71 | "kepler_meananom": { 72 | "a_km": 7378, 73 | "e": 0, 74 | "i_deg": 83.86, 75 | "RAAN_deg": 0, 76 | "arg_per_deg": 0, 77 | "M_deg": 120 78 | }, 79 | "propagation_method": "matlab_delkep" 80 | } 81 | ] 82 | } 83 | }, 84 | "sat_ref_model_name": "zhou_original_sat" 85 | } 86 | } 87 | -------------------------------------------------------------------------------- /inputs/cases/circinus_zhou_4_sats/ground_station_network_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "config_title":"ground_station_network_config", 3 | "version-gsndef":"0.0.1", 4 | "verbose_details":"https://github.mit.edu/star-lab/CIRCINUS/blob/SPRINT-restructuring-1/inputs/nom_sprint/groundstation_network/README.md", 5 | 6 | "network_definition":{ 7 | "version-gsn":"0.0.1", 8 | 9 | "default_gs_ref_model_name":"zhou_original_gs", 10 | 11 | "gs_net_params":{ 12 | "num_stations": 4, 13 | "gs_network_name": "Zhou 2017 GS", 14 | "gs_network_version": "1", 15 | "elevation_cutoff_deg":10, 16 | "stations": [ 17 | {"id": "G0", "name": "Beijing","name_pretty": "Beijing 0","latitude_deg":40.0,"longitude_deg":116.0,"height_m":0,"comm_type":"Zhou_2017_dlnk"}, 18 | {"id": "G1", "name": "Kashi","name_pretty": "Kashi 1", "latitude_deg":39.5,"longitude_deg":76.0,"height_m":0,"comm_type":"Zhou_2017_dlnk"}, 19 | {"id": "G2", "name": "Sanya","name_pretty": "Sanya 2", "latitude_deg":18.0,"longitude_deg":109.5,"height_m":0,"comm_type":"Zhou_2017_dlnk"}, 20 | {"id": "G3", "name": "Xi'an","name_pretty": "Xi'an 3", "latitude_deg":34.0,"longitude_deg":108.0,"height_m":0,"comm_type":"Zhou_2017_dlnk"} 21 | ] 22 | }, 23 | "sim_gs_network_params": { 24 | "_comments":"TODO: Reevaluate the location of these params. (Should they go in the sim file? Or GP? I think they are describing the behavior of the network, so this should be ok)", 25 | "time_epsilon_s": 1, 26 | "gsn_ps_params" : { 27 | "_comments": [ 28 | "replan_release_wait_time_s simulates the amount of time required to actually run the global planner in real life. from the perspective of this code the global planner will run instantaneously. After it runs, the sim will wait this amount of time before making those plans available", 29 | "release_first_plans_immediately = True means that global planner will immediately make its first set of global plans available (they won't be queued up for release at a later time)", 30 | "6300 seconds is 105 minutes, about the length of an orbit at 1000 km altitude", 31 | "replan release time is conservative here" 32 | ], 33 | "replan_interval_s": 6300, 34 | "replan_release_wait_time_s": 60, 35 | "release_first_plans_immediately": true 36 | } 37 | } 38 | 39 | 40 | } 41 | 42 | 43 | } -------------------------------------------------------------------------------- /inputs/cases/circinus_zhou_4_sats/operational_profile_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "version":"0.0.1", 3 | "which_config":"operational_profile_config", 4 | "where_should_i_be":"inputs/cases/", 5 | "what_goes_here":"things that only matter to the choices to be made about the current case.", 6 | 7 | "ops_profile_params": { 8 | "obs_params": { 9 | "num_targets": 5, 10 | "target_set_name": "Zhou 2017 Missions", 11 | "target_set_version": "1", 12 | "target_set_id": "2018-4-14", 13 | "elevation_cutoff_deg":60, 14 | "targets": [ 15 | {"id": "targ0","name": "Himalaya","name_pretty": "obs0", "latitude_deg": 28.0, "longitude_deg": 87.0,"height_m": 0}, 16 | {"id": "targ1","name": "Mamiraus","name_pretty": "obs1", "latitude_deg": -2.0, "longitude_deg": -66.0,"height_m": 0}, 17 | {"id": "targ2","name": "Cape York","name_pretty": "obs2", "latitude_deg": -11.0, "longitude_deg": 142.5,"height_m": 0}, 18 | {"id": "targ3","name": "Alaska Coast","name_pretty": "obs3", "latitude_deg": 60.0, "longitude_deg": -148,"height_m": 0}, 19 | {"id": "targ4","name": "Greenland","name_pretty": "obs4", "latitude_deg": 69.0, "longitude_deg": -49,"height_m": 0} 20 | ] 21 | }, 22 | "link_disables": { 23 | "_comment": "The satellite and GS ids below will always be interpreted as strings. if the ids are specified as integers in other files, they will be considered the same if their string representation is the same", 24 | "dlnk_direc_disabled_gs_ID_by_sat_IDstr": { 25 | }, 26 | "xlnk_direc_disabled_xsat_ID_by_sat_IDstr": { 27 | } 28 | } 29 | 30 | } 31 | 32 | } -------------------------------------------------------------------------------- /inputs/cases/circinus_zhou_5_sats/README.md: -------------------------------------------------------------------------------- 1 | # Original CIRCINUS use-case 2 | 3 | ## Description of Original Zhou use-case: 4 | Cases are fundamentally defined by a constellation and set ground stations, and further specified by an operational profile which defines intended up-time, as well as targets; and by a simulation scenario which defines actual up-time and performance. The SPRINT zhou use case is one of several use cases demonstrated with the first version of CIRCINUS. 5 | 6 | ## Required Case-specific Configuration Files, in this directory: 7 | * `constellation_config.json` 8 | * `ground_station_network_config.json` 9 | * `operational_profile_config.json` 10 | * `sim_case_config.json` 11 | 12 | ## Further required in the model definition directory `inputs/reference_model_definitions`: 13 | * `/gs_refs/zhou_original_gs.json` 14 | * `/payload_refs/zhou_original_payload.json` 15 | * `/sat_refs/zhou_original_sat.json` 16 | 17 | ### Hold on where do I find all these files? 18 | [New file structure](https://drive.google.com/open?id=1CQP91ySWmHOgwE4s4TaXmAkO5aoH4krC) 19 | 20 | 21 | [Original file dataflow](https://drive.google.com/open?id=18GtxUUbO9V40Ifl_81Cpz0z-GL1XkV4R) 22 | 23 | 24 | -------------------------------------------------------------------------------- /inputs/cases/circinus_zhou_5_sats/constellation_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "config_type": "constellation_config", 3 | "version-const_def": "0.0.1", 4 | "verbose_details": "https://github.mit.edu/star-lab/CIRCINUS/blob/SPRINT-restructuring-1/inputs/nom_sprint/constellation/README.md", 5 | "constellation_definition": { 6 | "version-const": "0.0.1", 7 | "constellation_params": { 8 | "num_satellites": 5, 9 | "sat_id_prefix": "S", 10 | "sat_ids": "duplicate,range_inclusive,0,4", 11 | "sat_id_order": "default", 12 | "_comments": [ 13 | "orbit_neighbor_direction_method specifies how to figure out which direction an orbit neighbor is in, for determining activity transition times. by_increasing_sat_index means that if the receive sat index is larger than tx sat index (i.e. further in sat_id_order list) then the crosslink is in an INCREASING direction", 14 | "" 15 | ], 16 | "intra-orbit_neighbor_direction_method": "by_increasing_sat_index", 17 | "orbit_params": { 18 | "sat_ids_by_orbit_name": { 19 | "orbit0": [ 20 | "S0", 21 | "S1", 22 | "S2" 23 | ], 24 | "orbit1": [ 25 | "S3", 26 | "S4", 27 | "S5" 28 | ] 29 | }, 30 | "sat_orbital_elems": [ 31 | { 32 | "sat_id": "S0", 33 | "def_type": "indv", 34 | "kepler_meananom": { 35 | "a_km": 7378, 36 | "e": 0, 37 | "i_deg": 97.86, 38 | "RAAN_deg": 0, 39 | "arg_per_deg": 0, 40 | "M_deg": 90 41 | }, 42 | "propagation_method": "matlab_delkep" 43 | }, 44 | { 45 | "sat_id": "S1", 46 | "def_type": "indv", 47 | "kepler_meananom": { 48 | "a_km": 7378, 49 | "e": 0, 50 | "i_deg": 97.86, 51 | "RAAN_deg": 0, 52 | "arg_per_deg": 0, 53 | "M_deg": 180 54 | }, 55 | "propagation_method": "matlab_delkep" 56 | }, 57 | { 58 | "sat_id": "S2", 59 | "def_type": "indv", 60 | "kepler_meananom": { 61 | "a_km": 7378, 62 | "e": 0, 63 | "i_deg": 97.86, 64 | "RAAN_deg": 0, 65 | "arg_per_deg": 0, 66 | "M_deg": 270 67 | }, 68 | "propagation_method": "matlab_delkep" 69 | }, 70 | { 71 | "sat_id": "S3", 72 | "def_type": "indv", 73 | "kepler_meananom": { 74 | "a_km": 7378, 75 | "e": 0, 76 | "i_deg": 83.86, 77 | "RAAN_deg": 0, 78 | "arg_per_deg": 0, 79 | "M_deg": 60 80 | }, 81 | "propagation_method": "matlab_delkep" 82 | }, 83 | { 84 | "sat_id": "S4", 85 | "def_type": "indv", 86 | "kepler_meananom": { 87 | "a_km": 7378, 88 | "e": 0, 89 | "i_deg": 83.86, 90 | "RAAN_deg": 0, 91 | "arg_per_deg": 0, 92 | "M_deg": 120 93 | }, 94 | "propagation_method": "matlab_delkep" 95 | } 96 | ] 97 | } 98 | }, 99 | "sat_ref_model_name": "zhou_original_sat" 100 | } 101 | } -------------------------------------------------------------------------------- /inputs/cases/circinus_zhou_5_sats/ground_station_network_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "config_title":"ground_station_network_config", 3 | "version-gsndef":"0.0.1", 4 | "verbose_details":"https://github.mit.edu/star-lab/CIRCINUS/blob/SPRINT-restructuring-1/inputs/nom_sprint/groundstation_network/README.md", 5 | 6 | "network_definition":{ 7 | "version-gsn":"0.0.1", 8 | 9 | "default_gs_ref_model_name":"zhou_original_gs", 10 | 11 | "gs_net_params":{ 12 | "num_stations": 4, 13 | "gs_network_name": "Zhou 2017 GS", 14 | "gs_network_version": "1", 15 | "elevation_cutoff_deg":10, 16 | "stations": [ 17 | {"id": "G0", "name": "Beijing","name_pretty": "Beijing 0","latitude_deg":40.0,"longitude_deg":116.0,"height_m":0,"comm_type":"Zhou_2017_dlnk"}, 18 | {"id": "G1", "name": "Kashi","name_pretty": "Kashi 1", "latitude_deg":39.5,"longitude_deg":76.0,"height_m":0,"comm_type":"Zhou_2017_dlnk"}, 19 | {"id": "G2", "name": "Sanya","name_pretty": "Sanya 2", "latitude_deg":18.0,"longitude_deg":109.5,"height_m":0,"comm_type":"Zhou_2017_dlnk"}, 20 | {"id": "G3", "name": "Xi'an","name_pretty": "Xi'an 3", "latitude_deg":34.0,"longitude_deg":108.0,"height_m":0,"comm_type":"Zhou_2017_dlnk"} 21 | ] 22 | }, 23 | "sim_gs_network_params": { 24 | "_comments":"TODO: Reevaluate the location of these params. (Should they go in the sim file? Or GP? I think they are describing the behavior of the network, so this should be ok)", 25 | "time_epsilon_s": 1, 26 | "gsn_ps_params" : { 27 | "_comments": [ 28 | "replan_release_wait_time_s simulates the amount of time required to actually run the global planner in real life. from the perspective of this code the global planner will run instantaneously. After it runs, the sim will wait this amount of time before making those plans available", 29 | "release_first_plans_immediately = True means that global planner will immediately make its first set of global plans available (they won't be queued up for release at a later time)", 30 | "6300 seconds is 105 minutes, about the length of an orbit at 1000 km altitude", 31 | "replan release time is conservative here" 32 | ], 33 | "replan_interval_s": 6300, 34 | "replan_release_wait_time_s": 60, 35 | "release_first_plans_immediately": true 36 | } 37 | } 38 | 39 | 40 | } 41 | 42 | 43 | } -------------------------------------------------------------------------------- /inputs/cases/circinus_zhou_5_sats/operational_profile_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "version":"0.0.1", 3 | "which_config":"operational_profile_config", 4 | "where_should_i_be":"inputs/cases/", 5 | "what_goes_here":"things that only matter to the choices to be made about the current case.", 6 | 7 | "ops_profile_params": { 8 | "obs_params": { 9 | "num_targets": 5, 10 | "target_set_name": "Zhou 2017 Missions", 11 | "target_set_version": "1", 12 | "target_set_id": "2018-4-14", 13 | "elevation_cutoff_deg":60, 14 | "targets": [ 15 | {"id": "targ0","name": "Himalaya","name_pretty": "obs0", "latitude_deg": 28.0, "longitude_deg": 87.0,"height_m": 0}, 16 | {"id": "targ1","name": "Mamiraus","name_pretty": "obs1", "latitude_deg": -2.0, "longitude_deg": -66.0,"height_m": 0}, 17 | {"id": "targ2","name": "Cape York","name_pretty": "obs2", "latitude_deg": -11.0, "longitude_deg": 142.5,"height_m": 0}, 18 | {"id": "targ3","name": "Alaska Coast","name_pretty": "obs3", "latitude_deg": 60.0, "longitude_deg": -148,"height_m": 0}, 19 | {"id": "targ4","name": "Greenland","name_pretty": "obs4", "latitude_deg": 69.0, "longitude_deg": -49,"height_m": 0} 20 | ] 21 | }, 22 | "link_disables": { 23 | "_comment": "The satellite and GS ids below will always be interpreted as strings. if the ids are specified as integers in other files, they will be considered the same if their string representation is the same", 24 | "dlnk_direc_disabled_gs_ID_by_sat_IDstr": { 25 | }, 26 | "xlnk_direc_disabled_xsat_ID_by_sat_IDstr": { 27 | } 28 | } 29 | 30 | } 31 | 32 | } -------------------------------------------------------------------------------- /inputs/cases/orig_circinus_zhou/README.md: -------------------------------------------------------------------------------- 1 | # Original CIRCINUS use-case 2 | 3 | ## Description of Original Zhou use-case: 4 | Cases are fundamentally defined by a constellation and set ground stations, and further specified by an operational profile which defines intended up-time, as well as targets; and by a simulation scenario which defines actual up-time and performance. The SPRINT zhou use case is one of several use cases demonstrated with the first version of CIRCINUS. 5 | 6 | ## Required Case-specific Configuration Files, in this directory: 7 | * `constellation_config.json` 8 | * `ground_station_network_config.json` 9 | * `operational_profile_config.json` 10 | * `sim_case_config.json` 11 | 12 | ## Further required in the model definition directory `inputs/reference_model_definitions`: 13 | * `/gs_refs/zhou_original_gs.json` 14 | * `/payload_refs/zhou_original_payload.json` 15 | * `/sat_refs/zhou_original_sat.json` 16 | 17 | ### Hold on where do I find all these files? 18 | [New file structure](https://drive.google.com/open?id=1CQP91ySWmHOgwE4s4TaXmAkO5aoH4krC) 19 | 20 | 21 | [Original file dataflow](https://drive.google.com/open?id=18GtxUUbO9V40Ifl_81Cpz0z-GL1XkV4R) 22 | 23 | 24 | -------------------------------------------------------------------------------- /inputs/cases/orig_circinus_zhou/ground_station_network_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "config_title":"ground_station_network_config", 3 | "version-gsndef":"0.0.1", 4 | "verbose_details":"https://github.mit.edu/star-lab/CIRCINUS/blob/SPRINT-restructuring-1/inputs/nom_sprint/groundstation_network/README.md", 5 | 6 | "network_definition":{ 7 | "version-gsn":"0.0.1", 8 | 9 | "default_gs_ref_model_name":"zhou_original_gs", 10 | 11 | "gs_net_params":{ 12 | "num_stations": 4, 13 | "gs_network_name": "Zhou 2017 GS", 14 | "gs_network_version": "1", 15 | "elevation_cutoff_deg":10, 16 | "stations": [ 17 | {"id": "G0", "name": "Beijing","name_pretty": "Beijing 0","latitude_deg":40.0,"longitude_deg":116.0,"height_m":0,"comm_type":"Zhou_2017_dlnk"}, 18 | {"id": "G1", "name": "Kashi","name_pretty": "Kashi 1", "latitude_deg":39.5,"longitude_deg":76.0,"height_m":0,"comm_type":"Zhou_2017_dlnk"}, 19 | {"id": "G2", "name": "Sanya","name_pretty": "Sanya 2", "latitude_deg":18.0,"longitude_deg":109.5,"height_m":0,"comm_type":"Zhou_2017_dlnk"}, 20 | {"id": "G3", "name": "Xi'an","name_pretty": "Xi'an 3", "latitude_deg":34.0,"longitude_deg":108.0,"height_m":0,"comm_type":"Zhou_2017_dlnk"} 21 | ] 22 | }, 23 | "sim_gs_network_params": { 24 | "_comments":"TODO: Reevaluate the location of these params. (Should they go in the sim file? Or GP? I think they are describing the behavior of the network, so this should be ok)", 25 | "time_epsilon_s": 1, 26 | "gsn_ps_params" : { 27 | "_comments": [ 28 | "replan_release_wait_time_s simulates the amount of time required to actually run the global planner in real life. from the perspective of this code the global planner will run instantaneously. After it runs, the sim will wait this amount of time before making those plans available", 29 | "release_first_plans_immediately = True means that global planner will immediately make its first set of global plans available (they won't be queued up for release at a later time)", 30 | "6300 seconds is 105 minutes, about the length of an orbit at 1000 km altitude", 31 | "replan release time is conservative here" 32 | ], 33 | "replan_interval_s": 6300, 34 | "replan_release_wait_time_s": 60, 35 | "release_first_plans_immediately": true 36 | } 37 | } 38 | 39 | 40 | } 41 | 42 | 43 | } -------------------------------------------------------------------------------- /inputs/cases/orig_circinus_zhou/operational_profile_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "version":"0.0.1", 3 | "which_config":"operational_profile_config", 4 | "where_should_i_be":"inputs/cases/", 5 | "what_goes_here":"things that only matter to the choices to be made about the current case.", 6 | 7 | "ops_profile_params": { 8 | "obs_params": { 9 | "num_targets": 5, 10 | "target_set_name": "Zhou 2017 Missions", 11 | "target_set_version": "1", 12 | "target_set_id": "2018-4-14", 13 | "elevation_cutoff_deg":60, 14 | "targets": [ 15 | {"id": "targ0","name": "Himalaya","name_pretty": "obs0", "latitude_deg": 28.0, "longitude_deg": 87.0,"height_m": 0}, 16 | {"id": "targ1","name": "Mamiraus","name_pretty": "obs1", "latitude_deg": -2.0, "longitude_deg": -66.0,"height_m": 0}, 17 | {"id": "targ2","name": "Cape York","name_pretty": "obs2", "latitude_deg": -11.0, "longitude_deg": 142.5,"height_m": 0}, 18 | {"id": "targ3","name": "Alaska Coast","name_pretty": "obs3", "latitude_deg": 60.0, "longitude_deg": -148,"height_m": 0}, 19 | {"id": "targ4","name": "Greenland","name_pretty": "obs4", "latitude_deg": 69.0, "longitude_deg": -49,"height_m": 0} 20 | ] 21 | }, 22 | "link_disables": { 23 | "_comment": "The satellite and GS ids below will always be interpreted as strings. if the ids are specified as integers in other files, they will be considered the same if their string representation is the same", 24 | "dlnk_direc_disabled_gs_ID_by_sat_IDstr": { 25 | }, 26 | "xlnk_direc_disabled_xsat_ID_by_sat_IDstr": { 27 | } 28 | } 29 | 30 | } 31 | 32 | } -------------------------------------------------------------------------------- /inputs/cases/sprint_lp_demo/constellation_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "config_type": "constellation_config", 3 | "version-const_def": "0.0.1", 4 | "verbose_details": "https://github.mit.edu/star-lab/CIRCINUS/blob/SPRINT-restructuring-1/inputs/nom_sprint/constellation/README.md", 5 | "constellation_definition": { 6 | "version-const": "0.0.1", 7 | "constellation_params": { 8 | "num_satellites": 3, 9 | "sat_id_prefix": "S", 10 | "sat_ids": "duplicate,range_inclusive,0,2", 11 | "sat_id_order": "default", 12 | "_comments": [ 13 | "orbit_neighbor_direction_method specifies how to figure out which direction an orbit neighbor is in, for determining activity transition times. by_increasing_sat_index means that if the receive sat index is larger than tx sat index (i.e. further in sat_id_order list) then the crosslink is in an INCREASING direction", 14 | "" 15 | ], 16 | "intra-orbit_neighbor_direction_method": "by_increasing_sat_index", 17 | "orbit_params": { 18 | "sat_ids_by_orbit_name": { 19 | "orbit0": [ 20 | "S0", 21 | "S1", 22 | "S2" 23 | ] 24 | }, 25 | "sat_orbital_elems": [ 26 | { 27 | "sat_id": "S0", 28 | "def_type": "indv", 29 | "kepler_meananom": { 30 | "a_km": 6777, 31 | "e": 0, 32 | "i_deg": 51.6, 33 | "RAAN_deg": 0, 34 | "arg_per_deg": 0, 35 | "M_deg": 60 36 | }, 37 | "propagation_method": "matlab_delkep" 38 | }, 39 | { 40 | "sat_id": "S1", 41 | "def_type": "indv", 42 | "kepler_meananom": { 43 | "a_km": 6777, 44 | "e": 0, 45 | "i_deg": 51.6, 46 | "RAAN_deg": 0, 47 | "arg_per_deg": 0, 48 | "M_deg": 30 49 | }, 50 | "propagation_method": "matlab_delkep" 51 | }, 52 | { 53 | "sat_id": "S2", 54 | "def_type": "indv", 55 | "kepler_meananom": { 56 | "a_km": 6777, 57 | "e": 0, 58 | "i_deg": 51.6, 59 | "RAAN_deg": 0, 60 | "arg_per_deg": 0, 61 | "M_deg": 0 62 | }, 63 | "propagation_method": "matlab_delkep" 64 | } 65 | ] 66 | } 67 | }, 68 | "sat_ref_model_name": "zhou_original_sat" 69 | } 70 | } -------------------------------------------------------------------------------- /inputs/cases/sprint_lp_demo/ground_station_network_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "config_title":"ground_station_network_config", 3 | "version-gsndef":"0.0.1", 4 | "verbose_details":"https://github.mit.edu/star-lab/CIRCINUS/blob/SPRINT-restructuring-1/inputs/nom_sprint/groundstation_network/README.md", 5 | 6 | "network_definition":{ 7 | "version-gsn":"0.0.1", 8 | 9 | "default_gs_ref_model_name":"zhou_original_gs", 10 | 11 | "gs_net_params":{ 12 | "num_stations": 1, 13 | "gs_network_name": "NASA NEN singleton", 14 | "gs_network_version": "1", 15 | "elevation_cutoff_deg":10, 16 | "stations": [ 17 | { 18 | "id" : "G0", 19 | "name" : "WFF", 20 | "name_pretty" : "Wallops Flight Facility", 21 | "latitude_deg" : 37.946089, 22 | "longitude_deg" : -75.460642, 23 | "height_m" : 0, 24 | "comm_type" : "Zhou_2017_dlnk" 25 | } 26 | ] 27 | }, 28 | "sim_gs_network_params": { 29 | "_comments":"TODO: Reevaluate the location of these params. (Should they go in the sim file? Or GP? I think they are describing the behavior of the network, so this should be ok)", 30 | "time_epsilon_s": 1, 31 | "gsn_ps_params" : { 32 | "_comments": [ 33 | "replan_release_wait_time_s simulates the amount of time required to actually run the global planner in real life. from the perspective of this code the global planner will run instantaneously. After it runs, the sim will wait this amount of time before making those plans available", 34 | "release_first_plans_immediately = True means that global planner will immediately make its first set of global plans available (they won't be queued up for release at a later time)", 35 | "6300 seconds is 105 minutes, about the length of an orbit at 1000 km altitude", 36 | "replan release time is conservative here" 37 | ], 38 | "replan_interval_s": 6300, 39 | "replan_release_wait_time_s": 60, 40 | "release_first_plans_immediately": true 41 | } 42 | } 43 | 44 | 45 | } 46 | 47 | 48 | } -------------------------------------------------------------------------------- /inputs/cases/sprint_lp_demo/operational_profile_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "version":"0.0.1", 3 | "which_config":"operational_profile_config", 4 | "where_should_i_be":"inputs/cases/", 5 | "what_goes_here":"things that only matter to the choices to be made about the current case.", 6 | 7 | "ops_profile_params": { 8 | "obs_params": { 9 | "num_targets": 6, 10 | "target_set_name": "Chesapeake Bay", 11 | "target_set_version": "1", 12 | "target_set_id": "CB_Test_1", 13 | "elevation_cutoff_deg":60, 14 | "targets": [ 15 | {"id": "targ0","name": "Bay 0", "name_pretty": "Bay 0", "latitude_deg": 37.983013, "longitude_deg": -75.429088,"height_m": 0}, 16 | {"id": "targ1","name": "Himalaya", "name_pretty": "Ocean 1", "latitude_deg": 37.910802, "longitude_deg": -75.470739,"height_m": 0}, 17 | {"id": "targ2","name": "Bay 1", "name_pretty": "Bay 1", "latitude_deg": 37.850126, "longitude_deg": -75.680622,"height_m": 0}, 18 | {"id": "targ3","name": "Bay 2", "name_pretty": "Bay 2", "latitude_deg": 37.388679, "longitude_deg": -75.972138,"height_m": 0}, 19 | {"id": "targ4","name": "Bay 3", "name_pretty": "Bay 3", "latitude_deg": 37.267298, "longitude_deg": -76.536600,"height_m": 0}, 20 | {"id": "targ5","name": "Norfolk", "name_pretty": "Nofolk", "latitude_deg": 36.897200, "longitude_deg": -76.334132,"height_m": 0} 21 | ] 22 | }, 23 | "link_disables": { 24 | "_comment": "The satellite and GS ids below will always be interpreted as strings. if the ids are specified as integers in other files, they will be considered the same if their string representation is the same", 25 | "dlnk_direc_disabled_gs_ID_by_sat_IDstr": { 26 | }, 27 | "xlnk_direc_disabled_xsat_ID_by_sat_IDstr": { 28 | } 29 | } 30 | 31 | } 32 | 33 | } -------------------------------------------------------------------------------- /inputs/cases/sprint_lp_demo/sim_case_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "version":"0.0.1", 3 | "which_config":"sim_case_config", 4 | "where_should_i_be":"inputs/cases/", 5 | "what_goes_here":"things that only matter to the simulation, or definition of time, that is relatively likely to vary per case. Things which vary for tweaks and will stay the same otherwise should go in /inputs/admin_config/sim_general_config.json instead", 6 | 7 | "scenario_params": { 8 | "start_utc": "2018-01-01T06:00:00.000000Z", 9 | "end_utc": "2018-01-01T09:00:00.000000Z", 10 | "use_crosslinks": true, 11 | "all_sats_same_time_system": true, 12 | 13 | "restore_pkl_name": "pickles/_.pkl", 14 | 15 | "sat_schedule_hotstart": true, 16 | 17 | "lookup_params": { 18 | "xlnk_range_rates" : { 19 | "_comment": "The names here should be different from built-in comm type names", 20 | "Zhou_2017_xlnk": { 21 | "range_units": "km", 22 | "rates_units": "Mbps", 23 | "interpolation_method": "floor", 24 | "range_rates_table": [ 25 | [0, 10] 26 | ] 27 | } 28 | }, 29 | "dlnk_range_rates" : { 30 | "_comment1": "The names here should be different from built-in comm type names", 31 | "_comment2": "they say this rate is a random distribution over {0,20,40} Mbps for each downlink timeslot. I'll just use the average...", 32 | "Zhou_2017_dlnk": { 33 | "range_units": "km", 34 | "rates_units": "Mbps", 35 | "interpolation_method": "floor", 36 | "range_rates_table": [ 37 | [0, 20] 38 | ] 39 | } 40 | } 41 | }, 42 | "sim_run_perturbations": { 43 | "do_inject_obs": true, 44 | "injected_observations": [ 45 | { 46 | "indx": 0, 47 | "end_utc": "2018-01-01T07:01:00.000000Z", 48 | "sat_id": "S1", 49 | "type": "hardcoded", 50 | "start_utc": "2018-01-01T07:00:00.000000Z" 51 | } 52 | ], 53 | "schedule_disruptions": { 54 | "_comment": "each key is the global UID of a sim agent, time windows correspond to outage periods", 55 | "G0": [["2018-01-01T06:00:00.000000Z","2018-01-01T08:07:30.000000Z"]] 56 | } 57 | } 58 | 59 | } 60 | } -------------------------------------------------------------------------------- /inputs/cases/walker15_inc30/README.md: -------------------------------------------------------------------------------- 1 | # Original CIRCINUS use-case 2 | 3 | ## Description of Original Zhou use-case: 4 | Cases are fundamentally defined by a constellation and set ground stations, and further specified by an operational profile which defines intended up-time, as well as targets; and by a simulation scenario which defines actual up-time and performance. The SPRINT zhou use case is one of several use cases demonstrated with the first version of CIRCINUS. 5 | 6 | ## Required Case-specific Configuration Files, in this directory: 7 | * `constellation_config.json` 8 | * `ground_station_network_config.json` 9 | * `operational_profile_config.json` 10 | * `sim_case_config.json` 11 | 12 | ## Further required in the model definition directory `inputs/reference_model_definitions`: 13 | * `/gs_refs/zhou_original_gs.json` 14 | * `/payload_refs/zhou_original_payload.json` 15 | * `/sat_refs/zhou_original_sat.json` 16 | 17 | ### Hold on where do I find all these files? 18 | [New file structure](https://drive.google.com/open?id=1CQP91ySWmHOgwE4s4TaXmAkO5aoH4krC) 19 | 20 | 21 | [Original file dataflow](https://drive.google.com/open?id=18GtxUUbO9V40Ifl_81Cpz0z-GL1XkV4R) 22 | 23 | 24 | -------------------------------------------------------------------------------- /inputs/cases/walker15_inc30/autogen_files/README.md: -------------------------------------------------------------------------------- 1 | # Autogenerated (Intermediate) files 2 | 3 | These are generated automatically by circinus modules and used as input for further modules. Some are very large, and only minimally human readable. This folder is empty other than this readme until the pipeline is run. 4 | 5 | ## Expected files to be generated: 6 | * data_rates_output.json : [ runner_orbitlink.py -> runner_const_sim.py ] 7 | * orbit_prop_data.json : [ runner_orbitprop.py -> runner_orbitviz.py ] 8 | * sat_link_history.json : [ runner_orbitlink.py -> runner_orbitviz.py ] 9 | * const_sim_outputs.json : [ runner_const_sim.py -> ] 10 | 11 | [Original file dataflow](https://drive.google.com/open?id=18GtxUUbO9V40Ifl_81Cpz0z-GL1XkV4R) -------------------------------------------------------------------------------- /inputs/cases/walker15_inc30/constellation_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "config_type": "constellation_config", 3 | "version-const_def": "0.0.1", 4 | "verbose_details": "https://github.mit.edu/star-lab/CIRCINUS/blob/SPRINT-restructuring-1/inputs/nom_sprint/constellation/README.md", 5 | "constellation_definition": { 6 | "version-const": "0.0.1", 7 | "constellation_params": { 8 | "num_satellites": 15, 9 | "sat_id_prefix": "S", 10 | "sat_ids": "duplicate,range_inclusive,0,14", 11 | "sat_id_order": "default", 12 | "_comments": [ 13 | "orbit_neighbor_direction_method specifies how to figure out which direction an orbit neighbor is in, for determining activity transition times. by_increasing_sat_index means that if the receive sat index is larger than tx sat index (i.e. further in sat_id_order list) then the crosslink is in an INCREASING direction", 14 | "" 15 | ], 16 | "intra-orbit_neighbor_direction_method": "by_increasing_sat_index", 17 | "orbit_params": { 18 | "sat_ids_by_orbit_name": { 19 | "orbit0": [ 20 | "S0", 21 | "S1", 22 | "S2", 23 | "S3", 24 | "S4" 25 | ], 26 | "orbit1": [ 27 | "S5", 28 | "S6", 29 | "S7", 30 | "S8", 31 | "S9" 32 | ], 33 | "orbit2": [ 34 | "S10", 35 | "S11", 36 | "S12", 37 | "S13", 38 | "S14" 39 | ] 40 | }, 41 | "sat_orbital_elems": [ 42 | { 43 | "sat_id_prefix": "S", 44 | "sat_ids": "synthesize,range_inclusive,0,14", 45 | "def_type": "walker", 46 | "walker": { 47 | "num_sats": 15, 48 | "i_deg": 30, 49 | "num_planes": 3, 50 | "f_relative_spacing": 1, 51 | "a_km": 6978, 52 | "RAAN_p1_deg": 0, 53 | "M_p1_deg": 0 54 | }, 55 | "propagation_method": "matlab_delkep" 56 | } 57 | ] 58 | } 59 | }, 60 | "sat_ref_model_name": "zhou_original_sat" 61 | } 62 | } -------------------------------------------------------------------------------- /inputs/cases/walker15_inc30/ground_station_network_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "config_title":"ground_station_network_config", 3 | "version-gsndef":"0.0.1", 4 | "verbose_details":"https://github.mit.edu/star-lab/CIRCINUS/blob/SPRINT-restructuring-1/inputs/nom_sprint/groundstation_network/README.md", 5 | 6 | "network_definition":{ 7 | "version-gsn":"0.0.1", 8 | 9 | "default_gs_ref_model_name":"zhou_original_gs", 10 | 11 | "gs_net_params":{ 12 | "num_stations": 17, 13 | "gs_network_name": "Space Flight Networks 2017", 14 | "gs_network_version": "1", 15 | "_comment": "setting this to 20 deg to be conservative", 16 | "elevation_cutoff_deg":20, 17 | "stations": [ 18 | {"id": "G0", "name": "Prudhoe Bay","name_pretty": "Prudhoe Bay 0","latitude_deg":70.36621,"longitude_deg":-148.745529,"height_m":0,"comm_type":"Zhou_2017_dlnk"}, 19 | {"id": "G1", "name": "Fairbanks","name_pretty": "Fairbanks 1","latitude_deg":64.836531,"longitude_deg":-147.651745,"height_m":0,"comm_type":"Zhou_2017_dlnk"}, 20 | {"id": "G2", "name": "Seattle","name_pretty": "Seattle 2","latitude_deg":47.606,"longitude_deg":-122.33,"height_m":0,"comm_type":"Zhou_2017_dlnk"}, 21 | {"id": "G3", "name": "New Mexico","name_pretty": "New Mexico 3","latitude_deg":32.7872,"longitude_deg":-106.3257,"height_m":0,"comm_type":"Zhou_2017_dlnk"}, 22 | {"id": "G4", "name": "New England","name_pretty": "New England 4","latitude_deg":42.94235,"longitude_deg":-71.636095,"height_m":0,"comm_type":"Zhou_2017_dlnk"}, 23 | {"id": "G5", "name": "Hawaii","name_pretty": "Hawaii 5","latitude_deg":19.8968,"longitude_deg":-155.5828,"height_m":0,"comm_type":"Zhou_2017_dlnk"}, 24 | {"id": "G6", "name": "Florida","name_pretty": "Florida 6","latitude_deg":26.7542,"longitude_deg":-80.9337,"height_m":0,"comm_type":"Zhou_2017_dlnk"}, 25 | {"id": "G7", "name": "Argentina","name_pretty": "Argentina 7","latitude_deg":-53.1638,"longitude_deg":-70.9171,"height_m":0,"comm_type":"Zhou_2017_dlnk"}, 26 | {"id": "G8", "name": "Brazil","name_pretty": "Brazil 8","latitude_deg":-18.415921,"longitude_deg":-45.633627,"height_m":0,"comm_type":"Zhou_2017_dlnk"}, 27 | {"id": "G9", "name": "Munich","name_pretty": "Munich 9","latitude_deg":48.1351,"longitude_deg":11.582,"height_m":0,"comm_type":"Zhou_2017_dlnk"}, 28 | {"id": "G10", "name": "Norway","name_pretty": "Norway 10","latitude_deg":67.316,"longitude_deg":14.777,"height_m":0,"comm_type":"Zhou_2017_dlnk"}, 29 | {"id": "G11", "name": "South Africa","name_pretty": "South Africa 11","latitude_deg":-25.89,"longitude_deg":27.6853,"height_m":0,"comm_type":"Zhou_2017_dlnk"}, 30 | {"id": "G12", "name": "Dubai","name_pretty": "Dubai 12","latitude_deg":25.2048,"longitude_deg":55.2708,"height_m":0,"comm_type":"Zhou_2017_dlnk"}, 31 | {"id": "G13", "name": "Singapore","name_pretty": "Singapore 13","latitude_deg":1.3521,"longitude_deg":103.8198,"height_m":0,"comm_type":"Zhou_2017_dlnk"}, 32 | {"id": "G14", "name": "Guam","name_pretty": "Guam 14","latitude_deg":13.4443,"longitude_deg":144.7937,"height_m":0,"comm_type":"Zhou_2017_dlnk"}, 33 | {"id": "G15", "name": "Japan","name_pretty": "Japan 15","latitude_deg":37.516871,"longitude_deg":139.666454,"height_m":0,"comm_type":"Zhou_2017_dlnk"}, 34 | {"id": "G16", "name": "New Zealand","name_pretty": "New Zealand 16","latitude_deg":-46.512945,"longitude_deg":168.375952,"height_m":0,"comm_type":"Zhou_2017_dlnk"} 35 | ] 36 | }, 37 | "sim_gs_network_params": { 38 | "_comments":"TODO: Reevaluate the location of these params. (Should they go in the sim file? Or GP? I think they are describing the behavior of the network, so this should be ok)", 39 | "time_epsilon_s": 1, 40 | "gsn_ps_params" : { 41 | "_comments": [ 42 | "replan_release_wait_time_s simulates the amount of time required to actually run the global planner in real life. from the perspective of this code the global planner will run instantaneously. After it runs, the sim will wait this amount of time before making those plans available", 43 | "release_first_plans_immediately = True means that global planner will immediately make its first set of global plans available (they won't be queued up for release at a later time)", 44 | "6300 seconds is 105 minutes, about the length of an orbit at 1000 km altitude", 45 | "replan release time is conservative here" 46 | ], 47 | "replan_interval_s": 6300, 48 | "replan_release_wait_time_s": 60, 49 | "release_first_plans_immediately": true 50 | } 51 | } 52 | 53 | 54 | } 55 | 56 | 57 | } -------------------------------------------------------------------------------- /inputs/cases/walker15_inc30/sim_case_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": "0.0.1", 3 | "which_config": "sim_case_config", 4 | "where_should_i_be": "inputs/cases/", 5 | "what_goes_here": "things that only matter to the simulation, or definition of time, that is relatively likely to vary per case. Things which vary for tweaks and will stay the same otherwise should go in /inputs/admin_config/sim_general_config.json instead", 6 | "scenario_params": { 7 | "start_utc": "2018-01-18T00:00:00.000000Z", 8 | "end_utc": "2018-01-18T06:00:00.000000Z", 9 | "use_crosslinks": true, 10 | "all_sats_same_time_system": true, 11 | "restore_pkl_name": "pickles/sim_checkpoint_2016_02_14T11_45_00.pkl", 12 | "sat_schedule_hotstart": true, 13 | "lookup_params": { 14 | "xlnk_range_rates": { 15 | "_comment": "The names here should be different from built-in comm type names", 16 | "Zhou_2017_xlnk": { 17 | "range_units": "km", 18 | "rates_units": "Mbps", 19 | "interpolation_method": "floor", 20 | "range_rates_table": [ 21 | [ 22 | 0, 23 | 10 24 | ] 25 | ] 26 | } 27 | }, 28 | "dlnk_range_rates": { 29 | "_comment1": "The names here should be different from built-in comm type names", 30 | "_comment2": "they say this rate is a random distribution over {0,20,40} Mbps for each downlink timeslot. I'll just use the average...", 31 | "Zhou_2017_dlnk": { 32 | "range_units": "km", 33 | "rates_units": "Mbps", 34 | "interpolation_method": "floor", 35 | "range_rates_table": [ 36 | [ 37 | 0, 38 | 20 39 | ] 40 | ] 41 | } 42 | } 43 | }, 44 | "sim_run_perturbations": { 45 | "do_inject_obs": false, 46 | "schedule_disruptions": { 47 | "G5": [ 48 | [ 49 | "2016-02-14T04:00:00.000000Z", 50 | "2016-02-14T16:00:00.000000Z" 51 | ] 52 | ] 53 | }, 54 | "injected_observations": [ 55 | { 56 | "sat_id": "S3", 57 | "start_utc": "2018-01-18T05:00:00.000000Z", 58 | "end_utc": "2018-01-18T05:01:00.000000Z", 59 | "type": "hardcoded" 60 | }, 61 | { 62 | "sat_id": "S5", 63 | "start_utc": "2018-01-18T05:20:00.000000Z", 64 | "end_utc": "2018-01-18T05:21:00.000000Z", 65 | "type": "hardcoded" 66 | } 67 | ] 68 | } 69 | } 70 | } -------------------------------------------------------------------------------- /inputs/cases/walker18_inc30_simple/README.md: -------------------------------------------------------------------------------- 1 | # Original CIRCINUS use-case 2 | 3 | ## Description of Original Zhou use-case: 4 | Cases are fundamentally defined by a constellation and set ground stations, and further specified by an operational profile which defines intended up-time, as well as targets; and by a simulation scenario which defines actual up-time and performance. The SPRINT zhou use case is one of several use cases demonstrated with the first version of CIRCINUS. 5 | 6 | ## Required Case-specific Configuration Files, in this directory: 7 | * `constellation_config.json` 8 | * `ground_station_network_config.json` 9 | * `operational_profile_config.json` 10 | * `sim_case_config.json` 11 | 12 | ## Further required in the model definition directory `inputs/reference_model_definitions`: 13 | * `/gs_refs/zhou_original_gs.json` 14 | * `/payload_refs/zhou_original_payload.json` 15 | * `/sat_refs/zhou_original_sat.json` 16 | 17 | ### Hold on where do I find all these files? 18 | [New file structure](https://drive.google.com/open?id=1CQP91ySWmHOgwE4s4TaXmAkO5aoH4krC) 19 | 20 | 21 | [Original file dataflow](https://drive.google.com/open?id=18GtxUUbO9V40Ifl_81Cpz0z-GL1XkV4R) 22 | 23 | 24 | -------------------------------------------------------------------------------- /inputs/cases/walker18_inc30_simple/autogen_files/README.md: -------------------------------------------------------------------------------- 1 | # Autogenerated (Intermediate) files 2 | 3 | These are generated automatically by circinus modules and used as input for further modules. Some are very large, and only minimally human readable. This folder is empty other than this readme until the pipeline is run. 4 | 5 | ## Expected files to be generated: 6 | * data_rates_output.json : [ runner_orbitlink.py -> runner_const_sim.py ] 7 | * orbit_prop_data.json : [ runner_orbitprop.py -> runner_orbitviz.py ] 8 | * sat_link_history.json : [ runner_orbitlink.py -> runner_orbitviz.py ] 9 | * const_sim_outputs.json : [ runner_const_sim.py -> ] 10 | 11 | [Original file dataflow](https://drive.google.com/open?id=18GtxUUbO9V40Ifl_81Cpz0z-GL1XkV4R) -------------------------------------------------------------------------------- /inputs/cases/walker18_inc30_simple/constellation_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "config_type": "constellation_config", 3 | "version-const_def": "0.0.1", 4 | "verbose_details": "https://github.mit.edu/star-lab/CIRCINUS/blob/SPRINT-restructuring-1/inputs/nom_sprint/constellation/README.md", 5 | "constellation_definition": { 6 | "version-const": "0.0.1", 7 | "constellation_params": { 8 | "num_satellites": 18, 9 | "sat_id_prefix": "S", 10 | "sat_ids": "duplicate,range_inclusive,0,18", 11 | "sat_id_order": "default", 12 | "_comments": [ 13 | "orbit_neighbor_direction_method specifies how to figure out which direction an orbit neighbor is in, for determining activity transition times. by_increasing_sat_index means that if the receive sat index is larger than tx sat index (i.e. further in sat_id_order list) then the crosslink is in an INCREASING direction", 14 | "" 15 | ], 16 | "intra-orbit_neighbor_direction_method": "by_increasing_sat_index", 17 | "orbit_params": { 18 | "sat_ids_by_orbit_name": { 19 | "orbit0": [ 20 | "S0", 21 | "S1", 22 | "S2", 23 | "S3", 24 | "S4", 25 | "S5" 26 | ], 27 | "orbit1": [ 28 | "S6", 29 | "S7", 30 | "S8", 31 | "S9", 32 | "S10", 33 | "S11" 34 | ], 35 | "orbit2": [ 36 | "S12", 37 | "S13", 38 | "S14", 39 | "S15", 40 | "S16", 41 | "S17" 42 | ] 43 | }, 44 | "sat_orbital_elems": [ 45 | { 46 | "sat_id_prefix": "S", 47 | "sat_ids": "synthesize,range_inclusive,0,18", 48 | "def_type": "walker", 49 | "walker": { 50 | "num_sats": 18, 51 | "i_deg": 30, 52 | "num_planes": 3, 53 | "f_relative_spacing": 1, 54 | "a_km": 6978, 55 | "RAAN_p1_deg": 0, 56 | "M_p1_deg": 0 57 | }, 58 | "propagation_method": "matlab_delkep" 59 | } 60 | ] 61 | } 62 | }, 63 | "sat_ref_model_name": "zhou_original_sat" 64 | } 65 | } -------------------------------------------------------------------------------- /inputs/cases/walker18_inc30_simple/operational_profile_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "version":"0.0.1", 3 | "which_config":"operational_profile_config", 4 | "where_should_i_be":"inputs/cases/", 5 | "what_goes_here":"things that only matter to the choices to be made about the current case.", 6 | 7 | "ops_profile_params": { 8 | "obs_params": { 9 | "num_targets": 20, 10 | "target_set_name": "targets_tropics_100.json (from CIRCINUS tools)", 11 | "target_set_version": "1", 12 | "target_set_id": "4", 13 | "elevation_cutoff_deg":60, 14 | "targets": [ 15 | {"id": "targ0","name": "midlat60 0","name_pretty": "obs0","latitude_deg": -24.0,"longitude_deg": -174.0,"height_m": 0}, 16 | {"id": "targ1","name": "midlat60 1","name_pretty": "obs1","latitude_deg": -24.0,"longitude_deg": -156.0,"height_m": 0}, 17 | {"id": "targ2","name": "midlat60 2","name_pretty": "obs2","latitude_deg": -24.0,"longitude_deg": -138.0,"height_m": 0}, 18 | {"id": "targ3","name": "midlat60 3","name_pretty": "obs3","latitude_deg": -24.0,"longitude_deg": -120.0,"height_m": 0}, 19 | {"id": "targ4","name": "midlat60 4","name_pretty": "obs4","latitude_deg": -24.0,"longitude_deg": -102.0,"height_m": 0}, 20 | {"id": "targ5","name": "midlat60 5","name_pretty": "obs5","latitude_deg": -24.0,"longitude_deg": -84.0,"height_m": 0}, 21 | {"id": "targ6","name": "midlat60 6","name_pretty": "obs6","latitude_deg": -24.0,"longitude_deg": -66.0,"height_m": 0}, 22 | {"id": "targ7","name": "midlat60 7","name_pretty": "obs7","latitude_deg": -24.0,"longitude_deg": -48.0,"height_m": 0}, 23 | {"id": "targ8","name": "midlat60 8","name_pretty": "obs8","latitude_deg": -24.0,"longitude_deg": -30.0,"height_m": 0}, 24 | {"id": "targ9","name": "midlat60 9","name_pretty": "obs9","latitude_deg": -24.0,"longitude_deg": -12.0,"height_m": 0}, 25 | {"id": "targ10","name": "midlat60 10","name_pretty": "obs10","latitude_deg": -24.0,"longitude_deg": 6.0,"height_m": 0}, 26 | {"id": "targ11","name": "midlat60 11","name_pretty": "obs11","latitude_deg": -24.0,"longitude_deg": 24.0,"height_m": 0}, 27 | {"id": "targ12","name": "midlat60 12","name_pretty": "obs12","latitude_deg": -24.0,"longitude_deg": 42.0,"height_m": 0}, 28 | {"id": "targ13","name": "midlat60 13","name_pretty": "obs13","latitude_deg": -24.0,"longitude_deg": 60.0,"height_m": 0}, 29 | {"id": "targ14","name": "midlat60 14","name_pretty": "obs14","latitude_deg": -24.0,"longitude_deg": 78.0,"height_m": 0}, 30 | {"id": "targ15","name": "midlat60 15","name_pretty": "obs15","latitude_deg": -24.0,"longitude_deg": 96.0,"height_m": 0}, 31 | {"id": "targ16","name": "midlat60 16","name_pretty": "obs16","latitude_deg": -24.0,"longitude_deg": 114.0,"height_m": 0}, 32 | {"id": "targ17","name": "midlat60 17","name_pretty": "obs17","latitude_deg": -24.0,"longitude_deg": 132.0,"height_m": 0}, 33 | {"id": "targ18","name": "midlat60 18","name_pretty": "obs18","latitude_deg": -24.0,"longitude_deg": 150.0,"height_m": 0}, 34 | {"id": "targ19","name": "midlat60 19","name_pretty": "obs19","latitude_deg": -24.0,"longitude_deg": 168.0,"height_m": 0} 35 | ] 36 | }, 37 | "link_disables": { 38 | "_comment": "The satellite and GS ids below will always be interpreted as strings. if the ids are specified as integers in other files, they will be considered the same if their string representation is the same", 39 | "dlnk_direc_disabled_gs_ID_by_sat_IDstr": { 40 | }, 41 | "xlnk_direc_disabled_xsat_ID_by_sat_IDstr": { 42 | } 43 | } 44 | 45 | } 46 | 47 | } -------------------------------------------------------------------------------- /inputs/cases/walker18_inc30_simple/sim_case_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": "0.0.1", 3 | "which_config": "sim_case_config", 4 | "where_should_i_be": "inputs/cases/", 5 | "what_goes_here": "things that only matter to the simulation, or definition of time, that is relatively likely to vary per case. Things which vary for tweaks and will stay the same otherwise should go in /inputs/admin_config/sim_general_config.json instead", 6 | "scenario_params": { 7 | "start_utc": "2018-01-18T00:00:00.000000Z", 8 | "end_utc": "2018-01-18T06:00:00.000000Z", 9 | "use_crosslinks": true, 10 | "all_sats_same_time_system": true, 11 | "restore_pkl_name": "pickles/sim_checkpoint_2016_02_14T11_45_00.pkl", 12 | "sat_schedule_hotstart": true, 13 | "lookup_params": { 14 | "xlnk_range_rates": { 15 | "_comment": "The names here should be different from built-in comm type names", 16 | "Zhou_2017_xlnk": { 17 | "range_units": "km", 18 | "rates_units": "Mbps", 19 | "interpolation_method": "floor", 20 | "range_rates_table": [ 21 | [ 22 | 0, 23 | 10 24 | ] 25 | ] 26 | } 27 | }, 28 | "dlnk_range_rates": { 29 | "_comment1": "The names here should be different from built-in comm type names", 30 | "_comment2": "they say this rate is a random distribution over {0,20,40} Mbps for each downlink timeslot. I'll just use the average...", 31 | "Zhou_2017_dlnk": { 32 | "range_units": "km", 33 | "rates_units": "Mbps", 34 | "interpolation_method": "floor", 35 | "range_rates_table": [ 36 | [ 37 | 0, 38 | 20 39 | ] 40 | ] 41 | } 42 | } 43 | }, 44 | "sim_run_perturbations": { 45 | "do_inject_obs": false, 46 | "schedule_disruptions": { 47 | "G1": [ 48 | [ 49 | "2018-01-18T04:00:00.000000Z", 50 | "2018-01-18T04:00:00.000000Z" 51 | ] 52 | ] 53 | }, 54 | "injected_observations": [ 55 | { 56 | "sat_id": "S3", 57 | "start_utc": "2018-01-18T05:00:00.000000Z", 58 | "end_utc": "2018-01-18T05:01:00.000000Z", 59 | "type": "hardcoded" 60 | }, 61 | { 62 | "sat_id": "S5", 63 | "start_utc": "2018-01-18T05:20:00.000000Z", 64 | "end_utc": "2018-01-18T05:21:00.000000Z", 65 | "type": "hardcoded" 66 | } 67 | ] 68 | } 69 | } 70 | } -------------------------------------------------------------------------------- /inputs/cases/walker30_inc30/README.md: -------------------------------------------------------------------------------- 1 | # Original CIRCINUS use-case 2 | 3 | ## Description of Original Zhou use-case: 4 | Cases are fundamentally defined by a constellation and set ground stations, and further specified by an operational profile which defines intended up-time, as well as targets; and by a simulation scenario which defines actual up-time and performance. The SPRINT zhou use case is one of several use cases demonstrated with the first version of CIRCINUS. 5 | 6 | ## Required Case-specific Configuration Files, in this directory: 7 | * `constellation_config.json` 8 | * `ground_station_network_config.json` 9 | * `operational_profile_config.json` 10 | * `sim_case_config.json` 11 | 12 | ## Further required in the model definition directory `inputs/reference_model_definitions`: 13 | * `/gs_refs/zhou_original_gs.json` 14 | * `/payload_refs/zhou_original_payload.json` 15 | * `/sat_refs/zhou_original_sat.json` 16 | 17 | ### Hold on where do I find all these files? 18 | [New file structure](https://drive.google.com/open?id=1CQP91ySWmHOgwE4s4TaXmAkO5aoH4krC) 19 | 20 | 21 | [Original file dataflow](https://drive.google.com/open?id=18GtxUUbO9V40Ifl_81Cpz0z-GL1XkV4R) 22 | 23 | 24 | -------------------------------------------------------------------------------- /inputs/cases/walker30_inc30/autogen_files/README.md: -------------------------------------------------------------------------------- 1 | # Autogenerated (Intermediate) files 2 | 3 | These are generated automatically by circinus modules and used as input for further modules. Some are very large, and only minimally human readable. This folder is empty other than this readme until the pipeline is run. 4 | 5 | ## Expected files to be generated: 6 | * data_rates_output.json : [ runner_orbitlink.py -> runner_const_sim.py ] 7 | * orbit_prop_data.json : [ runner_orbitprop.py -> runner_orbitviz.py ] 8 | * sat_link_history.json : [ runner_orbitlink.py -> runner_orbitviz.py ] 9 | * const_sim_outputs.json : [ runner_const_sim.py -> ] 10 | 11 | [Original file dataflow](https://drive.google.com/open?id=18GtxUUbO9V40Ifl_81Cpz0z-GL1XkV4R) -------------------------------------------------------------------------------- /inputs/cases/walker30_inc30/constellation_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "config_type": "constellation_config", 3 | "version-const_def": "0.0.1", 4 | "verbose_details": "https://github.mit.edu/star-lab/CIRCINUS/blob/SPRINT-restructuring-1/inputs/nom_sprint/constellation/README.md", 5 | "constellation_definition": { 6 | "version-const": "0.0.1", 7 | "constellation_params": { 8 | "num_satellites": 30, 9 | "sat_id_prefix": "S", 10 | "sat_ids": "duplicate,range_inclusive,0,29", 11 | "sat_id_order": "default", 12 | "_comments": [ 13 | "orbit_neighbor_direction_method specifies how to figure out which direction an orbit neighbor is in, for determining activity transition times. by_increasing_sat_index means that if the receive sat index is larger than tx sat index (i.e. further in sat_id_order list) then the crosslink is in an INCREASING direction", 14 | "" 15 | ], 16 | "intra-orbit_neighbor_direction_method": "by_increasing_sat_index", 17 | "orbit_params": { 18 | "sat_ids_by_orbit_name": { 19 | "orbit0": [ 20 | "S0", 21 | "S1", 22 | "S2", 23 | "S3", 24 | "S4", 25 | "S5", 26 | "S6", 27 | "S7", 28 | "S8", 29 | "S9" 30 | ], 31 | "orbit1": [ 32 | "S10", 33 | "S11", 34 | "S12", 35 | "S13", 36 | "S14", 37 | "S15", 38 | "S16", 39 | "S17", 40 | "S18", 41 | "S19" 42 | ], 43 | "orbit2": [ 44 | "S20", 45 | "S21", 46 | "S22", 47 | "S23", 48 | "S24", 49 | "S25", 50 | "S26", 51 | "S27", 52 | "S28", 53 | "S29" 54 | ] 55 | }, 56 | "sat_orbital_elems": [ 57 | { 58 | "sat_id_prefix": "S", 59 | "sat_ids": "synthesize,range_inclusive,0,29", 60 | "def_type": "walker", 61 | "walker": { 62 | "num_sats": 30, 63 | "i_deg": 30, 64 | "num_planes": 3, 65 | "f_relative_spacing": 1, 66 | "a_km": 6978, 67 | "RAAN_p1_deg": 0, 68 | "M_p1_deg": 0 69 | }, 70 | "propagation_method": "matlab_delkep" 71 | } 72 | ] 73 | } 74 | }, 75 | "sat_ref_model_name": "zhou_original_sat" 76 | } 77 | } -------------------------------------------------------------------------------- /inputs/cases/walker30_inc30/sim_case_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": "0.0.1", 3 | "which_config": "sim_case_config", 4 | "where_should_i_be": "inputs/cases/", 5 | "what_goes_here": "things that only matter to the simulation, or definition of time, that is relatively likely to vary per case. Things which vary for tweaks and will stay the same otherwise should go in /inputs/admin_config/sim_general_config.json instead", 6 | "scenario_params": { 7 | "start_utc": "2018-01-18T00:00:00.000000Z", 8 | "end_utc": "2018-01-18T06:00:00.000000Z", 9 | "use_crosslinks": true, 10 | "all_sats_same_time_system": true, 11 | "restore_pkl_name": "pickles/sim_checkpoint_2016_02_14T11_45_00.pkl", 12 | "sat_schedule_hotstart": true, 13 | "lookup_params": { 14 | "xlnk_range_rates": { 15 | "_comment": "The names here should be different from built-in comm type names", 16 | "Zhou_2017_xlnk": { 17 | "range_units": "km", 18 | "rates_units": "Mbps", 19 | "interpolation_method": "floor", 20 | "range_rates_table": [ 21 | [ 22 | 0, 23 | 10 24 | ] 25 | ] 26 | } 27 | }, 28 | "dlnk_range_rates": { 29 | "_comment1": "The names here should be different from built-in comm type names", 30 | "_comment2": "they say this rate is a random distribution over {0,20,40} Mbps for each downlink timeslot. I'll just use the average...", 31 | "Zhou_2017_dlnk": { 32 | "range_units": "km", 33 | "rates_units": "Mbps", 34 | "interpolation_method": "floor", 35 | "range_rates_table": [ 36 | [ 37 | 0, 38 | 20 39 | ] 40 | ] 41 | } 42 | } 43 | }, 44 | "sim_run_perturbations": { 45 | "do_inject_obs": false, 46 | "schedule_disruptions": { 47 | "G5": [ 48 | [ 49 | "2016-02-14T04:00:00.000000Z", 50 | "2016-02-14T16:00:00.000000Z" 51 | ] 52 | ] 53 | }, 54 | "injected_observations": [ 55 | { 56 | "sat_id": "S3", 57 | "start_utc": "2018-01-18T05:00:00.000000Z", 58 | "end_utc": "2018-01-18T05:01:00.000000Z", 59 | "type": "hardcoded" 60 | }, 61 | { 62 | "sat_id": "S5", 63 | "start_utc": "2018-01-18T05:20:00.000000Z", 64 | "end_utc": "2018-01-18T05:21:00.000000Z", 65 | "type": "hardcoded" 66 | } 67 | ] 68 | } 69 | } 70 | } -------------------------------------------------------------------------------- /inputs/cases/walker30_inc30_NEN/README.md: -------------------------------------------------------------------------------- 1 | # Original CIRCINUS use-case 2 | 3 | ## Description of Original Zhou use-case: 4 | Cases are fundamentally defined by a constellation and set ground stations, and further specified by an operational profile which defines intended up-time, as well as targets; and by a simulation scenario which defines actual up-time and performance. The SPRINT zhou use case is one of several use cases demonstrated with the first version of CIRCINUS. 5 | 6 | ## Required Case-specific Configuration Files, in this directory: 7 | * `constellation_config.json` 8 | * `ground_station_network_config.json` 9 | * `operational_profile_config.json` 10 | * `sim_case_config.json` 11 | 12 | ## Further required in the model definition directory `inputs/reference_model_definitions`: 13 | * `/gs_refs/zhou_original_gs.json` 14 | * `/payload_refs/zhou_original_payload.json` 15 | * `/sat_refs/zhou_original_sat.json` 16 | 17 | ### Hold on where do I find all these files? 18 | [New file structure](https://drive.google.com/open?id=1CQP91ySWmHOgwE4s4TaXmAkO5aoH4krC) 19 | 20 | 21 | [Original file dataflow](https://drive.google.com/open?id=18GtxUUbO9V40Ifl_81Cpz0z-GL1XkV4R) 22 | 23 | 24 | -------------------------------------------------------------------------------- /inputs/cases/walker30_inc30_NEN/constellation_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "config_type": "constellation_config", 3 | "version-const_def": "0.0.1", 4 | "verbose_details": "https://github.mit.edu/star-lab/CIRCINUS/blob/SPRINT-restructuring-1/inputs/nom_sprint/constellation/README.md", 5 | "constellation_definition": { 6 | "version-const": "0.0.1", 7 | "constellation_params": { 8 | "num_satellites": 30, 9 | "sat_id_prefix": "S", 10 | "sat_ids": "duplicate,range_inclusive,0,29", 11 | "sat_id_order": "default", 12 | "_comments": [ 13 | "orbit_neighbor_direction_method specifies how to figure out which direction an orbit neighbor is in, for determining activity transition times. by_increasing_sat_index means that if the receive sat index is larger than tx sat index (i.e. further in sat_id_order list) then the crosslink is in an INCREASING direction", 14 | "" 15 | ], 16 | "intra-orbit_neighbor_direction_method": "by_increasing_sat_index", 17 | "orbit_params": { 18 | "sat_ids_by_orbit_name": { 19 | "orbit0": [ 20 | "S0", 21 | "S1", 22 | "S2", 23 | "S3", 24 | "S4", 25 | "S5", 26 | "S6", 27 | "S7", 28 | "S8", 29 | "S9" 30 | ], 31 | "orbit1": [ 32 | "S10", 33 | "S11", 34 | "S12", 35 | "S13", 36 | "S14", 37 | "S15", 38 | "S16", 39 | "S17", 40 | "S18", 41 | "S19" 42 | ], 43 | "orbit2": [ 44 | "S20", 45 | "S21", 46 | "S22", 47 | "S23", 48 | "S24", 49 | "S25", 50 | "S26", 51 | "S27", 52 | "S28", 53 | "S29" 54 | ] 55 | }, 56 | "sat_orbital_elems": [ 57 | { 58 | "sat_id_prefix": "S", 59 | "sat_ids": "synthesize,range_inclusive,0,29", 60 | "def_type": "walker", 61 | "walker": { 62 | "num_sats": 30, 63 | "i_deg": 30, 64 | "num_planes": 3, 65 | "f_relative_spacing": 1, 66 | "a_km": 6978, 67 | "RAAN_p1_deg": 0, 68 | "M_p1_deg": 0 69 | }, 70 | "propagation_method": "matlab_delkep" 71 | } 72 | ] 73 | } 74 | }, 75 | "sat_ref_model_name": "zhou_original_sat" 76 | } 77 | } -------------------------------------------------------------------------------- /inputs/cases/walker30_inc30_NEN/sim_case_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "which_config": "sim_case_config", 3 | "where_should_i_be": "inputs/cases/", 4 | "what_goes_here": "things that only matter to the simulation, or definition of time, that is relatively likely to vary per case. Things which vary for tweaks and will stay the same otherwise should go in /inputs/admin_config/sim_general_config.json instead", 5 | "scenario_params": { 6 | "start_utc": "2018-01-18T00:00:00.000000Z", 7 | "end_utc": "2018-01-18T06:00:00.000000Z", 8 | "use_crosslinks": false, 9 | "all_sats_same_time_system": true, 10 | "restore_pkl_name": "pickles/sim_checkpoint_2016_02_14T11_45_00.pkl", 11 | "sat_schedule_hotstart": true, 12 | "lookup_params": { 13 | "xlnk_range_rates": { 14 | "_comment": "The names here should be different from built-in comm type names", 15 | "Zhou_2017_xlnk": { 16 | "range_units": "km", 17 | "rates_units": "Mbps", 18 | "interpolation_method": "floor", 19 | "range_rates_table": [ 20 | [ 21 | 0, 22 | 10 23 | ] 24 | ] 25 | } 26 | }, 27 | "dlnk_range_rates": { 28 | "_comment1": "The names here should be different from built-in comm type names", 29 | "_comment2": "they say this rate is a random distribution over {0,20,40} Mbps for each downlink timeslot. I'll just use the average...", 30 | "Zhou_2017_dlnk": { 31 | "range_units": "km", 32 | "rates_units": "Mbps", 33 | "interpolation_method": "floor", 34 | "range_rates_table": [ 35 | [ 36 | 0, 37 | 20 38 | ] 39 | ] 40 | } 41 | } 42 | }, 43 | "sim_run_perturbations": { 44 | "do_inject_obs": true, 45 | "injected_observations": [ 46 | { 47 | "indx": 0, 48 | "end_utc": "2016-02-14T09:55:37.164153Z", 49 | "sat_id": "S4", 50 | "type": "hardcoded", 51 | "start_utc": "2016-02-14T09:54:37.164153Z" 52 | } 53 | ] 54 | } 55 | } 56 | } -------------------------------------------------------------------------------- /inputs/failure_analysis.py: -------------------------------------------------------------------------------- 1 | # this file is for generating plots / outputs from 2 | # the json files in this folder 3 | import json 4 | import matplotlib.pyplot as plt 5 | import numpy as np 6 | import pandas as pd 7 | 8 | SRP_settings = [True, False] 9 | 10 | ## WALKER ## 11 | n_targs = 15 12 | total_targs = 100 13 | num_sats = 15 14 | #targ_subsets = [list(range(40,60)),list(range(0,total_targs,int(total_targs/n_targs)))] # first is all equatorial set, 2nd is spread out at all latitudes 15 | targ_subsets = [list(range(40,60))] # for 30 walker 16 | #GS_subsets = [[3,5,6,14],[13,14,15,3,4,5,6,8,12]] 17 | GS_subsets = [[3,5,6,14]] # for 30 walker 18 | ############ 19 | 20 | ## Zhou ## 21 | n_targs = 5 22 | num_sats = 6 23 | n_gs = 4 24 | #targ_subsets = [list(range(40,60)),list(range(0,total_targs,int(total_targs/n_targs)))] # first is all equatorial set, 2nd is spread out at all latitudes 25 | targ_subsets = [list(range(n_targs))] 26 | #GS_subsets = [[3,5,6,14],[13,14,15,3,4,5,6,8,12]] 27 | GS_subsets = [list(range(n_gs))] 28 | ########### 29 | 30 | data_folder = r".\multirun_tests" 31 | 32 | # grab all data 33 | all_data = {} 34 | # SELECT USE CASE to plot 35 | g_select = 0 36 | t_select = 0 37 | # LOAD DISRUPTED DATA SET 38 | GS_subset = GS_subsets[g_select] 39 | t_subset = targ_subsets[t_select] 40 | 41 | setting_name = 'setGS_%d_setT_%d' % (g_select,t_select) 42 | for SRP_setting in SRP_settings: 43 | 44 | GS_disruptions = [ 45 | None, 46 | "G%d" % GS_subset[1] 47 | ] 48 | for GS_disruption in GS_disruptions: 49 | scenario_name = 'WALKER_%d_SRP_Test_SRP_%s_GS_%s_%s' % (num_sats,SRP_setting, GS_disruption,setting_name) if GS_disruption else 'WALKER_%d_Nominal_%s' % (num_sats,setting_name) 50 | 51 | full_filename = data_folder + "\\" + scenario_name + ".json" 52 | with open(full_filename, "r") as jsonFile: 53 | all_data[scenario_name] = json.load(jsonFile) 54 | # modify names with white spaces and remove distinction between exec and non-exec 55 | all_data[scenario_name]['Num_Failures_by_Type'] = {**all_data[scenario_name]['Num_Failures_by_Type']['exec'], **all_data[scenario_name]['Num_Failures_by_Type']['non-exec']} 56 | #del all_data[scenario_name]['Num Failures by Type'] 57 | #all_data[scenario_name]['Percentage_of_Exec_Act_Failure_by_Act'] = all_data[scenario_name]['Percentage of Exec Act Failures by Act'] 58 | #del all_data[scenario_name]['Percentage of Exec Act Failures by Act'] 59 | 60 | 61 | # let's put the data in a more pandas friendly format 62 | 63 | for s_ind,scenario_name in enumerate(all_data.keys()): 64 | dataset = [] 65 | for f_ind,failure_name in enumerate(all_data[scenario_name]['Num_Failures_by_Type'].keys()): 66 | dataset.append([]) 67 | for act_type_failure_count in all_data[scenario_name]['Num_Failures_by_Type'][failure_name].values(): 68 | dataset[f_ind].append(act_type_failure_count) 69 | 70 | df = pd.DataFrame(dataset,index=all_data[scenario_name]['Num_Failures_by_Type'].keys(),columns=all_data[scenario_name]['Num_Failures_by_Type'][failure_name].keys()) 71 | df.to_csv(data_folder + scenario_name + '.txt') 72 | -------------------------------------------------------------------------------- /inputs/general_config/README.md: -------------------------------------------------------------------------------- 1 | # Admin Configuration Files 2 | 3 | General configuration files. GP & LP may be resorted back into those repositories. -------------------------------------------------------------------------------- /inputs/general_config/lp_general_params_inputs.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": "0.0.1", 3 | "which_config": "lp_general_params_inputs", 4 | "where_should_i_be": "inputs/general_config/", 5 | "what_goes_here": "Since we jammed the equiv into the gp_general params, this is the LP version. Again, these defaults needs to live in the LP with only mods, and those mods probably case specific.", 6 | "lp_wrapper_params": { 7 | "lp_params": { 8 | "_comments": [ 9 | "planning_leaving_flow_start_mins specifies the earliest time at which we can consider an outgoing (transmission) activity window to be available for re-routing with any data. this should be greater than the release time (replan_release_wait_time_s) for the satellite schedule arbiter, so that we don't choose too late to different data through a given activity window", 10 | "planning_horizon_fixed specifies how far ahead the local planner should look" 11 | ], 12 | "planning_leaving_flow_start_mins": 1.1, 13 | "planning_horizon_mins": 210 14 | } 15 | }, 16 | "lp_general_params": { 17 | "_comments": [ 18 | "existing_utilization_epsilon is the extra utilization allowed for existing routes so that they don't miss the minimum required dv due to roundoff error. It also functions as a general round off precision bound. It should definitely be larger than the integer integer_feasibility_tolerance", 19 | "min_latency_for_sf_1_mins: this is the mimimum latency requirement for the highest latency score factor, 1.0. If multiple routes/dlnks for a single obs have latency less than this, they will both have sf 1.0" 20 | ], 21 | "verbose_milp": false, 22 | "use_self_replanner": true, 23 | "run_lp_milp_after_SRP": true, 24 | "dv_epsilon_Mb": 0.1, 25 | "inflow_dv_minimum_Mb": 5, 26 | "existing_utilization_epsilon": 0.001, 27 | "solver_name": "cbc", 28 | "solver_params": { 29 | "run_remotely": false, 30 | "max_runtime_s": 10000, 31 | "optimality_gap": 0.001, 32 | "integer_feasibility_tolerance": 1e-05, 33 | "gurobi": { 34 | "_helpful_links": [ 35 | "http://www.gurobi.com/documentation/7.5/refman/intfeastol.html#parameter:IntFeasTol", 36 | "http://www.gurobi.com/documentation/7.5/refman/mipgap2.html#parameter:MIPGap", 37 | "http://www.gurobi.com/documentation/7.5/refman/timelimit.html#parameter:TimeLimit" 38 | ] 39 | }, 40 | "cplex": { 41 | "_helpful_links": [ 42 | "https://www.ibm.com/support/knowledgecenter/SSSA5P_12.8.0/ilog.odms.cplex.help/CPLEX/Parameters/topics/introListAlpha.html" 43 | ] 44 | }, 45 | "cbc":{ 46 | "_helpful_links":[ 47 | "https://projects.coin-or.org/Cbc" 48 | ] 49 | }, 50 | "glpk":{ 51 | "_helpful_links":[ 52 | "https://www.gnu.org/software/glpk/" 53 | ] 54 | } 55 | }, 56 | "obj_weights": { 57 | "flow_dv": 1.0, 58 | "existing_flow_dv": 1.0, 59 | "existing_flow_indicators": 1.0, 60 | "injected_inflow_dv": 5, 61 | "injected_inflow_indicators": 0, 62 | "injected_obs_latency": 1, 63 | "energy_storage": 0 64 | }, 65 | "min_latency_for_sf_1_mins": 10, 66 | "latency_calculation": { 67 | "dlnk": "center", 68 | "obs": "center" 69 | } 70 | } 71 | } 72 | -------------------------------------------------------------------------------- /inputs/general_config/sim_general_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "config_title":"sim_general_config", 3 | "version-gencfg":"0.0.1", 4 | "verbose_details":"https://github.mit.edu/star-lab/CIRCINUS/blob/SPRINT-restructuring-1/", 5 | 6 | "general_sim_params":{ 7 | "timestep_s": 10.0, 8 | "matlab_verbose": true, 9 | "matlab_version": "MATLAB_R2018a", 10 | "include_ecef_output": false, 11 | "gs_time_epsilon_s": 1, 12 | "use_standalone_gp" : false, 13 | "rem_gp_server_address" : "localhost", 14 | "ground_server_address": "localhost", 15 | "_comment": ["put ip address of ground in ground_server_address"], 16 | 17 | "sim_run_params": { 18 | "restore_from_checkpoint": false, 19 | "pickle_checkpoints": false, 20 | "checkpoint_spacing_s": 900, 21 | "_comments": [ 22 | "the sim tick [now under timestep_s] should be larger than the minimum activity window length allowed by the GP for scheduling" 23 | ] 24 | }, 25 | "general_link_params": { 26 | "xlnk_max_len_s": 200, 27 | "dlnk_max_len_s": 1200, 28 | "dlnk_decimation": 2, 29 | "xlnk_decimation": 5, 30 | "assume_max_datarate": false, 31 | "include_xlnk_range_in_output": false, 32 | "include_dlnk_aer_in_output": false, 33 | "matlab_verbose_links": true 34 | }, 35 | "sim_plot_params": { 36 | "sat_acts_plot": { 37 | "time_units": "hours", 38 | "include_obs_labels": true, 39 | "include_xlnk_labels": false, 40 | "include_dlnk_labels": false 41 | }, 42 | "gs_acts_plot": { 43 | "include_labels": true, 44 | "time_units": "hours" 45 | }, 46 | "energy_usage_plot": { 47 | "plot_bound_e_min_Wh_delta": -1, 48 | "plot_bound_e_max_Wh_delta": 1, 49 | "show_min_max_bounds": true, 50 | "display_e_min_constraint": false, 51 | "display_e_max_constraint": false, 52 | "include_eclipse_windows": true, 53 | "time_units": "hours" 54 | }, 55 | "data_usage_plot": { 56 | "plot_bound_d_min_Gb_delta": -1, 57 | "plot_bound_d_max_Gb_delta": 1, 58 | "show_min_max_bounds": true, 59 | "display_d_min_constraint": false, 60 | "display_d_max_constraint": false, 61 | "include_eclipse_windows": true, 62 | "time_units": "hours" 63 | }, 64 | "failures_on_data_usage_plot": { 65 | "plot_bound_d_min_Gb_delta": -1, 66 | "plot_bound_d_max_Gb_delta": 1, 67 | "show_min_max_bounds": true, 68 | "display_d_min_constraint": false, 69 | "display_d_max_constraint": false, 70 | "time_units": "hours" 71 | }, 72 | "obs_aoi_plot" : { 73 | "plot_bound_min_aoi_hours": 0, 74 | "plot_bound_max_aoi_hours": 5, 75 | "x_axis_time_units": "hours" 76 | }, 77 | "sat_cmd_aoi_plot" : { 78 | "plot_bound_min_aoi_hours": 0, 79 | "plot_bound_max_aoi_hours": 2, 80 | "x_axis_time_units": "hours" 81 | }, 82 | "sat_tlm_aoi_plot" : { 83 | "plot_bound_min_aoi_hours": 0, 84 | "plot_bound_max_aoi_hours": 2, 85 | "x_axis_time_units": "hours" 86 | } 87 | }, 88 | "sim_metrics_params" : { 89 | "latency_calculation": { 90 | "dlnk": "center", 91 | "obs": "center" 92 | }, 93 | "targ_id_ignore_list" : [], 94 | "aoi_units": "hours" 95 | } 96 | } 97 | } 98 | -------------------------------------------------------------------------------- /inputs/reference_model_definitions/gs_refs/GEO_Cape.json: -------------------------------------------------------------------------------- 1 | { 2 | "version":"0.0.1", 3 | "which_config":"operational_profile_config", 4 | "where_should_i_be":"inputs/cases/", 5 | "what_goes_here":"things that only matter to the choices to be made about the current case.", 6 | 7 | "ops_profile_params": { 8 | "obs_params": { 9 | "num_targets": 19, 10 | "target_set_name": "GEO-CAPE Scenes", 11 | "target_set_version": "1", 12 | "target_set_id": "2019-2-20", 13 | "elevation_cutoff_deg":60, 14 | "_comment":"Scene numbers listed correspond to GEO-CAPE FR scenes. Lat/long correspond to the center of each scene.", 15 | "targets": [ 16 | {"id": "targ0", "name": "scene1", "name_pretty": "obs0", "latitude_deg": 47.9395, "longitude_deg": -126.8506, "height_m": 0}, 17 | {"id": "targ1", "name": "scene2", "name_pretty": "obs1", "latitude_deg": 43.4326, "longitude_deg": -127.9426, "height_m": 0}, 18 | {"id": "targ2", "name": "scene3", "name_pretty": "obs2", "latitude_deg": 36.8907, "longitude_deg": -121.5899, "height_m": 0}, 19 | {"id": "targ3", "name": "scene4", "name_pretty": "obs3", "latitude_deg": 31.8694, "longitude_deg": -119.7753, "height_m": 0}, 20 | {"id": "targ4", "name": "scene5", "name_pretty": "obs4", "latitude_deg": 26.9929, "longitude_deg": -95.3666, "height_m": 0}, 21 | {"id": "targ5", "name": "scene6", "name_pretty": "obs5", "latitude_deg": 28.3815, "longitude_deg": -89.9399, "height_m": 0}, 22 | {"id": "targ6", "name": "scene7", "name_pretty": "obs6", "latitude_deg": 27.7502, "longitude_deg": -84.8929, "height_m": 0}, 23 | {"id": "targ7", "name": "scene8", "name_pretty": "obs7", "latitude_deg": 30.3431, "longitude_deg": -72.8011, "height_m": 0}, 24 | {"id": "targ8", "name": "scene9", "name_pretty": "obs8", "latitude_deg": 30.7858, "longitude_deg": -79.1106, "height_m": 0}, 25 | {"id": "targ9", "name": "scene10", "name_pretty": "obs9", "latitude_deg": 24.7100, "longitude_deg": -77.3878, "height_m": 0}, 26 | {"id": "targ10", "name": "scene11", "name_pretty": "obs10", "latitude_deg": 34.9294, "longitude_deg": -69.5721, "height_m": 0}, 27 | {"id": "targ11", "name": "scene12", "name_pretty": "obs11", "latitude_deg": 43.4378, "longitude_deg": -74.9875, "height_m": 0}, 28 | {"id": "targ12", "name": "scene13", "name_pretty": "obs12", "latitude_deg": 44.9772, "longitude_deg": -83.2117, "height_m": 0}, 29 | {"id": "targ13", "name": "scene14", "name_pretty": "obs13", "latitude_deg": 45.7600, "longitude_deg": -87.0750, "height_m": 0}, 30 | {"id": "targ14", "name": "scene15", "name_pretty": "obs14", "latitude_deg": 22.2823, "longitude_deg": -94.9570, "height_m": 0}, 31 | {"id": "targ15", "name": "scene16", "name_pretty": "obs15", "latitude_deg": 42.4901, "longitude_deg": -64.4311, "height_m": 0}, 32 | {"id": "targ16", "name": "scene17", "name_pretty": "obs16", "latitude_deg": 35.4907, "longitude_deg": -75.4724, "height_m": 0}, 33 | {"id": "targ17", "name": "scene18", "name_pretty": "obs17", "latitude_deg": 24.4862, "longitude_deg": -82.5786, "height_m": 0}, 34 | {"id": "targ18", "name": "scene19", "name_pretty": "obs18", "latitude_deg": 41.7472, "longitude_deg": -68.6284, "height_m": 0} 35 | ] 36 | }, 37 | "link_disables": { 38 | "_comment": "The satellite and GS ids below will always be interpreted as strings. if the ids are specified as integers in other files, they will be considered the same if their string representation is the same", 39 | "dlnk_direc_disabled_gs_ID_by_sat_IDstr": { 40 | }, 41 | "xlnk_direc_disabled_xsat_ID_by_sat_IDstr": { 42 | } 43 | } 44 | } 45 | 46 | } -------------------------------------------------------------------------------- /inputs/reference_model_definitions/gs_refs/README.md: -------------------------------------------------------------------------------- 1 | # Ground Station Model Definitions 2 | 3 | In this directory, provide definition files for modeling different ground stations. Specific cases can reference or modify them (via the object created, don't mod this file from a case) as desired. 4 | 5 | A single definition, homogeneous monolithic network is the initial intent. 6 | 7 | ## Defined Groundstations: 8 | nominal_original_gs.json -------------------------------------------------------------------------------- /inputs/reference_model_definitions/gs_refs/Zhou_Original.json: -------------------------------------------------------------------------------- 1 | { 2 | "config_title": "ground_station_network_config", 3 | "version-gsndef": "0.0.1", 4 | "verbose_details": "https://github.mit.edu/star-lab/CIRCINUS/blob/SPRINT-restructuring-1/inputs/nom_sprint/groundstation_network/README.md", 5 | "network_definition": { 6 | "version-gsn": "0.0.1", 7 | "gs_net_params": { 8 | "num_stations": 4, 9 | "gs_network_name": "Zhou 2017 GS", 10 | "gs_network_version": "1", 11 | "elevation_cutoff_deg": 10, 12 | "stations": [ 13 | { 14 | "id": "G0", 15 | "name": "Beijing", 16 | "name_pretty": "Beijing 0", 17 | "latitude_deg": 40.0, 18 | "longitude_deg": 116.0, 19 | "height_m": 0, 20 | "comm_type": "" 21 | }, 22 | { 23 | "id": "G1", 24 | "name": "Kashi", 25 | "name_pretty": "Kashi 1", 26 | "latitude_deg": 39.5, 27 | "longitude_deg": 76.0, 28 | "height_m": 0, 29 | "comm_type": "" 30 | }, 31 | { 32 | "id": "G2", 33 | "name": "Sanya", 34 | "name_pretty": "Sanya 2", 35 | "latitude_deg": 18.0, 36 | "longitude_deg": 109.5, 37 | "height_m": 0, 38 | "comm_type": "" 39 | }, 40 | { 41 | "id": "G3", 42 | "name": "Xi'an", 43 | "name_pretty": "Xi'an 3", 44 | "latitude_deg": 34.0, 45 | "longitude_deg": 108.0, 46 | "height_m": 0, 47 | "comm_type": "" 48 | } 49 | ] 50 | }, 51 | "sim_gs_network_params": { 52 | "_comments": "TODO: Reevaluate the location of these params. (Should they go in the sim file? Or GP? I think they are describing the behavior of the network, so this should be ok)", 53 | "time_epsilon_s": 1, 54 | "gsn_ps_params": { 55 | "_comments": [ 56 | "replan_release_wait_time_s simulates the amount of time required to actually run the global planner in real life. from the perspective of this code the global planner will run instantaneously. After it runs, the sim will wait this amount of time before making those plans available", 57 | "release_first_plans_immediately = True means that global planner will immediately make its first set of global plans available (they won't be queued up for release at a later time)", 58 | "6300 seconds is 105 minutes, about the length of an orbit at 1000 km altitude", 59 | "replan release time is conservative here" 60 | ], 61 | "replan_interval_s": 6300, 62 | "replan_release_wait_time_s": 60, 63 | "release_first_plans_immediately": true 64 | } 65 | } 66 | } 67 | } 68 | -------------------------------------------------------------------------------- /inputs/reference_model_definitions/gs_refs/nen_nom_gs.json: -------------------------------------------------------------------------------- 1 | { 2 | "config_title":"gs_model_def", 3 | "version-gs_def":"0.0.1", 4 | "verbose_details":"", 5 | 6 | "gs_model_definition":{ 7 | "gs_type_name":"nen_nom_gs", 8 | "version-gs":"0.0.1", 9 | "description":"This defines a generic X-band groundstation that may be found in the NASA NEN. Specifics should be adjusted by the instance which refers to this model, by reassigning the fields which differ. https://sbir.gsfc.nasa.gov/sites/default/files/453-NENUG%20R2.pdf", 10 | 11 | "gs_model_params": { 12 | "_comment":"A 'typical' NEN groundstation using S-band for uplink and X-band for downlink, with approximately median parameters that can be adjusted in ", 13 | "time_epsilon_s" : 1, 14 | 15 | "type" : "parabolic", 16 | "diameter_m" : 10, 17 | "max_slew_degPerS" : 10, 18 | 19 | "transmitters":[ 20 | { 21 | "name":"S-band-RX", 22 | "TX_freq_MHz": { 23 | "min":2025, 24 | "max":2120 25 | }, 26 | "EIRP_dBWi":65, 27 | "freq_MHz" : -1, 28 | "bandwidth_MHz" : -1, 29 | "enabled" : true, 30 | "_comment":"A common TX band in NEN. A small minority of GS have a second TX band available. Actual freq MUST be set when instance made. Adjustments to generic model (actual range, etc) should be set as well if differs." 31 | } 32 | ], 33 | "receivers":[ 34 | { 35 | "name":"X-band-TX", 36 | "RX_freq_MHz": { 37 | "min":8025, 38 | "max":8500 39 | }, 40 | "G_over_T_dB":35, 41 | "freq_MHz" : -1, 42 | "bandwidth_MHz" : -1, 43 | "enabled" : true, 44 | "_comment":"A common X-band RX band in NEN. Most also have S-band available. Actual freq MUST be set when instance made. Adjustments to generic model (actual range, etc) should be set as well if differs." 45 | } 46 | ] 47 | 48 | }, 49 | 50 | 51 | "sim_gs_params": { 52 | "_comment": "currently params are same for every gs", 53 | "time_epsilon_s": 1 54 | } 55 | } 56 | } 57 | 58 | 59 | } -------------------------------------------------------------------------------- /inputs/reference_model_definitions/gs_refs/zhou_original_gs.json: -------------------------------------------------------------------------------- 1 | { 2 | "config_title":"gs_model_def", 3 | "version-gs_def":"0.0.1", 4 | "verbose_details":"https://github.mit.edu/star-lab/CIRCINUS/blob/SPRINT-restructuring-1/inputs/nom_sprint/groundstation_network/gs_model_defs/README.md", 5 | 6 | "gs_model_definition":{ 7 | "gs_type_name":"Zhou_2017_dlnk", 8 | "version-gs":"0.0.1", 9 | "description":"This is an aggregation of the gs-centric terms in the configuration files.", 10 | 11 | "sim_gs_params": { 12 | "_comment": "currently params are same for every gs", 13 | "time_epsilon_s": 1 14 | } 15 | } 16 | 17 | 18 | } -------------------------------------------------------------------------------- /inputs/reference_model_definitions/obs_refs/Chesapeake_Bay.json: -------------------------------------------------------------------------------- 1 | { 2 | "version":"0.0.1", 3 | "which_config":"operational_profile_config", 4 | "where_should_i_be":"inputs/cases/", 5 | "what_goes_here":"things that only matter to the choices to be made about the current case.", 6 | 7 | "ops_profile_params": { 8 | "obs_params": { 9 | "num_targets": 6, 10 | "target_set_name": "Chesapeake Bay", 11 | "target_set_version": "1", 12 | "target_set_id": "CB_Test_1", 13 | "elevation_cutoff_deg":60, 14 | "targets": [ 15 | {"id": "targ0","name": "Bay 0", "name_pretty": "Bay 0", "latitude_deg": 37.983013, "longitude_deg": -75.429088,"height_m": 0}, 16 | {"id": "targ1","name": "Himalaya", "name_pretty": "Ocean 1", "latitude_deg": 37.910802, "longitude_deg": -75.470739,"height_m": 0}, 17 | {"id": "targ2","name": "Bay 1", "name_pretty": "Bay 1", "latitude_deg": 37.850126, "longitude_deg": -75.680622,"height_m": 0}, 18 | {"id": "targ3","name": "Bay 2", "name_pretty": "Bay 2", "latitude_deg": 37.388679, "longitude_deg": -75.972138,"height_m": 0}, 19 | {"id": "targ4","name": "Bay 3", "name_pretty": "Bay 3", "latitude_deg": 37.267298, "longitude_deg": -76.536600,"height_m": 0}, 20 | {"id": "targ5","name": "Norfolk", "name_pretty": "Nofolk", "latitude_deg": 36.897200, "longitude_deg": -76.334132,"height_m": 0} 21 | ] 22 | }, 23 | "link_disables": { 24 | "_comment": "The satellite and GS ids below will always be interpreted as strings. if the ids are specified as integers in other files, they will be considered the same if their string representation is the same", 25 | "dlnk_direc_disabled_gs_ID_by_sat_IDstr": { 26 | }, 27 | "xlnk_direc_disabled_xsat_ID_by_sat_IDstr": { 28 | } 29 | } 30 | 31 | } 32 | 33 | } -------------------------------------------------------------------------------- /inputs/reference_model_definitions/obs_refs/Tropics_20.json: -------------------------------------------------------------------------------- 1 | { 2 | "version":"0.0.1", 3 | "which_config":"operational_profile_config", 4 | "where_should_i_be":"inputs/cases/", 5 | "what_goes_here":"things that only matter to the choices to be made about the current case.", 6 | 7 | "ops_profile_params": { 8 | "obs_params": { 9 | "num_targets": 20, 10 | "target_set_name": "targets_tropics_100.json (from CIRCINUS tools)", 11 | "target_set_version": "1", 12 | "target_set_id": "4", 13 | "elevation_cutoff_deg":60, 14 | "targets": [ 15 | {"id": "targ0","name": "midlat60 0","name_pretty": "obs0","latitude_deg": -24.0,"longitude_deg": -174.0,"height_m": 0}, 16 | {"id": "targ1","name": "midlat60 1","name_pretty": "obs1","latitude_deg": -24.0,"longitude_deg": -156.0,"height_m": 0}, 17 | {"id": "targ2","name": "midlat60 2","name_pretty": "obs2","latitude_deg": -24.0,"longitude_deg": -138.0,"height_m": 0}, 18 | {"id": "targ3","name": "midlat60 3","name_pretty": "obs3","latitude_deg": -24.0,"longitude_deg": -120.0,"height_m": 0}, 19 | {"id": "targ4","name": "midlat60 4","name_pretty": "obs4","latitude_deg": -24.0,"longitude_deg": -102.0,"height_m": 0}, 20 | {"id": "targ5","name": "midlat60 5","name_pretty": "obs5","latitude_deg": -24.0,"longitude_deg": -84.0,"height_m": 0}, 21 | {"id": "targ6","name": "midlat60 6","name_pretty": "obs6","latitude_deg": -24.0,"longitude_deg": -66.0,"height_m": 0}, 22 | {"id": "targ7","name": "midlat60 7","name_pretty": "obs7","latitude_deg": -24.0,"longitude_deg": -48.0,"height_m": 0}, 23 | {"id": "targ8","name": "midlat60 8","name_pretty": "obs8","latitude_deg": -24.0,"longitude_deg": -30.0,"height_m": 0}, 24 | {"id": "targ9","name": "midlat60 9","name_pretty": "obs9","latitude_deg": -24.0,"longitude_deg": -12.0,"height_m": 0}, 25 | {"id": "targ10","name": "midlat60 10","name_pretty": "obs10","latitude_deg": -24.0,"longitude_deg": 6.0,"height_m": 0}, 26 | {"id": "targ11","name": "midlat60 11","name_pretty": "obs11","latitude_deg": -24.0,"longitude_deg": 24.0,"height_m": 0}, 27 | {"id": "targ12","name": "midlat60 12","name_pretty": "obs12","latitude_deg": -24.0,"longitude_deg": 42.0,"height_m": 0}, 28 | {"id": "targ13","name": "midlat60 13","name_pretty": "obs13","latitude_deg": -24.0,"longitude_deg": 60.0,"height_m": 0}, 29 | {"id": "targ14","name": "midlat60 14","name_pretty": "obs14","latitude_deg": -24.0,"longitude_deg": 78.0,"height_m": 0}, 30 | {"id": "targ15","name": "midlat60 15","name_pretty": "obs15","latitude_deg": -24.0,"longitude_deg": 96.0,"height_m": 0}, 31 | {"id": "targ16","name": "midlat60 16","name_pretty": "obs16","latitude_deg": -24.0,"longitude_deg": 114.0,"height_m": 0}, 32 | {"id": "targ17","name": "midlat60 17","name_pretty": "obs17","latitude_deg": -24.0,"longitude_deg": 132.0,"height_m": 0}, 33 | {"id": "targ18","name": "midlat60 18","name_pretty": "obs18","latitude_deg": -24.0,"longitude_deg": 150.0,"height_m": 0}, 34 | {"id": "targ19","name": "midlat60 19","name_pretty": "obs19","latitude_deg": -24.0,"longitude_deg": 168.0,"height_m": 0} 35 | ] 36 | }, 37 | "link_disables": { 38 | "_comment": "The satellite and GS ids below will always be interpreted as strings. if the ids are specified as integers in other files, they will be considered the same if their string representation is the same", 39 | "dlnk_direc_disabled_gs_ID_by_sat_IDstr": { 40 | }, 41 | "xlnk_direc_disabled_xsat_ID_by_sat_IDstr": { 42 | } 43 | } 44 | 45 | } 46 | 47 | } 48 | -------------------------------------------------------------------------------- /inputs/reference_model_definitions/obs_refs/Zhou_2017.json: -------------------------------------------------------------------------------- 1 | { 2 | "version":"0.0.1", 3 | "which_config":"operational_profile_config", 4 | "where_should_i_be":"inputs/cases/", 5 | "what_goes_here":"things that only matter to the choices to be made about the current case.", 6 | 7 | "ops_profile_params": { 8 | "obs_params": { 9 | "num_targets": 5, 10 | "target_set_name": "Zhou 2017 Missions", 11 | "target_set_version": "1", 12 | "target_set_id": "2018-4-14", 13 | "elevation_cutoff_deg":60, 14 | "targets": [ 15 | {"id": "targ0","name": "Himalaya","name_pretty": "obs0", "latitude_deg": 28.0, "longitude_deg": 87.0,"height_m": 0}, 16 | {"id": "targ1","name": "Mamiraus","name_pretty": "obs1", "latitude_deg": -2.0, "longitude_deg": -66.0,"height_m": 0}, 17 | {"id": "targ2","name": "Cape York","name_pretty": "obs2", "latitude_deg": -11.0, "longitude_deg": 142.5,"height_m": 0}, 18 | {"id": "targ3","name": "Alaska Coast","name_pretty": "obs3", "latitude_deg": 60.0, "longitude_deg": -148,"height_m": 0}, 19 | {"id": "targ4","name": "Greenland","name_pretty": "obs4", "latitude_deg": 69.0, "longitude_deg": -49,"height_m": 0} 20 | ] 21 | }, 22 | "link_disables": { 23 | "_comment": "The satellite and GS ids below will always be interpreted as strings. if the ids are specified as integers in other files, they will be considered the same if their string representation is the same", 24 | "dlnk_direc_disabled_gs_ID_by_sat_IDstr": { 25 | }, 26 | "xlnk_direc_disabled_xsat_ID_by_sat_IDstr": { 27 | } 28 | } 29 | 30 | } 31 | 32 | } -------------------------------------------------------------------------------- /inputs/reference_model_definitions/obs_refs/blank.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": "0.0.1", 3 | "which_config": "operational_profile_config", 4 | "where_should_i_be": "inputs/cases/", 5 | "what_goes_here": "things that only matter to the choices to be made about the current case.", 6 | "ops_profile_params": { 7 | "obs_params": { 8 | "num_targets": [], 9 | "target_set_name": "blank, for generating. replace this with the description of the new observation set.", 10 | "target_set_id": "4", 11 | "elevation_cutoff_deg": 60, 12 | "targets": [] 13 | }, 14 | "link_disables": { 15 | "_comment": "The satellite and GS ids below will always be interpreted as strings. if the ids are specified as integers in other files, they will be considered the same if their string representation is the same", 16 | "dlnk_direc_disabled_gs_ID_by_sat_IDstr": {}, 17 | "xlnk_direc_disabled_xsat_ID_by_sat_IDstr": {} 18 | } 19 | } 20 | } -------------------------------------------------------------------------------- /inputs/reference_model_definitions/obs_refs/rem.py: -------------------------------------------------------------------------------- 1 | import json 2 | 3 | with open('blank.json','r+') as f: 4 | data = json.load(f) 5 | 6 | data['ops_profile_params']['obs_params']['targets'] = [] 7 | 8 | with open('blank.json','w') as f: 9 | json.dump(data, f, indent = 4) 10 | 11 | 12 | -------------------------------------------------------------------------------- /inputs/reference_model_definitions/payload_refs/README.md: -------------------------------------------------------------------------------- 1 | # Payload Model Definition 2 | 3 | In this directory, provide definition files for modeling different payload models. Specific satellite definitions can reference or modify them (via the object created, don't mod this file from a case) as desired. 4 | 5 | 6 | ## Defined Satellites: 7 | nominal_original_payload.json 8 | -------------------------------------------------------------------------------- /inputs/reference_model_definitions/payload_refs/tropics_payload.json: -------------------------------------------------------------------------------- 1 | { 2 | "config_type":"payload_model_def", 3 | "version-sat_def":"0.0.1", 4 | 5 | "payload_model_definition":{ 6 | "payload_type_name":"tropics_payload", 7 | "version-sat_type":"0.0.1", 8 | "description":"Contains the payload information. Not sure if this is used but just in case", 9 | 10 | "payload_params":{ 11 | "payload_data_rate_Mbps": 3, 12 | "power_consumption_W":{ 13 | "base":0, 14 | "obs":-10 15 | }, 16 | "min_duration_s": { 17 | "obs": 15 18 | } 19 | } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /inputs/reference_model_definitions/payload_refs/zhou_original_payload.json: -------------------------------------------------------------------------------- 1 | { 2 | "config_type":"payload_model_def", 3 | "version-sat_def":"0.0.1", 4 | 5 | "payload_model_definition":{ 6 | "payload_type_name":"zhou_original_payload", 7 | "version-sat_type":"0.0.1", 8 | "description":"Contains the payload information used in the original circinus.", 9 | 10 | "payload_params":{ 11 | "payload_data_rate_Mbps": 50, 12 | "power_consumption_W":{ 13 | "base":0, 14 | "obs":-10 15 | }, 16 | "min_duration_s": { 17 | "obs": 15 18 | } 19 | } 20 | } 21 | } -------------------------------------------------------------------------------- /inputs/reference_model_definitions/sat_refs/README.md: -------------------------------------------------------------------------------- 1 | # Satellite Model Definition 2 | 3 | In this directory, provide definition files for modeling different satellites. Specific cases can reference or modify them (via the object created, don't mod this file from a case) as desired. 4 | 5 | ## Defined Satellites: 6 | nominal_original_sat.json 7 | -------------------------------------------------------------------------------- /inputs/reference_model_definitions/sat_refs/tropics.json: -------------------------------------------------------------------------------- 1 | { 2 | "config_title": "sat_model_def", 3 | "version-sat_def": "0.0.1", 4 | "sat_model_definition": { 5 | "sat_type_name": "tropics", 6 | "sat_model_params": { 7 | "payload_def": { 8 | "definition": "local", 9 | "name": "tropics_pl", 10 | "payload_params": { 11 | "name": "tropics_pl", 12 | "payload_data_rate_Mbps": 60, 13 | "power_consumption_W": { 14 | "base": 0, 15 | "obs": -2 16 | }, 17 | "min_duration_s": { 18 | "obs": 15 19 | } 20 | } 21 | }, 22 | "power_params": { 23 | "power_consumption_W": { 24 | "base": -11.1, 25 | "dlnk": -20, 26 | "xlnk_tx": -20, 27 | "xlnk_rx": -5, 28 | "orbit_insunlight_average_charging": 20.8 29 | }, 30 | "battery_storage_Wh": { 31 | "e_min": 2.78, 32 | "e_max": 30, 33 | "charge_efficiency": 1, 34 | "discharge_efficiency": 1 35 | } 36 | }, 37 | "data_storage_params": { 38 | "d_min": 0, 39 | "d_max": 200 40 | }, 41 | "initial_state": { 42 | "batt_e_Wh": 30 43 | }, 44 | "activity_params": { 45 | "transition_time_s": { 46 | "inter-sat": 0, 47 | "dlnk-dlnk": 0, 48 | "intra-sat": { 49 | "obs-obs": 0, 50 | "obs-xlnk": 0, 51 | "obs-dlnk": 0, 52 | "dlnk-obs": 0, 53 | "dlnk-xlnk": 0, 54 | "dlnk-dlnk": 0, 55 | "xlnk-obs": 0, 56 | "xlnk-xlnk": { 57 | "intra-orbit,same direction": 0.0, 58 | "intra-orbit,different direction": 0.0, 59 | "intra to inter-orbit/inter to intra-orbit": 0.0, 60 | "inter-orbit,same orbit,same satellite": 0.0, 61 | "inter-orbit,same orbit,different satellite": 0.0, 62 | "inter-orbit,different orbit": 0.0 63 | }, 64 | "xlnk-dlnk": 0 65 | } 66 | }, 67 | "min_duration_s": { 68 | "dlnk": 60, 69 | "xlnk": 60 70 | } 71 | }, 72 | "sat_link_params": [ 73 | { 74 | "dlnk_params": { 75 | "HPBW_rad": 0.2, 76 | "P_tx_W": 0.5, 77 | "comm_type": { 78 | "built_in": false, 79 | "name": "Tropics_dlnk" 80 | } 81 | }, 82 | "xlnk_params": { 83 | "HPBW_rad": 0.2, 84 | "P_tx_W": 0.5, 85 | "comm_type": { 86 | "built_in": false, 87 | "name": "Tropics_xlnk" 88 | } 89 | }, 90 | "pointing_error_deg": 0.2, 91 | "dlnk_disallowed": {} 92 | } 93 | ] 94 | }, 95 | "sim_satellite_params": { 96 | "crosslink_new_plans_only_during_BDT": false, 97 | "dv_epsilon_Mb": 1, 98 | "time_epsilon_s": 1, 99 | "state_simulator": { 100 | "es_state_update": { 101 | "add_noise": 0, 102 | "noise_params": { 103 | "noise_type": "fractional_normal_edot", 104 | "average": 0, 105 | "std": 0.01, 106 | "min": 0.95, 107 | "max": 1.05 108 | } 109 | } 110 | }, 111 | "sat_schedule_arbiter_params": { 112 | "replan_release_wait_time_s": 0, 113 | "allow_lp_execution": true, 114 | "replan_interval_s": 900, 115 | "frac_dv_lost_for_activity_failure_threshold": 0.5 116 | } 117 | } 118 | } 119 | } 120 | -------------------------------------------------------------------------------- /inputs/reference_model_definitions/sat_refs/zhou_original_sat.json: -------------------------------------------------------------------------------- 1 | { 2 | "config_title": "sat_model_def", 3 | "version-sat_def": "0.0.1", 4 | "sat_model_definition": { 5 | "sat_type_name": "zhou_original_sat", 6 | "default_payload_ref_model_name":"zhou_original_payload", 7 | "sat_model_params": { 8 | "payload_def": { 9 | "definition": "local", 10 | "name": "zhou_original_payload", 11 | "payload_params": { 12 | "name": "zhou_original_payload", 13 | "payload_data_rate_Mbps": 50, 14 | "power_consumption_W": { 15 | "base": 0, 16 | "obs": -10 17 | }, 18 | "min_duration_s": { 19 | "obs": 15 20 | } 21 | } 22 | }, 23 | "power_params": { 24 | "power_consumption_W": { 25 | "base": -10, 26 | "dlnk": -20, 27 | "xlnk_tx": -20, 28 | "xlnk_rx": -5, 29 | "orbit_insunlight_average_charging": 30 30 | }, 31 | "battery_storage_Wh": { 32 | "e_min": 2.78, 33 | "e_max": 13.89, 34 | "charge_efficiency": 1, 35 | "discharge_efficiency": 1 36 | } 37 | }, 38 | "data_storage_params": { 39 | "d_min": 0, 40 | "d_max": 12 41 | }, 42 | "initial_state": { 43 | "batt_e_Wh": 12 44 | }, 45 | "activity_params": { 46 | "transition_time_s": { 47 | "inter-sat": 0, 48 | "dlnk-dlnk": 0, 49 | "intra-sat": { 50 | "obs-obs": 0, 51 | "obs-xlnk": 0, 52 | "obs-dlnk": 0, 53 | "dlnk-obs": 0, 54 | "dlnk-xlnk": 0, 55 | "dlnk-dlnk": 0, 56 | "xlnk-obs": 0, 57 | "xlnk-xlnk": { 58 | "intra-orbit,same direction": 0.0, 59 | "intra-orbit,different direction": 0.0, 60 | "intra to inter-orbit/inter to intra-orbit": 0.0, 61 | "inter-orbit,same orbit,same satellite": 0.0, 62 | "inter-orbit,same orbit,different satellite": 0.0, 63 | "inter-orbit,different orbit": 0.0 64 | }, 65 | "xlnk-dlnk": 0 66 | } 67 | }, 68 | "min_duration_s": { 69 | "dlnk": 60, 70 | "xlnk": 60 71 | } 72 | }, 73 | "sat_link_params": [ 74 | { 75 | "dlnk_params": { 76 | "HPBW_rad": 0.2, 77 | "P_tx_W": 0.5, 78 | "comm_type": { 79 | "built_in": false, 80 | "name": "Zhou_2017_dlnk" 81 | } 82 | }, 83 | "xlnk_params": { 84 | "HPBW_rad": 30, 85 | "P_tx_W": 1, 86 | "comm_type": { 87 | "built_in": false, 88 | "name": "Zhou_2017_xlnk" 89 | } 90 | }, 91 | "pointing_error_deg": 0.01, 92 | "dlnk_disallowed": {} 93 | } 94 | ] 95 | }, 96 | "sim_satellite_params": { 97 | "crosslink_new_plans_only_during_BDT": false, 98 | "dv_epsilon_Mb": 1, 99 | "time_epsilon_s": 1, 100 | "state_simulator": { 101 | "es_state_update": { 102 | "add_noise": 0, 103 | "noise_params": { 104 | "noise_type": "fractional_normal_edot", 105 | "average": 0, 106 | "std": 0.01, 107 | "min": 0.95, 108 | "max": 1.05 109 | } 110 | } 111 | }, 112 | "sat_schedule_arbiter_params": { 113 | "replan_release_wait_time_s": 0, 114 | "allow_lp_execution": 0, 115 | "replan_interval_s": 900, 116 | "frac_dv_lost_for_activity_failure_threshold": 0.5 117 | } 118 | } 119 | } 120 | } 121 | -------------------------------------------------------------------------------- /multirun_tests/SRP_Zhou_scripts/test_runner.py: -------------------------------------------------------------------------------- 1 | # this file is intended for setting up and running multiple SPRINT runs, where the config is changed 2 | # in between runs 3 | import json 4 | from subprocess import Popen 5 | # things to modify 6 | # r'..\inputs\reference_model_definitions\sat_refs\zhou_original_sat.json': NVM - only doing Xlnk-always 7 | 8 | # setup things to step through 9 | # r'..\inputs\cases\orig_circinus\zhou\sim_case_config.json': ['scenario_params']['sim_run_perturbations']['schedule_disruptions'] 10 | schedule_disruptions_list = [ 11 | {"G0": [["2016-02-14T04:00:00.000000Z","2016-02-15T04:00:00.000000Z"]]}, 12 | {"G1": [["2016-02-14T04:00:00.000000Z","2016-02-14T16:00:00.000000Z"]]}, 13 | {"G2": [["2016-02-14T04:00:00.000000Z","2016-02-15T04:00:00.000000Z"]]} 14 | ] 15 | 16 | # r'..\inputs\general_config\lp_general_params_inputs.json': ['lp_general_params']['use_self_replanner'] 17 | SRP_settings_list = [True, False] 18 | 19 | SD_file = r'C:\Users\User\circinusGit\SPRINT\inputs\cases\orig_circinus_zhou\sim_case_config.json' 20 | SRP_file = r'C:\Users\User\circinusGit\SPRINT\inputs\\general_config\lp_general_params_inputs.json' 21 | scripts_folder = r"C:\Users\User\circinusGit\SPRINT\scripts" 22 | # NOTE: NEED TO BE IN SCRIPTS DIRECTORY TO FIND windows_env_var_setup.bat 23 | for SD_setting in schedule_disruptions_list: 24 | 25 | with open(SD_file, "r") as jsonFile: 26 | data = json.load(jsonFile) 27 | 28 | data['scenario_params']['sim_run_perturbations']['schedule_disruptions'] = SD_setting 29 | 30 | print('Setting schedule disruptions to: %s' % SD_setting) 31 | with open(SD_file, "w") as jsonFile: 32 | json.dump(data, jsonFile, indent=4, separators=(',', ': ')) 33 | 34 | for SRP_setting in SRP_settings_list: 35 | with open(SRP_file, "r") as jsonFile: 36 | data = json.load(jsonFile) 37 | 38 | data['lp_general_params']['use_self_replanner'] = SRP_setting 39 | 40 | print('Setting SRP to: %s' % SRP_setting) 41 | with open(SRP_file, "w") as jsonFile: 42 | json.dump(data, jsonFile, indent=4, separators=(',', ': ')) 43 | 44 | print('New Settings Set - run batch file') 45 | 46 | # python runner_const_sim.py --inputs_location /c/Users/wcgru/Documents/GitHubClones/SPRINT/scripts/../inputs --case_name orig_circinus_zhou --restore_pickle "" --remote_debug false 47 | 48 | p = Popen(r"C:\Users\User\circinusGit\SPRINT\scripts\windows_launcher.bat") 49 | stdout, stderr = p.communicate() -------------------------------------------------------------------------------- /multirun_tests/failure_analysis.py: -------------------------------------------------------------------------------- 1 | # this file is for generating plots / outputs from 2 | # the json files in this folder 3 | import json 4 | import matplotlib.pyplot as plt 5 | import numpy as np 6 | import pandas as pd 7 | 8 | SRP_settings = [True, False] 9 | 10 | ## WALKER ## 11 | n_targs = 15 12 | total_targs = 100 13 | num_sats = 15 14 | #targ_subsets = [list(range(40,60)),list(range(0,total_targs,int(total_targs/n_targs)))] # first is all equatorial set, 2nd is spread out at all latitudes 15 | targ_subsets = [list(range(40,60))] # for 30 walker 16 | #GS_subsets = [[3,5,6,14],[13,14,15,3,4,5,6,8,12]] 17 | GS_subsets = [[3,5,6,14]] # for 30 walker 18 | ############ 19 | 20 | ## Zhou ## 21 | n_targs = 5 22 | num_sats = 6 23 | n_gs = 4 24 | #targ_subsets = [list(range(40,60)),list(range(0,total_targs,int(total_targs/n_targs)))] # first is all equatorial set, 2nd is spread out at all latitudes 25 | targ_subsets = [list(range(n_targs))] 26 | #GS_subsets = [[3,5,6,14],[13,14,15,3,4,5,6,8,12]] 27 | GS_subsets = [list(range(n_gs))] 28 | ########### 29 | 30 | data_folder = r".\multirun_tests" 31 | 32 | # grab all data 33 | all_data = {} 34 | # SELECT USE CASE to plot 35 | g_select = 0 36 | t_select = 0 37 | # LOAD DISRUPTED DATA SET 38 | GS_subset = GS_subsets[g_select] 39 | t_subset = targ_subsets[t_select] 40 | 41 | setting_name = 'setGS_%d_setT_%d' % (g_select,t_select) 42 | for SRP_setting in SRP_settings: 43 | 44 | GS_disruptions = [ 45 | None, 46 | "G%d" % GS_subset[1] 47 | ] 48 | for GS_disruption in GS_disruptions: 49 | scenario_name = 'WALKER_%d_SRP_Test_SRP_%s_GS_%s_%s' % (num_sats,SRP_setting, GS_disruption,setting_name) if GS_disruption else 'WALKER_%d_Nominal_%s' % (num_sats,setting_name) 50 | 51 | full_filename = data_folder + "\\" + scenario_name + ".json" 52 | with open(full_filename, "r") as jsonFile: 53 | all_data[scenario_name] = json.load(jsonFile) 54 | # modify names with white spaces and remove distinction between exec and non-exec 55 | all_data[scenario_name]['Num_Failures_by_Type'] = {**all_data[scenario_name]['Num_Failures_by_Type']['exec'], **all_data[scenario_name]['Num_Failures_by_Type']['non-exec']} 56 | #del all_data[scenario_name]['Num Failures by Type'] 57 | #all_data[scenario_name]['Percentage_of_Exec_Act_Failure_by_Act'] = all_data[scenario_name]['Percentage of Exec Act Failures by Act'] 58 | #del all_data[scenario_name]['Percentage of Exec Act Failures by Act'] 59 | 60 | 61 | # let's put the data in a more pandas friendly format 62 | 63 | for s_ind,scenario_name in enumerate(all_data.keys()): 64 | dataset = [] 65 | for f_ind,failure_name in enumerate(all_data[scenario_name]['Num_Failures_by_Type'].keys()): 66 | dataset.append([]) 67 | for act_type_failure_count in all_data[scenario_name]['Num_Failures_by_Type'][failure_name].values(): 68 | dataset[f_ind].append(act_type_failure_count) 69 | 70 | df = pd.DataFrame(dataset,index=all_data[scenario_name]['Num_Failures_by_Type'].keys(),columns=all_data[scenario_name]['Num_Failures_by_Type'][failure_name].keys()) 71 | df.to_csv(data_folder + scenario_name + '.txt') 72 | -------------------------------------------------------------------------------- /requirements.txt: -------------------------------------------------------------------------------- 1 | pyutilib==5.8.0 2 | jdcal==1.4 3 | Pyomo==5.5.1 4 | numpy==1.15.4 5 | matplotlib==3.0.2 6 | scipy==1.1.0 7 | ipdb==0.11 8 | poliastro==0.11.0 9 | networkx==2.2 10 | pyOpenSSL==19.1.0 11 | pyyaml==5.4.1 12 | 13 | -------------------------------------------------------------------------------- /scripts/run_ind_gp.sh: -------------------------------------------------------------------------------- 1 | #! /bin/bash 2 | printf "running: $0\n" 3 | printf "IN INDGP" 4 | # ---------------------------- PATHS AND FILE NAMES ---------------------------- # 5 | 6 | #PATH TO LOCATION OF THIS SCRIPT (FROM WHICH ALL OTHER PATHS ARE RELATIVE). 7 | CIRCINUS_PATH=$PWD/.. 8 | 9 | # ---- STD INPUT FILES ---- # 10 | PATH_TO_INPUTS=$CIRCINUS_PATH/inputs 11 | 12 | # ---- MODULE PATHS ---- # 13 | PATH_TO_MODULES=$CIRCINUS_PATH/source 14 | 15 | 16 | # --------------------------------- EXECUTE GP --------------------------------- # 17 | cd $PATH_TO_MODULES/central_global_planner 18 | 19 | python $ipdb cgp_main.py --inputs_location $PATH_TO_INPUTS 20 | -------------------------------------------------------------------------------- /scripts/run_orbit_viz.sh: -------------------------------------------------------------------------------- 1 | #! /bin/bash 2 | 3 | # dir_opt=4hour 4 | dir_opt=1day 5 | # scen_name=sso10sat 6 | # scen_name=walker18_inc30 7 | # scen_name=walker30_inc30 8 | # scen_name=walker60_inc60 9 | scen_name=zhou2017_comparison 10 | # scen_name=walker100_inc60 11 | # scen_name=walker28_4orb_inc30 12 | # dir_opt_params=polar_gs_targs3/dlnk_and_xlnk 13 | # dir_opt_params=17gs_targs3/dlnk_and_xlnk 14 | # dir_opt_params=17gs_targs3/dlnk_and_xlnk 15 | # dir_opt_params=7gs_targs3/dlnk_and_xlnk 16 | dir_opt_params=dlnk_and_xlnk 17 | 18 | 19 | 20 | 21 | 22 | history_input_option=sat_link_only 23 | # history_input_option=gp_and_sat_link 24 | display_link_info="false" 25 | # display_link_info="true" 26 | 27 | prop_inputs=orbit_prop_inputs.json 28 | data_rates=data_rates_output.json 29 | prop_data=orbit_prop_data.json 30 | gp_outputs=gp_outputs.json 31 | sat_link=sat_link_history.json 32 | 33 | # this is relative to THIS file 34 | ORBIT_VIZ_PATH="../source/circinus_orbit_viz" 35 | 36 | # this is relative to each repo base in CIRCINUS/source/ 37 | gen_inp_dir_python="../../inputs/$dir_opt/$scen_name" 38 | opt_inp_dir_python="../../inputs/$dir_opt/$scen_name/$dir_opt_params" 39 | opt_inp_dir="../inputs/$dir_opt/$scen_name/$dir_opt_params" 40 | 41 | 42 | prop_inputs_r=$opt_inp_dir_python/$prop_inputs 43 | data_rates_r=$opt_inp_dir_python/$data_rates 44 | prop_data_r=$opt_inp_dir_python/$prop_data 45 | sat_link_r=$opt_inp_dir_python/$sat_link 46 | 47 | 48 | if [ $display_link_info = "true" ] 49 | then 50 | display_link_info=--display_link_info 51 | else 52 | display_link_info= 53 | fi 54 | 55 | # copy this, because orbit viz assumes a fixed location 56 | comp_inp_dir=crux/config/examples 57 | cp "$opt_inp_dir/$gp_outputs" $ORBIT_VIZ_PATH/$comp_inp_dir 58 | 59 | echo $prop_inputs 60 | echo $prop_data 61 | echo $sat_link 62 | echo $display_link_info 63 | 64 | pushd $ORBIT_VIZ_PATH/python_runner/ 65 | python runner_orbitviz.py --prop_inputs_file "$prop_inputs_r" --prop_data_file "$prop_data_r" --sat_link_file "$sat_link_r" --history_input_option $history_input_option $display_link_info 66 | # python -m ipdb -c continue runner_orbitviz.py --prop_inputs_file "$prop_inputs_r" --prop_data_file "$prop_data_r" --sat_link_file "$sat_link_r" --history_input_option $history_input_option $display_link_info 67 | popd -------------------------------------------------------------------------------- /scripts/tools/.gitignore: -------------------------------------------------------------------------------- 1 | injected_obs.pdf 2 | *.json 3 | *.pdf -------------------------------------------------------------------------------- /scripts/tools/case_generator/constellation_blank.xlsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MIT-STARLab/SPRINT/a70939ada4f49923aa06f8264d492a443338ff19/scripts/tools/case_generator/constellation_blank.xlsx -------------------------------------------------------------------------------- /scripts/tools/case_generator/cubesat_blank.xlsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MIT-STARLab/SPRINT/a70939ada4f49923aa06f8264d492a443338ff19/scripts/tools/case_generator/cubesat_blank.xlsx -------------------------------------------------------------------------------- /scripts/tools/case_generator/ground_station_blank.xlsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MIT-STARLab/SPRINT/a70939ada4f49923aa06f8264d492a443338ff19/scripts/tools/case_generator/ground_station_blank.xlsx -------------------------------------------------------------------------------- /scripts/tools/case_generator/gs_gen.py: -------------------------------------------------------------------------------- 1 | import json 2 | import os 3 | import sys 4 | import shutil 5 | 6 | 7 | def create_gs(reference, stations_on, dlnk, replan_interval = None, replan_release_wait = None, release_first = None): 8 | #First, get the reference from the reference folder 9 | print("Starting GS Generation...") 10 | cwd = os.path.abspath(os.getcwd()) 11 | name = 'ground_station_network_config.json' 12 | 13 | if reference[-5:] != ".json": 14 | reference = reference+".json" 15 | gs_path = os.path.abspath(os.path.join(os.path.dirname( __file__ ), '../../../', 'inputs/reference_model_definitions/gs_refs')) 16 | os.system('cp '+gs_path+'/'+reference+' '+cwd+'/'+name) 17 | 18 | try: 19 | with open(name,'r+') as f: 20 | data = json.load(f) 21 | 22 | stations = data['network_definition']['gs_net_params']['stations'] 23 | params = data['network_definition']['sim_gs_network_params']['gsn_ps_params'] 24 | 25 | except NameError: 26 | print("There are no stations in file "+reference) 27 | os.system('rm '+name) 28 | 29 | good_stations = [] 30 | id = 0 31 | for s in stations: 32 | if stations_on == 'all': 33 | s['id'] = 'G' + str(id) 34 | id += 1 35 | s['comm_type'] = dlnk 36 | good_stations.append(s) 37 | elif s['name'] in stations_on: 38 | s['id'] = 'G' + str(id) 39 | id += 1 40 | s['comm_type'] = dlnk 41 | good_stations.append(s) 42 | 43 | if replan_interval is not None: 44 | params['replan_interval_s'] = int(replan_interval) 45 | if replan_release_wait is not None: 46 | params['replan_release_wait_time_s'] = int(replan_release_wait) 47 | 48 | if release_first is not None: 49 | if release_first.lower() == 'true' or release_first.lower() == 't': 50 | params['release_first_plans_immediately'] = True 51 | elif release_first.lower() == 'false' or release_first.lower() == 'f': 52 | params['release_first_plans_immediately'] = False 53 | 54 | data['network_definition']['gs_net_params']['stations'] = good_stations 55 | data['network_definition']['gs_net_params']['num_stations'] = len(good_stations) 56 | 57 | with open(name,'w') as f: 58 | json.dump(data, f, indent =4) 59 | print("Successfully saved new gs.") 60 | 61 | return (cwd +'/'+name) 62 | 63 | 64 | 65 | 66 | if __name__ == '__main__': 67 | create_gs(*sys.argv[1:]) -------------------------------------------------------------------------------- /scripts/tools/case_generator/injected_obs_generator.py: -------------------------------------------------------------------------------- 1 | #! /usr/bin/env python 2 | 3 | 4 | # @author Kit Kennedy 5 | # @edits Mary Dahl 6 | 7 | import random 8 | from datetime import datetime,timedelta 9 | import json 10 | import bisect 11 | import sys 12 | import dateutil.parser 13 | 14 | def inject(file_to_inject, num_sats, inject_per_sat,day_start=None,day_end=None): 15 | if day_start is None or day_end is None: 16 | with open(file_to_inject,'r+') as f: 17 | data = json.load(f) 18 | day_start = dateutil.parser.isoparse(data['scenario_params']['start_utc']) 19 | day_end = dateutil.parser.isoparse(data['scenario_params']['end_utc']) 20 | 21 | 22 | sats= [] 23 | for i in range(int(num_sats)): 24 | sats.append("S" + str(i)) 25 | 26 | the_json = [] 27 | used_fracs = [] 28 | indx = 0 29 | 30 | for sat in sats: 31 | for i in range(int(inject_per_sat)): 32 | valid = False 33 | while not valid: 34 | overlap = False 35 | start = random.random()*24*60 36 | end = start + 1 37 | #make sure the delta doesn't make it after the end of the day 38 | if (day_start+ timedelta(minutes=end)) > day_end: 39 | continue 40 | 41 | #checking to make sure observations don't overlap 42 | if len(used_fracs) == 0: 43 | break 44 | if start >= (used_fracs[-1] +1 ): 45 | break 46 | else: 47 | for frac in used_fracs: 48 | if abs(frac - start) <= 1: 49 | overlap = True 50 | break 51 | if overlap: 52 | pass 53 | else: 54 | valid = True 55 | 56 | bisect.insort(used_fracs,start) 57 | 58 | the_json.append({ 59 | "indx": indx, 60 | "end_utc": (day_start + timedelta(minutes=end)).isoformat()[:-6]+'Z', 61 | "sat_id": sat, 62 | "type": "hardcoded", 63 | "start_utc": (day_start + timedelta(minutes=start)).isoformat()[:-6]+'Z', 64 | } 65 | ) 66 | 67 | indx+=1 68 | 69 | if file_to_inject is None: 70 | print("No file to inject. Saving as output.json") 71 | with open('output.json','w') as f: 72 | json.dump(the_json ,f, indent = 4) 73 | print("Successfully injected observations.") 74 | else: 75 | try: 76 | with open(file_to_inject,'r+') as f: 77 | data = json.load(f) 78 | 79 | data['scenario_params']['sim_run_perturbations']['injected_observations'] = the_json 80 | 81 | with open(file_to_inject,'w') as f: 82 | json.dump(data, f, indent =4) 83 | print("Successfully injected " + str(inject_per_sat) + " observations to " + str(num_sats) +" satellites to "+ str(file_to_inject)) 84 | 85 | except NameError: 86 | print("File to inject does not contain the correct data structures. Generated observations will be saved as output.json") 87 | with open('output.json','w') as f: 88 | json.dump(the_json,f,indent=4) 89 | print("Successfully saved injected observations.") 90 | 91 | 92 | if __name__ == '__main__': 93 | inject(*sys.argv[1:]) 94 | -------------------------------------------------------------------------------- /scripts/tools/case_generator/obs_gen.py: -------------------------------------------------------------------------------- 1 | #for when you just want a bunch of obs in a certain area 2 | import json 3 | import random 4 | import sys 5 | 6 | 7 | def observation_generator(num_targets, lat_min,lat_max,long_min, long_max, file_location = None): 8 | 9 | targets = [] 10 | for i in range(int(num_targets)): 11 | 12 | lat = random.randint(int(lat_min),int(lat_max)) 13 | lon = random.randint(int(long_min), int(long_max)) 14 | 15 | targ = { 16 | "id": "obs" + str(i), 17 | "name": "generated" +str(i), 18 | "name_pretty": "generated" +str(i), 19 | "latitude_deg": lat, 20 | "longitude_deg": lon, 21 | "height_m": 0 22 | } 23 | 24 | targets.append(targ) 25 | 26 | if file_location is None: 27 | print("No file given to inject into. Will dump json into this directory as obs_out.json.") 28 | data = {} 29 | data['targets'] = targets 30 | with open('obs_out.json','w') as f: 31 | json.dump(data,f, indent =4) 32 | else: 33 | with open(file_location,'r+') as f: 34 | data = json.load(f) 35 | 36 | data['ops_profile_params']['obs_params']['num_targets'] = int(num_targets) 37 | data['ops_profile_params']['obs_params']['targets'] = targets 38 | data['ops_profile_params']['obs_params']['target_set_name'] = "Generated targets, using latitude in the range " + str(lat_min) +" to "+ str(lat_max) + ' and longitude in the range '+str(long_min) + " to " +str(long_max)+'.' 39 | with open(file_location,'w') as f: 40 | json.dump(data,f,indent =4) 41 | 42 | 43 | 44 | if __name__ == '__main__': 45 | observation_generator(*sys.argv[1:]) -------------------------------------------------------------------------------- /scripts/tools/case_generator/op_blank.xlsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MIT-STARLab/SPRINT/a70939ada4f49923aa06f8264d492a443338ff19/scripts/tools/case_generator/op_blank.xlsx -------------------------------------------------------------------------------- /scripts/tools/case_generator/payload_blank.xlsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MIT-STARLab/SPRINT/a70939ada4f49923aa06f8264d492a443338ff19/scripts/tools/case_generator/payload_blank.xlsx -------------------------------------------------------------------------------- /scripts/tools/case_generator/sim_blank.xlsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MIT-STARLab/SPRINT/a70939ada4f49923aa06f8264d492a443338ff19/scripts/tools/case_generator/sim_blank.xlsx -------------------------------------------------------------------------------- /scripts/tools/injected_obs_creator/injected_obs_generator.py: -------------------------------------------------------------------------------- 1 | #! /usr/bin/env python 2 | 3 | ## 4 | # Python runner for orbit visualization pipeline 5 | # @author Kit Kennedy 6 | # 7 | 8 | 9 | 10 | import random 11 | from datetime import datetime,timedelta 12 | import json 13 | 14 | # day_start = datetime(2016,2,14,4,0,0) 15 | day_start = datetime(2018,1,18,0,0,0) 16 | sats = ["sat0","sat1","sat2","sat3","sat4","sat5","sat6","sat7","sat8","sat9"] 17 | # sats = ["sat0","sat1","sat2","sat3","sat4","sat5","sat6","sat7","sat8","sat9","sat10","sat11","sat12","sat13","sat14","sat15","sat16","sat17","sat18","sat19","sat20","sat21","sat22","sat23","sat24","sat25","sat26","sat27","sat28","sat29"] 18 | 19 | # BIG FAT NOTE: MAKE SURE RANDOMLY GENERATED INJECTED OBS DON'T OVERLAP!!!! 20 | 21 | 22 | the_json = [] 23 | indx = 0 24 | # for i in range(40): 25 | for sat in sats: 26 | 27 | for i in range(3): 28 | # sat = random.choice(sats) 29 | 30 | day_frac = random.random() 31 | 32 | 33 | the_json.append({ 34 | "sat_id": sat, 35 | "start_utc": (day_start + timedelta(minutes=day_frac*24*60)).isoformat()+'Z', 36 | "end_utc": (day_start + timedelta(minutes=day_frac*24*60 + 1)).isoformat()+'Z', 37 | "indx": indx, 38 | "type": "hardcoded" 39 | } 40 | ) 41 | 42 | indx+=1 43 | 44 | 45 | 46 | with open('output.json','w') as f: 47 | json.dump(the_json ,f) -------------------------------------------------------------------------------- /scripts/tools/injected_obs_creator/injected_obs_plotter.py: -------------------------------------------------------------------------------- 1 | #! /usr/bin/env python 2 | 3 | ## 4 | # Python runner for orbit visualization pipeline 5 | # @author Kit Kennedy 6 | # 7 | from datetime import datetime,timedelta 8 | import json 9 | import sys 10 | 11 | day_start = datetime(2016,2,14,4,0,0) 12 | day_end = datetime(2016,2,15,4,0,0) 13 | sats = ["sat0","sat1","sat2","sat3","sat4","sat5"] 14 | 15 | # day_start = datetime(2018,1,18,0,0,0) 16 | # day_end = datetime(2018,1,19,0,0,0) 17 | # sats = ["sat0","sat1","sat2","sat3","sat4","sat5","sat6","sat7","sat8","sat9"] 18 | # sats = ["sat0","sat1","sat2","sat3","sat4","sat5","sat6","sat7","sat8","sat9","sat10","sat11","sat12","sat13","sat14"] 19 | # sats = ["sat15","sat16","sat17","sat18","sat19","sat20","sat21","sat22","sat23","sat24","sat25","sat26","sat27","sat28","sat29"] 20 | # sats = ["sat0","sat1","sat2","sat3","sat4","sat5","sat6","sat7","sat8","sat9","sat10","sat11","sat12","sat13","sat14","sat15","sat16","sat17","sat18","sat19","sat20","sat21","sat22","sat23","sat24","sat25","sat26","sat27","sat28","sat29"] 21 | 22 | 23 | 24 | sys.path.append ('../../source/circinus_sim') 25 | from circinus_tools.plotting import plot_tools as pltl 26 | from circinus_tools.scheduling.custom_window import ObsWindow 27 | from circinus_tools import time_tools as tt 28 | 29 | with open('injects_zhou.json','r') as f: 30 | the_json = json.load(f) 31 | 32 | 33 | all_obs = [[] for i in range(len(sats))] 34 | 35 | for injected in the_json: 36 | if not injected['sat_id'] in sats: 37 | continue 38 | 39 | windid = injected['indx'] 40 | sat_indx = sats.index(injected['sat_id']) 41 | start = tt.iso_string_to_dt(injected['start_utc']) 42 | end = tt.iso_string_to_dt(injected['end_utc']) 43 | obs = ObsWindow(windid, sat_indx, ['blah'], 0, start, end, wind_obj_type='injected') 44 | all_obs[sat_indx].append(obs) 45 | 46 | 47 | plot_params = {} 48 | plot_params['route_ids_by_wind'] = None 49 | plot_params['plot_start_dt'] = day_start 50 | plot_params['plot_end_dt'] = day_end 51 | plot_params['base_time_dt'] = day_start 52 | 53 | plot_params['plot_title'] = 'Injected Observations' 54 | plot_params['y_label'] = 'Satellite Index' 55 | plot_params['plot_size_inches'] = (18,9) 56 | plot_params['plot_original_times_choices'] = False 57 | plot_params['plot_executed_times_regular'] = True 58 | plot_params['show'] = False 59 | plot_params['fig_name'] = 'injected_obs.pdf' 60 | plot_params['plot_fig_extension'] = 'pdf' 61 | 62 | plot_params['time_units'] = 'hours' 63 | plot_params['agent_id_order'] = sats 64 | 65 | plot_params['plot_xlnks_choices'] = False 66 | plot_params['plot_dlnks_choices'] = False 67 | plot_params['plot_obs_choices'] = False 68 | plot_params['plot_xlnks'] = False 69 | plot_params['plot_dlnks'] = False 70 | plot_params['plot_obs'] = True 71 | plot_params['plot_include_obs_labels'] = True 72 | plot_params['plot_include_xlnk_labels'] = False 73 | plot_params['plot_include_dlnk_labels'] = False 74 | 75 | plot_params['obs_choices_legend_name'] = "" 76 | plot_params['obs_exe_legend_name'] = "O inject" 77 | plot_params['dlnk_choices_legend_name'] = "" 78 | plot_params['dlnk_exe_legend_name'] = "" 79 | plot_params['xlnk_choices_legend_name'] = "" 80 | plot_params['xlnk_exe_legend_name'] = "" 81 | 82 | plot_params['label_fontsize'] = "12" 83 | 84 | 85 | def obs_label_getter(obs): 86 | # return "o%d, dv %d/%d (%d)"%(obs.window_ID,obs.executed_data_vol,obs.executable_data_vol,obs.data_vol) 87 | return "o%d"%(obs.window_ID) 88 | plot_params['obs_label_getter_func'] = obs_label_getter 89 | 90 | pltl.plot_all_agents_acts( 91 | sats, 92 | [], 93 | all_obs, 94 | [], 95 | [], 96 | [], 97 | [], 98 | plot_params) 99 | 100 | 101 | -------------------------------------------------------------------------------- /scripts/windows_launcher.bat: -------------------------------------------------------------------------------- 1 | @ echo off 2 | REM this script assumes you are calling from the $REPO_BASE/scripts directory 3 | REM helpful batch string operations here: https://www.dostips.com/DtTipsStringManipulation.php#Snippets.Replace 4 | REM ===========SETUP THE FOLLOWING VARIABLES FOR EACH COMPUTER============= 5 | REM THIS FILE ASSUMES YOU HAVE A LOCAL FILE THAT SETS THE FOLLOWING ENVIRONMENT VARIABLES (name it windows_env_var_setup.bat to have git ignore it): 6 | REM PY_ENV_NAME: name of python environment that runs SPRINT 7 | REM PY_ENV_ACTIVATE_DIR: full path to activate script of your python distribution, if using Anaconda it is at C:\Users\[User Name]\Anaconda3\Scripts\activate 8 | REM BASH_DIR: full path to the bash executable, if using git SCM, then it is usually at C:\Users\[User Name]]\AppData\Local\Programs\Git\bin\bash OR at C:\Program Files\Git\bin\bash 9 | REM PKL_DIR: full path (in UNIX convention, NOT windows) to the pickle you want to run from (if this isn't set, then it will run from the start) 10 | REM ======================END SETUP VARIABLES============================== 11 | call windows_env_var_setup.bat 12 | REM Activate python environment 13 | SET cur_dir_win=%~dp0 14 | SET cur_dir_unix=%cur_dir_win:\=/% 15 | SET cur_dir_unix=%cur_dir_unix:~0,-1% 16 | call %PY_ENV_ACTIVATE_DIR% %PY_ENV_NAME% 17 | REM change directory manually as needed, this is hacky for now to get the project done 18 | REM remove carriage returns (CR) from the DOS stored version of the file 19 | if not exist run_const_sim_win.sh ( 20 | call "%BASH_DIR%" --login -c "cd '%cur_dir_unix%'; sed 's/\r$//' run_const_sim.sh > run_const_sim_win.sh" 21 | REM allow all acesses on new file 22 | call "%BASH_DIR%" --login -c "cd '%cur_dir_unix%'; chmod +x run_const_sim_win.sh" 23 | ) 24 | REM run new script 25 | if defined PKL_DIR ( 26 | call "%BASH_DIR%" --login -c "cd '%cur_dir_unix%'; ./run_const_sim_win.sh --fromPkl %PKL_DIR%" 27 | ) else ( 28 | call "%BASH_DIR%" --login -c "cd '%cur_dir_unix%'; ./run_const_sim_win.sh" 29 | ) -------------------------------------------------------------------------------- /source/Ground_Sim/Satellite_Ground_Protocol: -------------------------------------------------------------------------------- 1 | """ 2 | MESSAGE PROTOCOL TO AND FROM SAT < - > GS and SIM 3 | 4 | NOTE: 5 | --------------------------------------------- 6 | - GROUND refers to ground simulation manager 7 | that orchestrates sim 8 | - GS refers to singular GS 9 | - Each Message is structured as follows: 10 | - req_type : The request type 11 | - dest: The destination 12 | - payload: Any corresponding data 13 | - sender: The id of the object sending the message 14 | 15 | Protocol is formatted as follows: 16 | ---------------------------------------------- 17 | #) ____ SENDS: 18 | - 19 | - Payload: 20 | - Target: 21 | - Sender: 22 | 23 | - Steps with parts a, b, c, etc. indicate no strict ordering of messages sent 24 | in that numbered step, only that they are all sent before the next numbered 25 | step and after the previous numbered step 26 | 27 | - (*) is only used once 28 | 29 | ======================================== 30 | ============= BEFORE SIM =============== 31 | ======================================== 32 | 33 | 1) SAT SENDS: JOIN 34 | - Request to join simulation 35 | - Payload: address of socket 36 | - Target: ground 37 | 38 | 2) GROUND SENDS: INIT PARAMS 39 | - Parameters for satellite and simulation 40 | - Payload: Parameters 41 | - Target: Client that sent most recent JOIN 42 | - Sender: ground 43 | 44 | 3) GROUND SENDS: ALL_IPS 45 | - Once all satellites joined 46 | - IP addresses of all satellites in simulation 47 | - Payload: Map keyed on satellite IDs with IP addresses as values 48 | - Target: All satellites 49 | - Sender: ground 50 | 51 | 4) GROUND SENDS: INJECT_OBS 52 | - Injects observations into satellites (sat-specific) 53 | - Payload: the injected observations 54 | - Target: All satellites 55 | - Sender: ground 56 | 57 | 5) GROUND SENDS: SAT_WINDOWS_INIT 58 | - Initializes each satellite's windows 59 | - Payload: The map of windows 60 | - Target: All satellites 61 | - Sender: ground 62 | 63 | 6) GROUND SENDS: START 64 | - Request to start simulation 65 | - Payload: None 66 | - Target: All satellites 67 | - Sender: ground 68 | 69 | ======================================== 70 | ============= DURING SIM =============== 71 | =============== REPEAT ================= 72 | ======================================== 73 | 74 | 1a) SAT SENDS: BDT 75 | - Bulk Data transfer as downlink and or crosslink 76 | - Payload: The data 77 | - Target: Intended receiver (gs id of sat id) 78 | - Sender: sat_id 79 | 80 | 1b) SAT SENDS: PLAN 81 | - Sends plan after each BDT run 82 | - Payload: Planning data 83 | - Target: Intended receiver (gs id of sat id) 84 | - Sender: sat_id 85 | 86 | 2) SAT SENDS: ACTS_DONE 87 | - Indicates done sending all executive act related messages 88 | - Payload: None 89 | - Target: All 90 | - Sender: sat_id 91 | 92 | 3) GS SENDS: PLAN 93 | - ONLY on first iteration and ONLY if hot start 94 | - Payload: GS planning info 95 | - Target: Satellites in view 96 | - Sender: gs id 97 | 98 | 4) GROUND SENDS: UPDATE 99 | - Request for recipient to update state 100 | - Payload: None 101 | - Target: All satellites 102 | - Sender: ground 103 | 104 | 5a) SAT SENDS: STATE 105 | - Current state of satellite to send via crosslink only if 106 | the time since the last state sending is over a threshold amount of time 107 | - Payload: State 108 | - Target: Any satellite in view 109 | - Sender: sat id 110 | 111 | 5b) GS SENDS: PLAN 112 | - Planning info of each gs if GP ran 113 | - Payload: Planning info 114 | - Target: Any satellite in view 115 | - Sender: gs id 116 | 117 | 5c) SAT SENDS: PLAN 118 | - Send to other satellites if allowed, and send to gs in view if LP ran 119 | - Payload: Planning info 120 | - Target: satellite (if allowed) or gs in view (if LP ran) 121 | - Sender: sat id 122 | 123 | 6) SAT and GROUND SEND: FINISHED_PROP 124 | - Indicates done propagating plans 125 | - Payload: None 126 | - Target: All 127 | - Sender: ground or sat id 128 | 129 | 7) SAT AND GROUND SEND: READY_FOR_TIME_UPDATE 130 | - Indicates ready for time update 131 | - Payload: None 132 | - Target: All 133 | - Sender: ground or sat id 134 | 135 | 136 | 137 | 138 | -------------------------------------------------------------------------------- /source/Ground_Sim/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MIT-STARLab/SPRINT/a70939ada4f49923aa06f8264d492a443338ff19/source/Ground_Sim/__init__.py -------------------------------------------------------------------------------- /source/Removed_Satellite/BlockingDict.py: -------------------------------------------------------------------------------- 1 | import threading 2 | class BlockingDict: 3 | """ 4 | A threadsafe version of a dictionary. 5 | All actions (put, get, keyExists) requires the object's lock to proceed. 6 | 7 | """ 8 | 9 | def __init__(self): 10 | self.queue = {} 11 | self.cv = threading.Condition() 12 | 13 | def put(self, key, value): 14 | """ 15 | Places value associated with given key 16 | 17 | :param key: 18 | :param value: 19 | :return: None 20 | """ 21 | with self.cv: 22 | self.queue[key] = value 23 | self.cv.notifyAll() 24 | 25 | 26 | def keyExists(self,key): 27 | """ 28 | Determines if the key exists 29 | :param key: The key 30 | :return: True if key exists 31 | """ 32 | with self.cv: 33 | return key in self.queue 34 | 35 | def get(self,key): 36 | """ 37 | Gets and removes the key-value pair. 38 | blocks until key is in queue 39 | :param key: The input key 40 | :return: The value of the key 41 | """ 42 | with self.cv: 43 | self.cv.wait_for(lambda: key in self.queue) 44 | result = self.queue.pop(key) 45 | return result 46 | 47 | def __str__(self): 48 | with self.cv: 49 | return self.queue.__str__() 50 | -------------------------------------------------------------------------------- /source/Removed_Satellite/LightControl.py: -------------------------------------------------------------------------------- 1 | import RPi.GPIO as GPIO 2 | import time 3 | 4 | def light_toggle(rxsnd, where, state): 5 | GPIO.setwarnings(False) 6 | GPIO.setmode(GPIO.BCM) 7 | #blue: receive from ground 8 | #green: send to groudn 9 | #yellow: send to cs 10 | #red: receive from cs 11 | if rxsnd == 'r': 12 | if where == 'G0': 13 | color = 'blue' 14 | else: 15 | color = 'red' 16 | else: 17 | if where == 'G0': 18 | color = 'green' 19 | else: 20 | color = 'yellow' 21 | 22 | color_dict = { 23 | 'red':17, 24 | 'yellow':18, 25 | 'green':22, 26 | 'blue':23 27 | } 28 | 29 | pin = color_dict[color] 30 | GPIO.setup(pin, GPIO.OUT) 31 | GPIO.output(pin, state) 32 | -------------------------------------------------------------------------------- /source/Removed_Satellite/Message_ID_Assigner.py: -------------------------------------------------------------------------------- 1 | from threading import RLock 2 | 3 | class MessageIDAssigner: 4 | """ 5 | A thread-safe UID assigner for messages in the format 6 | 7 | UIDs are integers. 8 | 9 | : 10 | 11 | """ 12 | def __init__(self,start: int = 0): 13 | """ 14 | The contructor 15 | :param start: Starting UID value 16 | """ 17 | self.nextID = start # The next ID to use when assigning messages 18 | self.agent_id = None # The ID of the agent using the assigner 19 | self.lock = RLock() # Lock for threadsafety 20 | 21 | def assign_id(self): 22 | """ 23 | Assign exactly one message a UID. Requires the agent ID to 24 | be defined. 25 | 26 | :return: The UID 27 | """ 28 | if self.agent_id: 29 | with self.lock: 30 | self.nextID += 1 31 | return self.agent_id + ":" + str(self.nextID - 1) 32 | else: 33 | self.nextID += 1 34 | return str(self.nextID) 35 | 36 | def assign_ids(self,num:int): 37 | """ 38 | Assign multiple messages separate UIDs in one shot. 39 | :param num: The number of UIDs to generate 40 | :return: A set of UIDs 41 | """ 42 | with self.lock: 43 | return set(self.assign_id() for i in range(num)) 44 | 45 | def setAgentID(self,_id:str): 46 | 47 | self.agent_id = _id 48 | -------------------------------------------------------------------------------- /source/central_global_planner/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MIT-STARLab/SPRINT/a70939ada4f49923aa06f8264d492a443338ff19/source/central_global_planner/__init__.py -------------------------------------------------------------------------------- /source/central_global_planner/certs/.gitignore: -------------------------------------------------------------------------------- 1 | *.cert 2 | *.pkey 3 | *.req 4 | *.pem -------------------------------------------------------------------------------- /source/central_global_planner/certs/README.md: -------------------------------------------------------------------------------- 1 | # SSL Certs directory 2 | 3 | Before distribution, a shell script shall be provided to set up certs automatically on installation. Consideration should also be given to distribution for systems not colocated. 4 | 5 | Certs themselves shall not be git controlled. -------------------------------------------------------------------------------- /source/central_global_planner/cgp_main.yaml: -------------------------------------------------------------------------------- 1 | --- 2 | # config for cgp_main.py 3 | 4 | server_config: 5 | port: 54202 6 | log_name: 'logs/cgp_main_server.log' 7 | 8 | ... -------------------------------------------------------------------------------- /source/sprint_tools/OEnum.py: -------------------------------------------------------------------------------- 1 | import enum 2 | 3 | class OrderedEnum(enum.Enum): 4 | def __ge__(self, other): 5 | if self.__class__ is other.__class__: 6 | return self.value >= other.value 7 | return NotImplemented 8 | def __gt__(self, other): 9 | if self.__class__ is other.__class__: 10 | return self.value > other.value 11 | return NotImplemented 12 | def __le__(self, other): 13 | if self.__class__ is other.__class__: 14 | return self.value <= other.value 15 | return NotImplemented 16 | def __lt__(self, other): 17 | if self.__class__ is other.__class__: 18 | return self.value < other.value 19 | return NotImplemented 20 | 21 | 22 | class PrintVerbosity(OrderedEnum): 23 | NONE = 99 24 | ERRORS = 3 25 | WARNINGS = 2 26 | INFO = 1 27 | ALL = 0 -------------------------------------------------------------------------------- /source/sprint_tools/Sprint_Types.py: -------------------------------------------------------------------------------- 1 | # TODO - Force upgrade to 3.6 2 | from enum import Enum, auto 3 | class AgentType(Enum): # To be used for type-based behavior in generalized functions 4 | GS = auto() #'GS' 5 | SAT = auto() #'SAT' 6 | GSNET = auto() #'GSNET' -------------------------------------------------------------------------------- /source/sprint_tools/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MIT-STARLab/SPRINT/a70939ada4f49923aa06f8264d492a443338ff19/source/sprint_tools/__init__.py -------------------------------------------------------------------------------- /source/sprint_tools/demo_ruby_client.rb: -------------------------------------------------------------------------------- 1 | require 'socket' 2 | require 'openssl' 3 | 4 | require 'json' 5 | 6 | c_dir = Dir.getwd + '/../central_global_planner/certs/' # + c_dir 7 | f_cert = c_dir+"client.cert" 8 | f_key = c_dir+"client.pkey" 9 | 10 | socket = TCPSocket.open('localhost', 54202) 11 | ssl_context = OpenSSL::SSL::SSLContext.new() 12 | ssl_context.cert = OpenSSL::X509::Certificate.new(File.open(f_cert)) 13 | ssl_context.key = OpenSSL::PKey::RSA.new(File.open(f_key)) 14 | ssl_context.ssl_version = :SSLv23 15 | ssl_socket = OpenSSL::SSL::SSLSocket.new(socket, ssl_context) 16 | ssl_socket.sync_close = true 17 | ssl_socket.connect 18 | 19 | 20 | ##### ----- User Defined: Define request to GP ----- ##### 21 | ##### ----- Send downlinked state update from satellite, and requrest most recent plan for uplink ----- ##### 22 | ##### ----- This can be triggered on receipt of satellite TT&C downlink, or user command ----- ##### 23 | 24 | ##### ----- End User Defined ----- ##### 25 | 26 | 27 | 28 | ###### ----- Core GS Functions ----- ###### 29 | data = { # Request most recent plan 30 | "req_type" => "reqPlan", 31 | "payload" => nil # None 32 | } 33 | # data = { 34 | # "req_type" => 'updateSat', 35 | # "payload" => { 36 | # 'satID' => 'S0', # etc 37 | # 'sat_state' => { # for each, a list of pairs; each pair is a time & state ; one entry shown for each 38 | # 'power' => [ ["2016-02-14T04:00:00.000000Z", {"DS_state" =>500000}] ], 39 | # 'data' => [ ["2016-02-14T04:00:00.000000Z", {"batt_e_Wh"=>12}] ], 40 | # 'orbit' => [ ["2016-02-14T04:00:00.000000Z", { 41 | # "a_km" => 7378, 42 | # "e" => 0, 43 | # "i_deg" => 97.86, 44 | # "RAAN_deg" => 0, 45 | # "arg_per_deg" => 0, 46 | # "M_deg" => 180 47 | # } 48 | # ] 49 | # ] 50 | # } 51 | # } 52 | # } 53 | 54 | ###### ----- Supporting GS Functions ----- ###### 55 | 56 | # data = { 57 | # "req_type" => 'regenPlan', # Force regen of plan - should be automatically generated when GP ingests changes 58 | # "payload" => [ nil ] # nil for all live use when GP controls its own time. 59 | # } 60 | ###### Details on payloads for add & remove sat can be found in cgp_main.py 61 | # data = { 62 | # "req_type" => 'addSat', 63 | # "payload" => nil 64 | # } 65 | # data = { 66 | # "req_type" => 'removeSat', 67 | # "payload" => nil 68 | # } 69 | # data = { # Signal the GP to exit. 70 | # "req_type" => "quit", 71 | # "payload" => nil # None 72 | # } 73 | 74 | 75 | msg = JSON.generate(data) 76 | 77 | START_MARKER = "size:" 78 | 79 | ssl_socket.puts START_MARKER+[msg.length].pack("L>")+msg # "'B'*50024" 80 | all_data = [] 81 | 82 | while partial_data = ssl_socket.read(16) #read # (3) #.rcv 83 | all_data << partial_data 84 | 85 | if partial_data=="ACK" # Log or act if response required 86 | break 87 | end 88 | 89 | end 90 | 91 | data = all_data.join().slice!(START_MARKER.length+4...) 92 | data = JSON.parse(data) 93 | 94 | # puts data 95 | 96 | ##### ----- User Defined: Select from 'data' to build next packet to sat node, as appropriate ----- ##### 97 | 98 | ##### ----- End User Defined ----- ##### 99 | 100 | 101 | ssl_socket.close 102 | 103 | --------------------------------------------------------------------------------