Skip to content
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
1 change: 0 additions & 1 deletion doc/source/tutorials/aquad/delta_forward.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -281,7 +281,6 @@
" groupsets=[{\n",
" \"groups_from_to\": (0, 0),\n",
" \"angular_quadrature\": pquad,\n",
" \"angle_aggregation_num_subsets\": 1,\n",
" \"inner_linear_method\": \"petsc_gmres\",\n",
" \"l_abs_tol\": 1.0e-8,\n",
" \"l_max_its\": 100,\n",
Expand Down
1 change: 0 additions & 1 deletion doc/source/tutorials/aquad/forward_peaked_g099.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -264,7 +264,6 @@
" groupsets=[{\n",
" \"groups_from_to\": (0, 0),\n",
" \"angular_quadrature\": pquad,\n",
" \"angle_aggregation_num_subsets\": 1,\n",
" \"inner_linear_method\": \"petsc_gmres\",\n",
" \"l_abs_tol\": 1.0e-8,\n",
" \"l_max_its\": 300,\n",
Expand Down
1 change: 0 additions & 1 deletion doc/source/tutorials/lbs/keigen/cmfd.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -316,7 +316,6 @@
" {\n",
" \"groups_from_to\": [0, num_groups - 1],\n",
" \"angular_quadrature\": pquad,\n",
" \"angle_aggregation_num_subsets\": 1,\n",
" \"inner_linear_method\": \"petsc_gmres\",\n",
" \"l_abs_tol\": 1.0e-7,\n",
" \"l_max_its\": 300,\n",
Expand Down
1 change: 0 additions & 1 deletion doc/source/tutorials/lbs/primer/forward_example.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -314,7 +314,6 @@
" {\n",
" \"groups_from_to\": (0, 0),\n",
" \"angular_quadrature\": pquad,\n",
" \"angle_aggregation_num_subsets\": 1,\n",
" \"inner_linear_method\": \"petsc_gmres\",\n",
" \"l_abs_tol\": 1.0e-6,\n",
" \"l_max_its\": 300,\n",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -278,7 +278,6 @@
" {\n",
" \"groups_from_to\": (0, num_groups-1),\n",
" \"angular_quadrature\": pquad,\n",
" \"angle_aggregation_num_subsets\": 1,\n",
" \"inner_linear_method\": \"petsc_gmres\",\n",
" \"l_abs_tol\": 1.0e-6,\n",
" \"l_max_its\": 300,\n",
Expand Down
1 change: 0 additions & 1 deletion doc/source/userguide/groupsets.rst
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ The main groupset fields exposed in the Python API are:
* ``groups_from_to``
* ``angular_quadrature``
* ``angle_aggregation_type``
* ``angle_aggregation_num_subsets``
* ``inner_linear_method``
* ``l_abs_tol``
* ``l_max_its``
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1769,112 +1769,97 @@ DiscreteOrdinatesProblem::InitFluxDataStructures(LBSGroupset& groupset)
const auto& sweep_ordering = quadrature_spds_map_[groupset.quadrature][so_id];
const auto& fluds_common_data = *quadrature_fluds_commondata_map_[groupset.quadrature][so_id];

// Compute direction subsets
const auto dir_subsets = MakeSubSets(so_grouping.size(), groupset.master_num_ang_subsets);
std::vector<size_t> angle_indices(so_grouping.begin(), so_grouping.end());

