resqpy 5.1.5__tar.gz → 5.1.6__tar.gz
Sign up to get free protection for your applications and to get access to all the features.
- {resqpy-5.1.5 → resqpy-5.1.6}/PKG-INFO +1 -1
- {resqpy-5.1.5 → resqpy-5.1.6}/pyproject.toml +1 -1
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/__init__.py +1 -1
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/grid/_extract_functions.py +6 -1
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/grid_surface/_find_faces.py +129 -65
- {resqpy-5.1.5 → resqpy-5.1.6}/LICENSE +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/README.md +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/crs.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/derived_model/__init__.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/derived_model/_add_edges_per_column_property_array.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/derived_model/_add_faults.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/derived_model/_add_one_blocked_well_property.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/derived_model/_add_one_grid_property_array.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/derived_model/_add_single_cell_grid.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/derived_model/_add_wells_from_ascii_file.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/derived_model/_add_zone_by_layer_property.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/derived_model/_coarsened_grid.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/derived_model/_common.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/derived_model/_copy_grid.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/derived_model/_drape_to_surface.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/derived_model/_extract_box.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/derived_model/_extract_box_for_well.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/derived_model/_fault_throw_scaling.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/derived_model/_gather_ensemble.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/derived_model/_interpolated_grid.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/derived_model/_local_depth_adjustment.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/derived_model/_refined_grid.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/derived_model/_tilted_grid.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/derived_model/_unsplit_grid.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/derived_model/_zonal_grid.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/derived_model/_zone_layer_ranges_from_array.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/fault/__init__.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/fault/_gcs_functions.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/fault/_grid_connection_set.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/grid/__init__.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/grid/_cell_properties.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/grid/_connection_sets.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/grid/_create_grid_xml.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/grid/_defined_geometry.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/grid/_face_functions.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/grid/_faults.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/grid/_grid.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/grid/_grid_types.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/grid/_intervals_info.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/grid/_pillars.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/grid/_pixel_maps.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/grid/_points_functions.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/grid/_regular_grid.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/grid/_transmissibility.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/grid/_write_hdf5_from_caches.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/grid/_write_nexus_corp.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/grid/_xyz.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/grid_surface/__init__.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/grid_surface/_blocked_well_populate.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/grid_surface/_grid_skin.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/grid_surface/_grid_surface.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/grid_surface/_trajectory_intersects.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/grid_surface/grid_surface_cuda.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/lines/__init__.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/lines/_common.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/lines/_polyline.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/lines/_polyline_set.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/model/__init__.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/model/_catalogue.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/model/_context.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/model/_forestry.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/model/_grids.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/model/_hdf5.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/model/_model.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/model/_xml.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/multi_processing/__init__.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/multi_processing/_multiprocessing.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/multi_processing/wrappers/__init__.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/multi_processing/wrappers/blocked_well_mp.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/multi_processing/wrappers/grid_surface_mp.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/multi_processing/wrappers/mesh_mp.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/olio/__init__.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/olio/ab_toolbox.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/olio/base.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/olio/box_utilities.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/olio/class_dict.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/olio/consolidation.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/olio/data/build.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/olio/data/properties.json +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/olio/dataframe.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/olio/exceptions.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/olio/factors.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/olio/fine_coarse.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/olio/grid_functions.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/olio/intersection.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/olio/keyword_files.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/olio/load_data.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/olio/point_inclusion.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/olio/random_seed.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/olio/read_nexus_fault.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/olio/relperm.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/olio/simple_lines.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/olio/time.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/olio/trademark.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/olio/transmission.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/olio/triangulation.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/olio/uuid.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/olio/vdb.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/olio/vector_utilities.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/olio/volume.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/olio/wellspec_keywords.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/olio/write_data.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/olio/write_hdf5.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/olio/xml_et.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/olio/xml_namespaces.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/olio/zmap_reader.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/organize/__init__.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/organize/_utils.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/organize/boundary_feature.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/organize/boundary_feature_interpretation.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/organize/earth_model_interpretation.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/organize/fault_interpretation.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/organize/fluid_boundary_feature.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/organize/frontier_feature.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/organize/generic_interpretation.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/organize/genetic_boundary_feature.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/organize/geobody_boundary_interpretation.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/organize/geobody_feature.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/organize/geobody_interpretation.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/organize/geologic_unit_feature.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/organize/horizon_interpretation.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/organize/organization_feature.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/organize/rock_fluid_unit_feature.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/organize/structural_organization_interpretation.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/organize/tectonic_boundary_feature.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/organize/wellbore_feature.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/organize/wellbore_interpretation.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/property/__init__.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/property/_collection_add_part.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/property/_collection_create_xml.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/property/_collection_get_attributes.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/property/_collection_support.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/property/_property.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/property/attribute_property_set.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/property/grid_property_collection.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/property/property_collection.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/property/property_common.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/property/property_kind.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/property/string_lookup.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/property/well_interval_property.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/property/well_interval_property_collection.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/property/well_log.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/property/well_log_collection.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/rq_import/__init__.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/rq_import/_add_ab_properties.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/rq_import/_add_surfaces.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/rq_import/_grid_from_cp.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/rq_import/_import_nexus.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/rq_import/_import_vdb_all_grids.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/rq_import/_import_vdb_ensemble.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/strata/__init__.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/strata/_binary_contact_interpretation.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/strata/_geologic_unit_interpretation.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/strata/_strata_common.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/strata/_stratigraphic_column.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/strata/_stratigraphic_column_rank.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/strata/_stratigraphic_unit_feature.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/strata/_stratigraphic_unit_interpretation.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/surface/__init__.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/surface/_base_surface.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/surface/_combined_surface.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/surface/_mesh.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/surface/_pointset.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/surface/_surface.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/surface/_tri_mesh.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/surface/_tri_mesh_stencil.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/surface/_triangulated_patch.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/time_series/__init__.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/time_series/_any_time_series.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/time_series/_from_nexus_summary.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/time_series/_functions.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/time_series/_geologic_time_series.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/time_series/_time_duration.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/time_series/_time_series.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/unstructured/__init__.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/unstructured/_hexa_grid.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/unstructured/_prism_grid.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/unstructured/_pyramid_grid.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/unstructured/_tetra_grid.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/unstructured/_unstructured_grid.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/weights_and_measures/__init__.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/weights_and_measures/nexus_units.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/weights_and_measures/weights_and_measures.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/well/__init__.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/well/_blocked_well.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/well/_deviation_survey.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/well/_md_datum.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/well/_trajectory.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/well/_wellbore_frame.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/well/_wellbore_marker.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/well/_wellbore_marker_frame.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/well/blocked_well_frame.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/well/well_object_funcs.py +0 -0
- {resqpy-5.1.5 → resqpy-5.1.6}/resqpy/well/well_utils.py +0 -0
@@ -445,7 +445,12 @@ def extract_stratigraphy(grid):
|
|
445
445
|
object = grid,
|
446
446
|
array_attribute = 'stratigraphic_units',
|
447
447
|
dtype = 'int')
|
448
|
-
|
448
|
+
if (len(grid.stratigraphic_units) != grid.nk_plus_k_gaps):
|
449
|
+
log.error("Unable to load Stratigraphy," +
|
450
|
+
f" the number of stratigraphic units {len(grid.stratigraphic_units)}" +
|
451
|
+
f" does not equal the number of layers plus gaps {grid.nk_plus_k_gaps}")
|
452
|
+
grid.stratigraphic_column_rank_uuid = None
|
453
|
+
grid.stratigraphic_units = None
|
449
454
|
|
450
455
|
|
451
456
|
def extract_children(grid):
|
@@ -1167,68 +1167,6 @@ def find_faces_to_represent_surface_regular_optimised(grid,
|
|
1167
1167
|
else:
|
1168
1168
|
return None
|
1169
1169
|
|
1170
|
-
log.debug("converting face sets into grid connection set")
|
1171
|
-
# NB: kji0 arrays in internal face protocol: used as cell_kji0 with polarity of 1
|
1172
|
-
# property lists have elements replaced with sorted and filtered equivalents
|
1173
|
-
gcs = rqf.GridConnectionSet.from_faces_indices(grid = grid,
|
1174
|
-
k_faces_kji0 = k_faces_kji0,
|
1175
|
-
j_faces_kji0 = j_faces_kji0,
|
1176
|
-
i_faces_kji0 = i_faces_kji0,
|
1177
|
-
remove_duplicates = not patchwork,
|
1178
|
-
k_properties = k_props,
|
1179
|
-
j_properties = j_props,
|
1180
|
-
i_properties = i_props,
|
1181
|
-
feature_name = name,
|
1182
|
-
feature_type = feature_type,
|
1183
|
-
create_organizing_objects_where_needed = True,
|
1184
|
-
title = title)
|
1185
|
-
# log.debug('finished coversion to gcs')
|
1186
|
-
|
1187
|
-
# NB. following assumes faces have been added to gcs in a particular order!
|
1188
|
-
all_tris = None
|
1189
|
-
if return_triangles:
|
1190
|
-
# log.debug('preparing triangles array')
|
1191
|
-
k_triangles = np.empty((0,), dtype = np.int32) if k_props is None else k_props.pop(0)
|
1192
|
-
j_triangles = np.empty((0,), dtype = np.int32) if j_props is None else j_props.pop(0)
|
1193
|
-
i_triangles = np.empty((0,), dtype = np.int32) if i_props is None else i_props.pop(0)
|
1194
|
-
all_tris = np.concatenate((k_triangles, j_triangles, i_triangles), axis = 0)
|
1195
|
-
# log.debug(f'gcs count: {gcs.count}; all triangles shape: {all_tris.shape}')
|
1196
|
-
assert all_tris.shape == (gcs.count,)
|
1197
|
-
|
1198
|
-
# NB. following assumes faces have been added to gcs in a particular order!
|
1199
|
-
all_depths = None
|
1200
|
-
if return_depths:
|
1201
|
-
# log.debug('preparing depths array')
|
1202
|
-
k_depths = np.empty((0,), dtype = np.float64) if k_props is None else k_props.pop(0)
|
1203
|
-
j_depths = np.empty((0,), dtype = np.float64) if j_props is None else j_props.pop(0)
|
1204
|
-
i_depths = np.empty((0,), dtype = np.float64) if i_props is None else i_props.pop(0)
|
1205
|
-
all_depths = np.concatenate((k_depths, j_depths, i_depths), axis = 0)
|
1206
|
-
# log.debug(f'gcs count: {gcs.count}; all depths shape: {all_depths.shape}')
|
1207
|
-
assert all_depths.shape == (gcs.count,)
|
1208
|
-
|
1209
|
-
# NB. following assumes faces have been added to gcs in a particular order!
|
1210
|
-
all_offsets = None
|
1211
|
-
if return_offsets:
|
1212
|
-
# log.debug('preparing offsets array')
|
1213
|
-
k_offsets = np.empty((0,), dtype = np.float64) if k_props is None else k_props[0]
|
1214
|
-
j_offsets = np.empty((0,), dtype = np.float64) if j_props is None else j_props[0]
|
1215
|
-
i_offsets = np.empty((0,), dtype = np.float64) if i_props is None else i_props[0]
|
1216
|
-
all_offsets = _all_offsets(grid.crs, k_offsets, j_offsets, i_offsets)
|
1217
|
-
# log.debug(f'gcs count: {gcs.count}; all offsets shape: {all_offsets.shape}')
|
1218
|
-
assert all_offsets.shape == (gcs.count,)
|
1219
|
-
|
1220
|
-
all_flange = None
|
1221
|
-
if return_flange_bool:
|
1222
|
-
# log.debug('preparing flange array')
|
1223
|
-
flange_bool_uuid = surface.model.uuid(title = "flange bool",
|
1224
|
-
obj_type = "DiscreteProperty",
|
1225
|
-
related_uuid = surface.uuid)
|
1226
|
-
assert (flange_bool_uuid is not None), f"No flange bool property found for surface: {surface.title}"
|
1227
|
-
flange_bool = rqp.Property(surface.model, uuid = flange_bool_uuid)
|
1228
|
-
flange_array = flange_bool.array_ref(dtype = bool)
|
1229
|
-
all_flange = np.take(flange_array, all_tris)
|
1230
|
-
assert all_flange.shape == (gcs.count,)
|
1231
|
-
|
1232
1170
|
# note: following is a grid cells property, not a gcs property
|
1233
1171
|
bisector = None
|
1234
1172
|
if return_bisector:
|
@@ -1245,6 +1183,15 @@ def find_faces_to_represent_surface_regular_optimised(grid,
|
|
1245
1183
|
bisector = column_bisector_from_face_indices((grid.nj, grid.ni), j_faces_ji0, i_faces_ji0)
|
1246
1184
|
# log.debug('finished preparing columns bisector')
|
1247
1185
|
elif patchwork:
|
1186
|
+
# NB. following assumes faces have been added to gcs in a particular order!
|
1187
|
+
all_tris = None
|
1188
|
+
assert return_triangles
|
1189
|
+
# log.debug('preparing triangles array')
|
1190
|
+
k_triangles = np.empty((0,), dtype = np.int32) if k_props is None else k_props[0]
|
1191
|
+
j_triangles = np.empty((0,), dtype = np.int32) if j_props is None else j_props[0]
|
1192
|
+
i_triangles = np.empty((0,), dtype = np.int32) if i_props is None else i_props[0]
|
1193
|
+
all_tris = np.concatenate((k_triangles, j_triangles, i_triangles), axis = 0)
|
1194
|
+
# log.debug(f'gcs count: {gcs.count}; all triangles shape: {all_tris.shape}')
|
1248
1195
|
n_patches = surface.number_of_patches()
|
1249
1196
|
log.info(f'preparing composite cells bisector for surface: {surface.title}; number of patches: {n_patches}')
|
1250
1197
|
nkf = 0 if k_faces_kji0 is None else len(k_faces_kji0)
|
@@ -1328,6 +1275,98 @@ def find_faces_to_represent_surface_regular_optimised(grid,
|
|
1328
1275
|
if is_curtain:
|
1329
1276
|
bisector = bisector[0] # reduce to a columns property
|
1330
1277
|
|
1278
|
+
# if using patchwork, filter all faces (and properties) to those within (or on boundary of) volume corresponding to patch
|
1279
|
+
if patchwork:
|
1280
|
+
if k_faces_kji0 is not None:
|
1281
|
+
selection = filter_faces(k_faces_kji0, patch_indices_k, patch_indices, 0)
|
1282
|
+
if np.any(selection):
|
1283
|
+
k_faces_kji0 = k_faces_kji0[selection]
|
1284
|
+
if k_props is not None:
|
1285
|
+
k_props = [prop[selection] for prop in k_props]
|
1286
|
+
else:
|
1287
|
+
k_faces_kji0 = None
|
1288
|
+
k_props = None
|
1289
|
+
if j_faces_kji0 is not None:
|
1290
|
+
selection = filter_faces(j_faces_kji0, patch_indices_j, patch_indices, 1)
|
1291
|
+
if np.any(selection):
|
1292
|
+
j_faces_kji0 = j_faces_kji0[selection]
|
1293
|
+
if j_props is not None:
|
1294
|
+
j_props = [prop[selection] for prop in j_props]
|
1295
|
+
else:
|
1296
|
+
j_faces_kji0 = None
|
1297
|
+
j_props = None
|
1298
|
+
if i_faces_kji0 is not None:
|
1299
|
+
selection = filter_faces(i_faces_kji0, patch_indices_i, patch_indices, 2)
|
1300
|
+
if np.any(selection):
|
1301
|
+
i_faces_kji0 = i_faces_kji0[selection]
|
1302
|
+
if i_props is not None:
|
1303
|
+
i_props = [prop[selection] for prop in i_props]
|
1304
|
+
else:
|
1305
|
+
i_faces_kji0 = None
|
1306
|
+
i_props = None
|
1307
|
+
|
1308
|
+
log.debug("converting face sets into grid connection set")
|
1309
|
+
# NB: kji0 arrays in internal face protocol: used as cell_kji0 with polarity of 1
|
1310
|
+
# property lists have elements replaced with sorted and filtered equivalents
|
1311
|
+
gcs = rqf.GridConnectionSet.from_faces_indices(grid = grid,
|
1312
|
+
k_faces_kji0 = k_faces_kji0,
|
1313
|
+
j_faces_kji0 = j_faces_kji0,
|
1314
|
+
i_faces_kji0 = i_faces_kji0,
|
1315
|
+
remove_duplicates = not patchwork,
|
1316
|
+
k_properties = k_props,
|
1317
|
+
j_properties = j_props,
|
1318
|
+
i_properties = i_props,
|
1319
|
+
feature_name = name,
|
1320
|
+
feature_type = feature_type,
|
1321
|
+
create_organizing_objects_where_needed = True,
|
1322
|
+
title = title)
|
1323
|
+
# log.debug('finished coversion to gcs')
|
1324
|
+
|
1325
|
+
# NB. following assumes faces have been added to gcs in a particular order!
|
1326
|
+
all_tris = None
|
1327
|
+
if return_triangles:
|
1328
|
+
# log.debug('preparing triangles array')
|
1329
|
+
k_triangles = np.empty((0,), dtype = np.int32) if k_props is None else k_props.pop(0)
|
1330
|
+
j_triangles = np.empty((0,), dtype = np.int32) if j_props is None else j_props.pop(0)
|
1331
|
+
i_triangles = np.empty((0,), dtype = np.int32) if i_props is None else i_props.pop(0)
|
1332
|
+
all_tris = np.concatenate((k_triangles, j_triangles, i_triangles), axis = 0)
|
1333
|
+
# log.debug(f'gcs count: {gcs.count}; all triangles shape: {all_tris.shape}')
|
1334
|
+
assert all_tris.shape == (gcs.count,)
|
1335
|
+
|
1336
|
+
# NB. following assumes faces have been added to gcs in a particular order!
|
1337
|
+
all_depths = None
|
1338
|
+
if return_depths:
|
1339
|
+
# log.debug('preparing depths array')
|
1340
|
+
k_depths = np.empty((0,), dtype = np.float64) if k_props is None else k_props.pop(0)
|
1341
|
+
j_depths = np.empty((0,), dtype = np.float64) if j_props is None else j_props.pop(0)
|
1342
|
+
i_depths = np.empty((0,), dtype = np.float64) if i_props is None else i_props.pop(0)
|
1343
|
+
all_depths = np.concatenate((k_depths, j_depths, i_depths), axis = 0)
|
1344
|
+
# log.debug(f'gcs count: {gcs.count}; all depths shape: {all_depths.shape}')
|
1345
|
+
assert all_depths.shape == (gcs.count,)
|
1346
|
+
|
1347
|
+
# NB. following assumes faces have been added to gcs in a particular order!
|
1348
|
+
all_offsets = None
|
1349
|
+
if return_offsets:
|
1350
|
+
# log.debug('preparing offsets array')
|
1351
|
+
k_offsets = np.empty((0,), dtype = np.float64) if k_props is None else k_props[0]
|
1352
|
+
j_offsets = np.empty((0,), dtype = np.float64) if j_props is None else j_props[0]
|
1353
|
+
i_offsets = np.empty((0,), dtype = np.float64) if i_props is None else i_props[0]
|
1354
|
+
all_offsets = _all_offsets(grid.crs, k_offsets, j_offsets, i_offsets)
|
1355
|
+
# log.debug(f'gcs count: {gcs.count}; all offsets shape: {all_offsets.shape}')
|
1356
|
+
assert all_offsets.shape == (gcs.count,)
|
1357
|
+
|
1358
|
+
all_flange = None
|
1359
|
+
if return_flange_bool:
|
1360
|
+
# log.debug('preparing flange array')
|
1361
|
+
flange_bool_uuid = surface.model.uuid(title = "flange bool",
|
1362
|
+
obj_type = "DiscreteProperty",
|
1363
|
+
related_uuid = surface.uuid)
|
1364
|
+
assert (flange_bool_uuid is not None), f"No flange bool property found for surface: {surface.title}"
|
1365
|
+
flange_bool = rqp.Property(surface.model, uuid = flange_bool_uuid)
|
1366
|
+
flange_array = flange_bool.array_ref(dtype = bool)
|
1367
|
+
all_flange = np.take(flange_array, all_tris)
|
1368
|
+
assert all_flange.shape == (gcs.count,)
|
1369
|
+
|
1331
1370
|
# note: following is a grid cells property, not a gcs property
|
1332
1371
|
shadow = None
|
1333
1372
|
if return_shadow:
|
@@ -2475,7 +2514,7 @@ def _bitwise_count_njit(a: np.ndarray) -> np.int64:
|
|
2475
2514
|
return c
|
2476
2515
|
|
2477
2516
|
|
2478
|
-
@njit
|
2517
|
+
@njit # pragma: no cover
|
2479
2518
|
def box_intersection(box_a: np.ndarray, box_b: np.ndarray) -> np.ndarray:
|
2480
2519
|
"""Return a box which is the intersection of two boxes, python protocol; all zeros if no intersection."""
|
2481
2520
|
box = np.zeros((2, 3), dtype = np.int32)
|
@@ -2486,8 +2525,8 @@ def box_intersection(box_a: np.ndarray, box_b: np.ndarray) -> np.ndarray:
|
|
2486
2525
|
return box
|
2487
2526
|
|
2488
2527
|
|
2489
|
-
@njit
|
2490
|
-
def get_box(mask: np.ndarray) -> Tuple[np.ndarray, int]:
|
2528
|
+
@njit # pragma: no cover
|
2529
|
+
def get_box(mask: np.ndarray) -> Tuple[np.ndarray, int]:
|
2491
2530
|
"""Returns a python protocol box enclosing True elements of 3D boolean mask, and count which is zero if all False."""
|
2492
2531
|
box = np.full((2, 3), -1, dtype = np.int32)
|
2493
2532
|
count = 0
|
@@ -2517,3 +2556,28 @@ def get_box(mask: np.ndarray) -> Tuple[np.ndarray, int]: # pragma: no cover
|
|
2517
2556
|
box[1, 2] = i + 1
|
2518
2557
|
count += 1
|
2519
2558
|
return box, count
|
2559
|
+
|
2560
|
+
|
2561
|
+
@njit # pragma: no cover
|
2562
|
+
def filter_faces(faces_kji0: np.ndarray, face_patches: np.ndarray, cell_patches: np.ndarray, axis: int) -> np.ndarray:
|
2563
|
+
"""Return 1D boolean selection array indicating subset of faces that are applicable to cells with matching patch."""
|
2564
|
+
n: int = len(faces_kji0)
|
2565
|
+
assert len(face_patches) == n
|
2566
|
+
selection = np.zeros(n, dtype = np.bool_)
|
2567
|
+
for f in range(n):
|
2568
|
+
k: int = faces_kji0[f, 0]
|
2569
|
+
j: int = faces_kji0[f, 1]
|
2570
|
+
i: int = faces_kji0[f, 2]
|
2571
|
+
if face_patches[f] == cell_patches[k, j, i]:
|
2572
|
+
selection[f] = True
|
2573
|
+
else:
|
2574
|
+
if axis == 0:
|
2575
|
+
if face_patches[f] == cell_patches[k + 1, j, i]:
|
2576
|
+
selection[f] = True
|
2577
|
+
elif axis == 1:
|
2578
|
+
if face_patches[f] == cell_patches[k, j + 1, i]:
|
2579
|
+
selection[f] = True
|
2580
|
+
else:
|
2581
|
+
if face_patches[f] == cell_patches[k, j, i + 1]:
|
2582
|
+
selection[f] = True
|
2583
|
+
return selection
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|