-
-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
new Documentation for setting amount of threads used in STARDIS simul… (
#228) * new Documentation for setting amount of threads used in STARDIS simulation * more info added: parallelized stuff and when to use * direcotry managment and added to index.rst * name change: Using Stardis in Parallel
- Loading branch information
1 parent
ec588eb
commit ab7e61d
Showing
2 changed files
with
62 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
{ | ||
"cells": [ | ||
{ | ||
"cell_type": "markdown", | ||
"metadata": {}, | ||
"source": [ | ||
"### Setting number of threads used in running a STARDIS simulation" | ||
] | ||
}, | ||
{ | ||
"cell_type": "markdown", | ||
"metadata": {}, | ||
"source": [ | ||
"When you run a STARDIS simulation, the yaml file determines how many threads are used. By default, it will only use 1 thread. The more threads you set a simulation to use, the more computing power the simulation will take advantage of for calculating line opacity and ray tracing steps (as both of these are parallelized in STARDIS). **Setting n_threads to 0 will make the simulation use all available threads.**" | ||
] | ||
}, | ||
{ | ||
"cell_type": "markdown", | ||
"metadata": {}, | ||
"source": [ | ||
"Here is a what a yaml file that has the STARDIS simulation use 3 threads will look like\n", | ||
"\n", | ||
"``` yaml\n", | ||
"stardis_config_version: 1.0\n", | ||
"n_threads: 3 # <----------- add your 'n_threads: <integer>' here\n", | ||
"atom_data: kurucz_cd23_chianti_H_He.h5\n", | ||
"model:\n", | ||
" ...\n", | ||
"```\n" | ||
] | ||
}, | ||
{ | ||
"cell_type": "markdown", | ||
"metadata": {}, | ||
"source": [ | ||
"One reason you may want to consider increasing threads used is when computing spectra with large numbers (i.e. 10,000 or more) of wavelength points." | ||
] | ||
} | ||
], | ||
"metadata": { | ||
"kernelspec": { | ||
"display_name": "stardis", | ||
"language": "python", | ||
"name": "python3" | ||
}, | ||
"language_info": { | ||
"codemirror_mode": { | ||
"name": "ipython", | ||
"version": 3 | ||
}, | ||
"file_extension": ".py", | ||
"mimetype": "text/x-python", | ||
"name": "python", | ||
"nbconvert_exporter": "python", | ||
"pygments_lexer": "ipython3", | ||
"version": "3.12.4" | ||
} | ||
}, | ||
"nbformat": 4, | ||
"nbformat_minor": 2 | ||
} |