for (const auto& dir_ss_info : dir_subsets)
if (sweep_type_ == "AAH")
{
const auto& dir_ss_begin = dir_ss_info.ss_begin;
const auto& dir_ss_end = dir_ss_info.ss_end;
const auto& dir_ss_size = dir_ss_info.ss_size;

std::vector<size_t> angle_indices(dir_ss_size, 0);
std::shared_ptr<FLUDS> fluds;
if (use_gpus_)
{
size_t k = 0;
for (size_t n = dir_ss_begin; n <= dir_ss_end; ++n)
angle_indices[k++] = so_grouping[n];
fluds = CreateAAHD_FLUDS(gs_num_grps, angle_indices.size(), fluds_common_data);
}

if (sweep_type_ == "AAH")
else
{
std::shared_ptr<FLUDS> fluds;
if (use_gpus_)
{
fluds = CreateAAHD_FLUDS(gs_num_grps, angle_indices.size(), fluds_common_data);
}
else
{
fluds = std::make_shared<AAH_FLUDS>(
gs_num_grps,
angle_indices.size(),
dynamic_cast<const AAH_FLUDSCommonData&>(fluds_common_data));
}
fluds =
std::make_shared<AAH_FLUDS>(gs_num_grps,
angle_indices.size(),
dynamic_cast<const AAH_FLUDSCommonData&>(fluds_common_data));
}

std::shared_ptr<AngleSet> angle_set;
if (use_gpus_)
{
angle_set = CreateAAHD_AngleSet(angle_set_id++,
groupset,
*sweep_ordering,
fluds,
angle_indices,
sweep_boundaries_,
options_.max_mpi_message_size,
*grid_local_comm_set_);
}
else
{
angle_set = std::make_shared<AAH_AngleSet>(angle_set_id++,
groupset,
*sweep_ordering,
fluds,
angle_indices,
sweep_boundaries_,
options_.max_mpi_message_size,
*grid_local_comm_set_);
}
groupset.angle_agg->GetAngleSetGroups().push_back(angle_set);
std::shared_ptr<AngleSet> angle_set;
if (use_gpus_)
{
angle_set = CreateAAHD_AngleSet(angle_set_id++,
groupset,
*sweep_ordering,
fluds,
angle_indices,
sweep_boundaries_,
options_.max_mpi_message_size,
*grid_local_comm_set_);
}
else if (sweep_type_ == "CBC")
else
{
std::shared_ptr<FLUDS> fluds;
if (use_gpus_)
{
fluds = CreateCBCD_FLUDS(gs_num_grps,
angle_indices.size(),
grid_->local_cells.size(),
fluds_common_data,
groupset.psi_uk_man_,
*discretization_,
(not GetPsiNewLocal()[groupset.id].empty()));
}
else
{
fluds =
std::make_shared<CBC_FLUDS>(gs_num_grps,
angle_indices.size(),
dynamic_cast<const CBC_FLUDSCommonData&>(fluds_common_data),
groupset.psi_uk_man_,
*discretization_);
}

std::shared_ptr<AngleSet> angle_set;
if (use_gpus_)
{
angle_set = CreateCBCD_AngleSet(angle_set_id++,
groupset,
*sweep_ordering,
fluds,
angle_indices,
sweep_boundaries_,
*grid_local_comm_set_);
}
else
{
angle_set = std::make_shared<CBC_AngleSet>(angle_set_id++,
groupset,
*sweep_ordering,
fluds,
angle_indices,
sweep_boundaries_,
*grid_local_comm_set_);
}
angle_set = std::make_shared<AAH_AngleSet>(angle_set_id++,
groupset,
*sweep_ordering,
fluds,
angle_indices,
sweep_boundaries_,
options_.max_mpi_message_size,
*grid_local_comm_set_);
}
groupset.angle_agg->GetAngleSetGroups().push_back(angle_set);
}
else if (sweep_type_ == "CBC")
{
std::shared_ptr<FLUDS> fluds;
if (use_gpus_)
{
fluds = CreateCBCD_FLUDS(gs_num_grps,
angle_indices.size(),
grid_->local_cells.size(),
fluds_common_data,
groupset.psi_uk_man_,
*discretization_,
(not GetPsiNewLocal()[groupset.id].empty()));
}
else
{
fluds =
std::make_shared<CBC_FLUDS>(gs_num_grps,
angle_indices.size(),
dynamic_cast<const CBC_FLUDSCommonData&>(fluds_common_data),
groupset.psi_uk_man_,
*discretization_);
}

groupset.angle_agg->GetAngleSetGroups().push_back(angle_set);
std::shared_ptr<AngleSet> angle_set;
if (use_gpus_)
{
angle_set = CreateCBCD_AngleSet(angle_set_id++,
groupset,
*sweep_ordering,
fluds,
angle_indices,
sweep_boundaries_,
*grid_local_comm_set_);
}
else
OpenSnInvalidArgument("Unsupported sweeptype \"" + sweep_type_ + "\"");
} // for an_ss
{
angle_set = std::make_shared<CBC_AngleSet>(angle_set_id++,
groupset,
*sweep_ordering,
fluds,
angle_indices,
sweep_boundaries_,
*grid_local_comm_set_);
}

