Skip to content

Commit 6f3cdae

Browse files
committed
Tidied up readme and examples
1 parent 05fb76b commit 6f3cdae

4 files changed

Lines changed: 1435 additions & 164 deletions

File tree

README.md

Lines changed: 3 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# CamPyRoS - A 6DOF Rocket Trajectory Simulator
2-
[![DOI](https://zenodo.org/badge/308847422.svg)](https://zenodo.org/badge/latestdoi/308847422) [![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black)
2+
[![DOI](https://zenodo.org/badge/308847422.svg)](https://zenodo.org/badge/latestdoi/308847422) [![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black)[![Testing](https://github.com/cuspaceflight/CamPyRoS/actions/workflows/testcase.yml/badge.svg)](https://github.com/cuspaceflight/CamPyRoS/actions/workflows/testcase.yml)
33

44
CamPyRoS (Cambridge Python Rocketry Simulator) is a Python package which provides fully featured rocket trajectory simulation including features like:
55
- 6 degrees of freedom (3 translational, 3 rotational)
@@ -15,27 +15,11 @@ Currently not all dependancies are supported by the same install methods so the
1515

1616
`pip install git+https://github.com/cuspaceflight/CamPyRoS.git`
1717

18-
The "wind" and "statistics" modules will not run. Statistics has a dependancy not fully supported by windows, to install it:
18+
Statistics has a dependancy not fully supported by windows, to install it:
1919

2020
`pip install ray` on most platforms, for Windows problems see [here](https://docs.ray.io/en/master/installation.html).
2121

22-
Wind depends on a library called iris which can only be installed with conda:
23-
24-
`conda install iris, iris_grib`
25-
26-
> Note: after some more testing this won't work for anyone on Windows, I am in the process fo sorting this out (the problem is a codec dependancy which there is no way for us to fix) by writing an library to read the other GFS distrobution method, see [gfspy](https://github.com/jagoosw/gfspy). You can still run and contribute without using the wind module. If you really want to use the wind module please [email](jagoosw@protonmail.com) or message me and we can try and sort out access to something remote you can use to run it.
27-
28-
This may then demand you install another library when you try to run it:
29-
30-
`pip install eccodes-python`
31-
32-
Alternativly you can download this repository and move it to either your system path or somewhere you will exclusivly use it from then:
33-
34-
`conda env create -f enviroment.yml -n <name>`
35-
36-
`conda activate <name>`
37-
38-
From within the downloaded folder.
22+
If you don't install this the statistics module will run but only single threaded which will be *extremely* slow.
3923

4024
## Usage
4125

Stats Model Example.ipynb

Lines changed: 1420 additions & 123 deletions
Large diffs are not rendered by default.

example.ipynb

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -94,14 +94,16 @@
9494
"metadata": {},
9595
"outputs": [],
9696
"source": [
97-
"launch_site = pyro.LaunchSite(rail_length=5, \n",
98-
" rail_yaw=0, \n",
99-
" rail_pitch=0, \n",
100-
" alt=1, \n",
101-
" longi=0, \n",
102-
" lat=0, \n",
103-
" variable_wind=False,\n",
104-
" default_wind=np.array([5,0,0]))#Use this version if you don't want to use the real wind (e.g. to test something else)"
97+
"launch_site = pyro.LaunchSite(\n",
98+
" rail_length=5,\n",
99+
" rail_yaw=0,\n",
100+
" rail_pitch=0,\n",
101+
" alt=10,\n",
102+
" longi=0.1,\n",
103+
" lat=52.1,\n",
104+
" variable_wind=True,\n",
105+
" cache_Wind=True\n",
106+
")"
105107
]
106108
},
107109
{
@@ -263,4 +265,4 @@
263265
},
264266
"nbformat": 4,
265267
"nbformat_minor": 2
266-
}
268+
}

example.py

Lines changed: 1 addition & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -63,18 +63,6 @@
6363
"""Create the other objects needed to initialise the Rocket object"""
6464
pulsar = pyro.Motor.from_novus("novus_sim_6.1/motor_out.csv", pos=ROCKET_L)
6565

66-
"""
67-
launch_site = pyro.LaunchSite(rail_length=10,
68-
rail_yaw=0,
69-
rail_pitch=0,
70-
alt=1,
71-
longi=0.1160127,
72-
lat=52.2079404,
73-
variable_wind=True,
74-
forcast_plus_time="016",
75-
run_date="20201216",
76-
fast_wind=False)
77-
"""
7866
launch_site = pyro.LaunchSite(
7967
rail_length=5,
8068
rail_yaw=0,
@@ -84,7 +72,7 @@
8472
lat=52.1,
8573
variable_wind=True,
8674
cache_Wind=True
87-
) # Use this version if you don't want to use the real wind (e.g. to test something else)
75+
)
8876

8977
parachute_Data = pd.read_csv("data/Sample_Parachute_Cd.csv")
9078
mach_array = parachute_Data["Mach_Number"].to_numpy()

0 commit comments

Comments
 (0)