Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixing documentation build #1601

Merged
merged 1 commit into from
Jun 2, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 7 additions & 4 deletions docs/using/interaction/custom_source.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"Custom packet source class that is derived from BasePacketSource. The method create_packets (which returns ```nus, mus, energies```) has to be defined."
"Custom packet source class that is derived from BasePacketSource. The method create_packets (which returns ```radii, nus, mus, energies```) has to be defined."
]
},
{
Expand All @@ -55,7 +55,7 @@
" self.rng = np.random.default_rng(seed=seed)\n",
" self.truncation_wavelength = truncation_wavelength\n",
" \n",
" def create_packets(self, T, no_of_packets, rng,\n",
" def create_packets(self, T, no_of_packets, rng, radius,\n",
" drawing_sample_size=None):\n",
" \"\"\"\n",
" Packet source that generates a truncated Blackbody source.\n",
Expand All @@ -71,6 +71,9 @@
" Only wavelengths higher than the truncation wavelength\n",
" will be sampled.\n",
" \"\"\"\n",
" \n",
" # Makes uniform array of packet radii\n",
" radii = np.ones(no_of_packets) * radius\n",
"\n",
" # Use mus and energies from normal blackbody source.\n",
" mus = self.create_zero_limb_darkening_packet_mus(no_of_packets, self.rng)\n",
Expand Down Expand Up @@ -100,7 +103,7 @@
" additional_nus = additional_nus[mask][:no_of_packets]\n",
" nus = np.hstack([nus, additional_nus])[:no_of_packets]\n",
" \n",
" return nus, mus, energies"
" return radii, nus, mus, energies"
]
},
{
Expand Down Expand Up @@ -161,7 +164,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.6.7"
"version": "3.7.10"
},
"nbsphinx": {
"execute": "always",
Expand Down