groupset.angle_agg->GetAngleSetGroups().push_back(angle_set);
}
else
OpenSnInvalidArgument("Unsupported sweeptype \"" + sweep_type_ + "\"");
} // for so_grouping

groupset.angle_agg->BuildDirnumToAnglesetMap();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,11 +30,6 @@ LBSGroupset::GetInputParameters()
"angular_quadrature", nullptr, "A handle to an angular quadrature");
params.AddOptionalParameter(
"angle_aggregation_type", "polar", "The angle aggregation method to use during sweeping");
params.AddOptionalParameter("angle_aggregation_num_subsets",
1,
"The number of subsets to apply to sets of angles that have been "
"aggregated. This is useful for increasing pipeline size for "
"parallel simulations");

// Iterative method
params.AddOptionalParameter("inner_linear_method",
Expand Down Expand Up @@ -94,7 +89,6 @@ LBSGroupset::GetInputParameters()
// Constraints
params.ConstrainParameterRange("angle_aggregation_type",
AllowableRangeList::New({"polar", "single", "azimuthal"}));
params.ConstrainParameterRange("angle_aggregation_num_subsets", AllowableRangeLowLimit::New(1));
params.ConstrainParameterRange(
"inner_linear_method",
AllowableRangeList::New(
Expand Down Expand Up @@ -126,7 +120,6 @@ LBSGroupset::Init(int aid)
size = 0;
quadrature = nullptr;
angle_agg = nullptr;
master_num_ang_subsets = 1;
iterative_method = LinearSystemSolver::IterativeMethod::PETSC_RICHARDSON;
angleagg_method = AngleAggregationType::POLAR;
residual_tolerance = 1.0e-6;
Expand Down Expand Up @@ -189,8 +182,6 @@ LBSGroupset::LBSGroupset( // NOLINT(cppcoreguidelines-pro-type-member-init)
else if (angle_agg_typestr == "azimuthal")
angleagg_method = AngleAggregationType::AZIMUTHAL;

master_num_ang_subsets = params.GetParamValue<int>("angle_aggregation_num_subsets");

// Inner solver
const auto inner_linear_method = params.GetParamValue<std::string>("inner_linear_method");
if (inner_linear_method == "classic_richardson")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,8 +67,6 @@ class LBSGroupset
UniqueSOGroupings unique_so_groupings;
DirIDToSOMap dir_id_to_so_map;

int master_num_ang_subsets;

LinearSystemSolver::IterativeMethod iterative_method;
AngleAggregationType angleagg_method;
double residual_tolerance;
Expand Down
4 changes: 0 additions & 4 deletions python/lib/solver.cc
Original file line number Diff line number Diff line change
Expand Up @@ -704,8 +704,6 @@ WrapLBS(py::module& slv)
Handle to an angular quadrature.
- angle_aggregation_type: {'polar', 'single', 'azimuthal'}, default='polar'
Angle aggregation method to use during sweeping.
- angle_aggregation_num_subsets: int, default=1
Number of angle subsets used for aggregation.
- inner_linear_method: {'classic_richardson', 'petsc_richardson',
'petsc_gmres', 'petsc_bicgstab'}, default='petsc_richardson'
Iterative method used for inner linear solves.
Expand Down Expand Up @@ -1205,8 +1203,6 @@ WrapLBS(py::module& slv)
Handle to an angular quadrature.
- angle_aggregation_type: {'polar', 'single', 'azimuthal'}, default='polar'
Angle aggregation method to use during sweeping.
- angle_aggregation_num_subsets: int, default=1
Number of angle subsets used for aggregation.
- inner_linear_method: {'classic_richardson', 'petsc_richardson',
'petsc_gmres', 'petsc_bicgstab'}, default='petsc_richardson'
Iterative method used for inner linear solves.
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading