|
42 | 42 | "id": "11b7cf83", |
43 | 43 | "metadata": {}, |
44 | 44 | "source": [ |
45 | | - "These arrays can be generated using the `draw_from_hypercube` function, which takes as input the number of samples you want to draw, and a dictionary of parameter ranges. In this dictionary, the key is the parameter range, and the value is a tuple defining the minimum and maximum value for that parameter. The function will then return a dictionary of arrays, where each array contains the sampled values for each parameter. \n", |
| 45 | + "These arrays can be generated using the `draw_from_hypercube` function, which takes as input the number of samples you want to draw, and a dictionary of parameter ranges. In this dictionary, the key is the parameter range, and the value is a tuple defining the minimum and maximum value for that parameter. The function will then return a dictionary of arrays, where each array contains the sampled values for each parameter. Other sampling schemes can be used (e.g. a [Sobol sequence](https://docs.scipy.org/doc/scipy/reference/generated/scipy.stats.qmc.Sobol.html))\n", |
46 | 46 | "\n", |
47 | 47 | "By default, the `draw_from_hypercube` function uses a form of low-discrepancy sampling called **Latin Hypercube Sampling (LHS)**. LHS is highly efficient compared to random sampling, especially when dealing with many parameters, as it ensures that the parameter space is sampled more evenly.\n", |
48 | 48 | "\n", |
|
311 | 311 | "id": "9ef59dba", |
312 | 312 | "metadata": {}, |
313 | 313 | "source": [ |
314 | | - "You'll notice that above, unlike in the first tutorial, we didn't set the optical depth `tau_v` directy on the emission model. This is because we want it to vary between galaxies, so we will instead pass this attrivute to `GalaxyBasis` to set it on the individual `Galaxy` level." |
| 314 | + "You'll notice that above, unlike in the first tutorial, we didn't set the optical depth `tau_v` directy on the emission model. This is because we want it to vary between galaxies, so we will instead pass this attribute to `GalaxyBasis` to set it on the individual `Galaxy` level." |
315 | 315 | ] |
316 | 316 | }, |
317 | 317 | { |
|
396 | 396 | "id": "2aba55cb", |
397 | 397 | "metadata": {}, |
398 | 398 | "source": [ |
399 | | - "Before we make our mock library, we also choose to save the `max_age` parameter. This is a derived parameter based on the redshift of the galaxy and is useful for later analysis so that we can easily reconstruct the original parameter space." |
| 399 | + "We also save the `max_age` parameter, which is a derived parameter based on the redshift of the galaxy. This is useful for later analysis so we can easily reconstruct the original parameter space." |
400 | 400 | ] |
401 | 401 | }, |
402 | 402 | { |
|
493 | 493 | "- Supplementary parameters array: An empty supplementary parameters array in this case, designed to store optional derived quantities such as star formation rates, or the surviving stellar mass\n", |
494 | 494 | "- Model Group: This stores information about the emission model and instrument used, allowing us recreate the emission model and instrument later if we need to\n", |
495 | 495 | "\n", |
496 | | - "It's worth noting that the only required arrays are the 'parameters' and 'photometry' datasets. So you can entirely avoid using Synthesizer and build models externally using your code and method of choice, as long as you can produde a HDF5 array with the same simple format you will be able to use the SBI functioality of synference with your code. Please see the tutorial where we train a model from the outputs of the hydrodynamical simulation SPHINX for an example." |
| 496 | + "It's worth noting that the only required arrays are the 'parameters' and 'photometry' datasets. So you can entirely avoid using Synthesizer and build models externally using your code and method of choice, as long as you can produde a HDF5 array with the same simple format you will be able to use the SBI functionality of Synference with your code. Please see [this example](../library_gen/bring_your_own_library.ipynb), where we train a model from the outputs of the hydrodynamical simulation SPHINX." |
497 | 497 | ] |
498 | 498 | }, |
499 | 499 | { |
|
503 | 503 | "source": [ |
504 | 504 | "## Plotting a galaxy from our model\n", |
505 | 505 | "\n", |
506 | | - "Lastly, Synference has some debug methods to plot specific or random individual galaxy SEDs, photometry and star formation histories - `plot_galaxy` and `plot_random_galaxy`. Below we plot a random galaxy from the model. " |
| 506 | + "Synference has some debug methods to plot specific or random individual galaxy SEDs, photometry and star formation histories - `plot_galaxy` and `plot_random_galaxy`. Below we plot a random galaxy from the model. " |
507 | 507 | ] |
508 | 508 | }, |
509 | 509 | { |
|
0 commit comments