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

Uniform Grid Missing Topology Bug #1319

Merged
merged 1 commit into from
Jun 27, 2024
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
Original file line number Diff line number Diff line change
Expand Up @@ -3361,26 +3361,25 @@ VTKHUniformGrid::execute()
}
std::shared_ptr<VTKHCollection> collection = data_object->as_vtkh_collection();

bool throw_error = false;
std::string topo_name = detail::resolve_topology(params(),
this->name(),
collection,
throw_error);
if(topo_name == "")
std::string field = params()["field"].as_string();
if(!collection->has_field(field))
{
bool throw_error = false;
detail::field_error(field, this->name(), collection, throw_error);
// this creates a data object with an invalid soource
set_output<DataObject>(new DataObject());
return;
}


std::string topo_name = collection->field_topology(field);
vtkh::DataSet &data = collection->dataset_by_topology(topo_name);

vtkm::Bounds d_bounds = data.GetGlobalBounds();
vtkm::Float64 x_extents = d_bounds.X.Length() + 1; //add one b/c we are
vtkm::Float64 y_extents = d_bounds.Y.Length() + 1; //setting num points
vtkm::Float64 z_extents = d_bounds.Z.Length() + 1; //(not cells) in each dim

std::string field = params()["field"].as_string();
vtkm::Float64 invalid_value = 0.0;

using Vec3f = vtkm::Vec<vtkm::Float64,3>;
Expand Down