Skip to content

Commit

Permalink
docs: update tutorial to use pyuvdata AnalyticBeam
Browse files Browse the repository at this point in the history
  • Loading branch information
steven-murray committed Nov 8, 2024
1 parent d6b11fb commit 7cc7068
Showing 1 changed file with 10 additions and 16 deletions.
26 changes: 10 additions & 16 deletions docs/tutorials/matvis_tutorial.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@
},
{
"cell_type": "code",
"execution_count": 12,
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
Expand All @@ -59,7 +59,7 @@
"from astropy.time import Time\n",
"\n",
"from matvis import simulate_vis\n",
"from pyuvsim.analyticbeam import AnalyticBeam"
"from pyuvdata.analytic_beam import GaussianBeam, UniformBeam"
]
},
{
Expand Down Expand Up @@ -107,17 +107,18 @@
"source": [
"Now, let's define the beams for each of these antennas. `matvis` allows us to specify\n",
"different beams for each antenna, but we need only specify *unique* beams. Each beam\n",
"must be either a `UVBeam` or `AnalyticBeam`. Here, for simplicity we just use the \n",
"`AnalyticBeam` class. We do this as follows:"
"must be either a `UVBeam` or `AnalyticBeam`. Here, for simplicity we just use some\n",
"subclasses of the `AnalyticBeam` class. You can create your own custom `AnalyticBeam`\n",
"classes to use as well (see the [pyuvdata tutorial](https://pyuvdata.readthedocs.io/en/latest/analytic_beam_tutorial.html#defining-new-analytic-beams))."
]
},
{
"cell_type": "code",
"execution_count": 3,
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
"beams = [AnalyticBeam(\"gaussian\", sigma=0.5), AnalyticBeam(\"uniform\")]\n",
"beams = [GaussianBeam(sigma=0.5), UniformBeam(\"uniform\")]\n",
"beam_idx = [0, 0, 1]"
]
},
Expand All @@ -135,9 +136,7 @@
"metadata": {},
"source": [
"We also need to tell `matvis` the observational configuration, such as the frequency\n",
"channels and times to use. In this example, we don't worry too much about the exact date\n",
"of observation, but rather the LST. In general, the exact date of observation does make\n",
"a little difference."
"channels and times to use:"
]
},
{
Expand Down Expand Up @@ -422,7 +421,7 @@
],
"metadata": {
"kernelspec": {
"display_name": "Python 3 (ipykernel)",
"display_name": ".venv",
"language": "python",
"name": "python3"
},
Expand All @@ -436,12 +435,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.12.5"
},
"vscode": {
"interpreter": {
"hash": "ad4f6c198aebbf84691339a9a95c2c9f143d88558d502a312c8b0f70f8363bfd"
}
"version": "3.12.6"
}
},
"nbformat": 4,
Expand Down

0 comments on commit 7cc7068

Please sign in to comment.