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

Reeber param input doc #102

Open
wants to merge 3 commits into
base: development
Choose a base branch
from
Open
Show file tree
Hide file tree
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
6 changes: 2 additions & 4 deletions Docs/sphinx_documentation/source/AGN.rst
Original file line number Diff line number Diff line change
Expand Up @@ -188,10 +188,8 @@ Parameter Definition Acceptab
=================================== =================================== ===================================== =========
**reeber.halo_int** timesteps between halo finder calls Integer -1 (none)
**reeber.negate** allow negative values for analysis 0 if false, 1 if true 1
**reeber.halo_density_vars** density variable list density, particle_mass_density “density”
**reeber.halo_extrema_threshold** extrema threshold for haloes Real 200.
**reeber.halo_component_threshold** component threshold for haloes Real 82.
**reeber.absolute_halo_thresholds** are halo thresholds absolute 0 if multiples of mean, 1 if absolute 0
**reeber.halo_component_threshold** component threshold for haloes Real 81.66
**reeber.min_halo_n_cells** min. number of halo cells Integer 10
=================================== =================================== ===================================== =========

[Table:Reeber-inputs]
10 changes: 5 additions & 5 deletions Docs/sphinx_documentation/source/InSitu.rst
Original file line number Diff line number Diff line change
Expand Up @@ -56,16 +56,16 @@ Note that these codes are in separate repositories and are not included in Nyx d
If you intend to use in situ halo finding, you should clone Reeber from its
`GitHub page <https://github.com/mrzv/reeber>`_ and follow the installation instructions provided there.

In the Nyx inputs file, one should specify the time step interval for halo finder, fields which will be
used (to use the total density, one should specify both (gas) ``density`` and ``particle_mass_density``),
and thresholds of the boundary and extrema values::
.. In the Nyx inputs file, one should specify the time step interval for halo finder, fields which will be
.. used (to use the total density, one should specify both (gas) ``density`` and ``particle_mass_density``),
.. and thresholds of the boundary and extrema values::
In the Nyx inputs file, one should specify the time step interval for the halo finder, whether to permit negative values for analysis, the boundary isovalue threshold, and the minimum number of cells required for a region to be considered a halo::

# Halo Finder
reeber.halo_int = 1
reeber.negate = 1
reeber.halo_density_vars = density particle_mass_density
reeber.halo_extrema_threshold = 20
reeber.halo_component_threshold = 10
reeber.min_n_halo_cells = 10

# Call reeber insitu analysis
insitu.reeber_int = 100
Expand Down
12 changes: 7 additions & 5 deletions Exec/LyA/inputs
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
# ------------------ INPUTS TO MAIN PROGRAM -------------------
max_step = 10000000

# use managed memory
amrex.the_arena_is_managed=1

nyx.ppm_type = 1
nyx.use_colglaz = 0
nyx.corner_coupling = 1
Expand Down Expand Up @@ -140,12 +143,11 @@ nyx.plot_z_values = 7.0 6.0 5.0 4.0 3.0 2.0
amr.plot_vars = density xmom ymom zmom rho_e Temp phi_grav
amr.derive_plot_vars = particle_mass_density particle_count

# Halo Finder
#nyx.analysis_z_values = 150 10 5 4 3 2
reeber.halo_int = 1
# Halo finder
reeber.min_halo_n_cells = 10
reeber.negate = 1
reeber.halo_density_vars = density particle_mass_density
reeber.halo_extrema_threshold = 20
#reeber.halo_density_vars = density particle_mass_density
#reeber.halo_extrema_threshold = 20
reeber.halo_component_threshold = 10
#nyx.mass_halo_min = 1.e11
#nyx.mass_seed = 1.e6
Expand Down
5 changes: 5 additions & 0 deletions Source/Driver/Nyx.H
Original file line number Diff line number Diff line change
Expand Up @@ -996,6 +996,11 @@ protected:
// Seed mass of SMBH
//
static amrex::Real mass_seed;

static int min_halo_n_cells;
static bool halo_negate;
static amrex::Real halo_component_threshold;

#endif

// Previous maximum number of steps for sundials
Expand Down
8 changes: 8 additions & 0 deletions Source/Driver/Nyx.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -204,6 +204,9 @@ Real Nyx::he_species = 0.24;
#ifdef REEBER
Real Nyx::mass_halo_min = 1.e10;
Real Nyx::mass_seed = 1.e5;
Real Nyx::halo_component_threshold = 81.66;
int Nyx::min_halo_n_cells = 10;
bool Nyx::halo_negate = true;
#endif

#ifdef _OPENMP
Expand Down Expand Up @@ -445,6 +448,11 @@ Nyx::read_params ()
#ifdef REEBER
pp_nyx.query("mass_halo_min", mass_halo_min);
pp_nyx.query("mass_seed", mass_seed);

ParmParse pp_reeber("reeber");
pp_reeber.query("min_halo_n_cells", min_halo_n_cells);
pp_reeber.query("halo_component_threshold", halo_component_threshold);
pp_reeber.query("negate", halo_negate);
#endif
}

Expand Down
5 changes: 1 addition & 4 deletions Util/reeber/src/reeber.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -598,10 +598,7 @@ void Nyx::runReeberAnalysis(Vector<MultiFab*>& new_state,

diy::DiscreteBounds diy_domain(3);

// TODO: take rho, min_halo_n_cells as parameters
Real min_halo_n_cells = 10;
Real rho = 81.66;

Real rho = halo_component_threshold;
Real absolute_rho = (Nyx::average_dm_density + Nyx::average_gas_density) * rho;
bool negate = true; // sweep superlevel sets, highest density = root
int finest_level = parent->finestLevel();
Expand Down
Loading