resqpy 4.17.2__tar.gz → 4.17.7__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {resqpy-4.17.2 → resqpy-4.17.7}/PKG-INFO +1 -1
- {resqpy-4.17.2 → resqpy-4.17.7}/pyproject.toml +1 -1
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/__init__.py +1 -1
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/grid_surface/_find_faces.py +159 -108
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/surface/_surface.py +2 -2
- {resqpy-4.17.2 → resqpy-4.17.7}/LICENSE +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/README.md +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/crs.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/derived_model/__init__.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/derived_model/_add_edges_per_column_property_array.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/derived_model/_add_faults.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/derived_model/_add_one_blocked_well_property.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/derived_model/_add_one_grid_property_array.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/derived_model/_add_single_cell_grid.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/derived_model/_add_wells_from_ascii_file.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/derived_model/_add_zone_by_layer_property.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/derived_model/_coarsened_grid.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/derived_model/_common.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/derived_model/_copy_grid.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/derived_model/_drape_to_surface.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/derived_model/_extract_box.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/derived_model/_extract_box_for_well.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/derived_model/_fault_throw_scaling.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/derived_model/_gather_ensemble.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/derived_model/_interpolated_grid.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/derived_model/_local_depth_adjustment.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/derived_model/_refined_grid.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/derived_model/_tilted_grid.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/derived_model/_unsplit_grid.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/derived_model/_zonal_grid.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/derived_model/_zone_layer_ranges_from_array.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/fault/__init__.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/fault/_gcs_functions.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/fault/_grid_connection_set.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/grid/__init__.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/grid/_cell_properties.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/grid/_connection_sets.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/grid/_create_grid_xml.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/grid/_defined_geometry.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/grid/_extract_functions.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/grid/_face_functions.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/grid/_faults.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/grid/_grid.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/grid/_grid_types.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/grid/_intervals_info.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/grid/_moved_functions.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/grid/_pillars.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/grid/_pixel_maps.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/grid/_points_functions.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/grid/_regular_grid.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/grid/_transmissibility.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/grid/_write_hdf5_from_caches.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/grid/_write_nexus_corp.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/grid/_xyz.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/grid_surface/__init__.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/grid_surface/_blocked_well_populate.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/grid_surface/_grid_skin.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/grid_surface/_grid_surface.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/grid_surface/_trajectory_intersects.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/grid_surface/grid_surface_cuda.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/lines/__init__.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/lines/_common.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/lines/_polyline.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/lines/_polyline_set.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/model/__init__.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/model/_catalogue.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/model/_context.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/model/_forestry.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/model/_grids.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/model/_hdf5.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/model/_model.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/model/_xml.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/multi_processing/__init__.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/multi_processing/_multiprocessing.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/multi_processing/wrappers/__init__.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/multi_processing/wrappers/blocked_well_mp.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/multi_processing/wrappers/grid_surface_mp.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/multi_processing/wrappers/mesh_mp.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/olio/__init__.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/olio/ab_toolbox.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/olio/base.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/olio/box_utilities.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/olio/class_dict.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/olio/consolidation.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/olio/data/build.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/olio/data/properties.json +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/olio/dataframe.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/olio/exceptions.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/olio/factors.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/olio/fine_coarse.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/olio/grid_functions.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/olio/intersection.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/olio/keyword_files.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/olio/load_data.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/olio/point_inclusion.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/olio/random_seed.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/olio/read_nexus_fault.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/olio/relperm.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/olio/simple_lines.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/olio/time.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/olio/trademark.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/olio/transmission.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/olio/triangulation.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/olio/uuid.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/olio/vdb.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/olio/vector_utilities.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/olio/volume.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/olio/wellspec_keywords.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/olio/write_data.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/olio/write_hdf5.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/olio/xml_et.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/olio/xml_namespaces.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/olio/zmap_reader.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/organize/__init__.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/organize/_utils.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/organize/boundary_feature.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/organize/boundary_feature_interpretation.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/organize/earth_model_interpretation.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/organize/fault_interpretation.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/organize/fluid_boundary_feature.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/organize/frontier_feature.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/organize/generic_interpretation.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/organize/genetic_boundary_feature.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/organize/geobody_boundary_interpretation.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/organize/geobody_feature.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/organize/geobody_interpretation.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/organize/geologic_unit_feature.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/organize/horizon_interpretation.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/organize/organization_feature.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/organize/rock_fluid_unit_feature.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/organize/structural_organization_interpretation.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/organize/tectonic_boundary_feature.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/organize/wellbore_feature.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/organize/wellbore_interpretation.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/property/__init__.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/property/_collection_add_part.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/property/_collection_create_xml.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/property/_collection_get_attributes.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/property/_collection_support.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/property/_property.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/property/attribute_property_set.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/property/grid_property_collection.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/property/property_collection.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/property/property_common.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/property/property_kind.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/property/string_lookup.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/property/well_interval_property.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/property/well_interval_property_collection.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/property/well_log.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/property/well_log_collection.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/rq_import/__init__.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/rq_import/_add_ab_properties.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/rq_import/_add_surfaces.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/rq_import/_grid_from_cp.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/rq_import/_import_nexus.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/rq_import/_import_vdb_all_grids.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/rq_import/_import_vdb_ensemble.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/strata/__init__.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/strata/_binary_contact_interpretation.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/strata/_geologic_unit_interpretation.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/strata/_strata_common.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/strata/_stratigraphic_column.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/strata/_stratigraphic_column_rank.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/strata/_stratigraphic_unit_feature.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/strata/_stratigraphic_unit_interpretation.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/surface/__init__.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/surface/_base_surface.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/surface/_combined_surface.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/surface/_mesh.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/surface/_pointset.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/surface/_tri_mesh.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/surface/_tri_mesh_stencil.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/surface/_triangulated_patch.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/time_series/__init__.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/time_series/_any_time_series.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/time_series/_from_nexus_summary.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/time_series/_functions.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/time_series/_geologic_time_series.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/time_series/_time_duration.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/time_series/_time_series.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/unstructured/__init__.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/unstructured/_hexa_grid.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/unstructured/_prism_grid.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/unstructured/_pyramid_grid.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/unstructured/_tetra_grid.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/unstructured/_unstructured_grid.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/weights_and_measures/__init__.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/weights_and_measures/nexus_units.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/weights_and_measures/weights_and_measures.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/well/__init__.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/well/_blocked_well.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/well/_deviation_survey.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/well/_md_datum.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/well/_trajectory.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/well/_wellbore_frame.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/well/_wellbore_marker.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/well/_wellbore_marker_frame.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/well/blocked_well_frame.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/well/well_object_funcs.py +0 -0
- {resqpy-4.17.2 → resqpy-4.17.7}/resqpy/well/well_utils.py +0 -0
@@ -8,7 +8,7 @@ import numpy as np
|
|
8
8
|
import warnings
|
9
9
|
import numba # type: ignore
|
10
10
|
from numba import njit, prange # type: ignore
|
11
|
-
from typing import Tuple,
|
11
|
+
from typing import Tuple, Union, Dict
|
12
12
|
|
13
13
|
import resqpy as rq
|
14
14
|
import resqpy.crs as rqc
|
@@ -832,8 +832,7 @@ def find_faces_to_represent_surface_regular_dense_optimised(grid,
|
|
832
832
|
# log.debug('finished preparing columns bisector')
|
833
833
|
else:
|
834
834
|
log.debug("preparing cells bisector")
|
835
|
-
bisector, is_curtain = bisector_from_faces(tuple(grid.extent_kji), k_faces, j_faces, i_faces, raw_bisector
|
836
|
-
False)
|
835
|
+
bisector, is_curtain = bisector_from_faces(tuple(grid.extent_kji), k_faces, j_faces, i_faces, raw_bisector)
|
837
836
|
if is_curtain:
|
838
837
|
bisector = bisector[0] # reduce to a columns property
|
839
838
|
|
@@ -1051,7 +1050,7 @@ def find_faces_to_represent_surface_regular_optimised(grid,
|
|
1051
1050
|
if grid.nj > 1:
|
1052
1051
|
# log.debug("searching for J faces")
|
1053
1052
|
|
1054
|
-
j_hits, j_depths = vec.points_in_triangles_aligned_unified(grid.ni,
|
1053
|
+
j_hits, j_depths = vec.points_in_triangles_aligned_unified(grid.ni, nk, 0, 2, 1, p, n_batches)
|
1055
1054
|
|
1056
1055
|
j_faces = np.floor(j_depths)
|
1057
1056
|
mask = np.logical_and(j_faces >= 0, j_faces < grid.nj - 1)
|
@@ -1103,7 +1102,7 @@ def find_faces_to_represent_surface_regular_optimised(grid,
|
|
1103
1102
|
if grid.ni > 1:
|
1104
1103
|
# log.debug("searching for I faces")
|
1105
1104
|
|
1106
|
-
i_hits, i_depths = vec.points_in_triangles_aligned_unified(grid.nj,
|
1105
|
+
i_hits, i_depths = vec.points_in_triangles_aligned_unified(grid.nj, nk, 1, 2, 0, p, n_batches)
|
1107
1106
|
|
1108
1107
|
i_faces = np.floor(i_depths)
|
1109
1108
|
mask = np.logical_and(i_faces >= 0, i_faces < grid.ni - 1)
|
@@ -1146,6 +1145,9 @@ def find_faces_to_represent_surface_regular_optimised(grid,
|
|
1146
1145
|
if progress_fn is not None:
|
1147
1146
|
progress_fn(0.9)
|
1148
1147
|
|
1148
|
+
assert k_faces_kji0 is not None or j_faces_kji0 is not None or i_faces_kji0 is not None, \
|
1149
|
+
f'did not find any faces to represent {name}: surface does not intersect grid?'
|
1150
|
+
|
1149
1151
|
log.debug("converting face sets into grid connection set")
|
1150
1152
|
# NB: kji0 arrays in internal face protocol: used as cell_kji0 with polarity of 1
|
1151
1153
|
# property lists have elements replaced with sorted and filtered equivalents
|
@@ -1212,8 +1214,8 @@ def find_faces_to_represent_surface_regular_optimised(grid,
|
|
1212
1214
|
# log.debug('finished preparing columns bisector')
|
1213
1215
|
else:
|
1214
1216
|
log.debug("preparing cells bisector")
|
1215
|
-
bisector, is_curtain =
|
1216
|
-
|
1217
|
+
bisector, is_curtain = bisector_from_face_indices(tuple(grid.extent_kji), k_faces_kji0, j_faces_kji0,
|
1218
|
+
i_faces_kji0, raw_bisector)
|
1217
1219
|
if is_curtain:
|
1218
1220
|
bisector = bisector[0] # reduce to a columns property
|
1219
1221
|
|
@@ -1311,8 +1313,8 @@ def find_faces_to_represent_surface(grid, surface, name, mode = "auto", feature_
|
|
1311
1313
|
|
1312
1314
|
|
1313
1315
|
def bisector_from_faces( # type: ignore
|
1314
|
-
grid_extent_kji: Tuple[int, int, int], k_faces: np.ndarray, j_faces: np.ndarray,
|
1315
|
-
|
1316
|
+
grid_extent_kji: Tuple[int, int, int], k_faces: Union[np.ndarray, None], j_faces: Union[np.ndarray, None],
|
1317
|
+
i_faces: Union[np.ndarray, None], raw_bisector: bool) -> Tuple[np.ndarray, bool]:
|
1316
1318
|
"""Creates a boolean array denoting the bisection of the grid by the face sets.
|
1317
1319
|
|
1318
1320
|
arguments:
|
@@ -1321,8 +1323,6 @@ def bisector_from_faces( # type: ignore
|
|
1321
1323
|
- j_faces (np.ndarray): a boolean array of which faces represent the surface in the j dimension
|
1322
1324
|
- i_faces (np.ndarray): a boolean array of which faces represent the surface in the i dimension
|
1323
1325
|
- raw_bisector (bool): if True, the bisector is returned without determining which side is shallower
|
1324
|
-
- using_indices (bool): if True, k_faces etc. are list-like arrays of kji indices; if False, they
|
1325
|
-
are full boolean arrays covering the internal faces
|
1326
1326
|
|
1327
1327
|
returns:
|
1328
1328
|
Tuple containing:
|
@@ -1334,21 +1334,88 @@ def bisector_from_faces( # type: ignore
|
|
1334
1334
|
- the face sets must form a single 'sealed' cut of the grid (eg. not waving in and out of the grid)
|
1335
1335
|
- any 'boxed in' parts of the grid (completely enclosed by bisecting faces) will be consistently
|
1336
1336
|
assigned to either the True or False part
|
1337
|
-
-
|
1337
|
+
- this function is DEPRECATED, pending proving of newer indices based approach
|
1338
1338
|
"""
|
1339
1339
|
assert len(grid_extent_kji) == 3
|
1340
1340
|
|
1341
1341
|
# find the surface boundary (includes a buffer slice where surface does not reach edge of grid)
|
1342
|
-
|
1343
|
-
|
1344
|
-
|
1345
|
-
|
1342
|
+
box = get_boundary(k_faces, j_faces, i_faces, grid_extent_kji)
|
1343
|
+
box_shape = box[1, :] - box[0, :]
|
1344
|
+
|
1345
|
+
# set up the bisector array for the bounding box
|
1346
|
+
box_array = np.zeros(box_shape, dtype = np.bool_)
|
1347
|
+
|
1348
|
+
# seed the bisector box array at (0, 0, 0)
|
1349
|
+
box_array[0, 0, 0] = True
|
1350
|
+
|
1351
|
+
# prepare to spread True values to neighbouring cells that are not the other side of a face
|
1352
|
+
if k_faces is None:
|
1353
|
+
open_k = np.ones((box_shape[0] - 1, box_shape[1], box_shape[2]), dtype = bool)
|
1346
1354
|
else:
|
1347
|
-
box = get_boundary(k_faces, j_faces, i_faces, grid_extent_kji)
|
1348
|
-
# switch k_faces etc. to box coverage
|
1349
1355
|
k_faces = k_faces[box[0, 0]:box[1, 0] - 1, box[0, 1]:box[1, 1], box[0, 2]:box[1, 2]]
|
1356
|
+
open_k = np.logical_not(k_faces)
|
1357
|
+
if j_faces is None:
|
1358
|
+
open_j = np.ones((box_shape[0], box_shape[1] - 1, box_shape[2]), dtype = bool)
|
1359
|
+
else:
|
1350
1360
|
j_faces = j_faces[box[0, 0]:box[1, 0], box[0, 1]:box[1, 1] - 1, box[0, 2]:box[1, 2]]
|
1361
|
+
open_j = np.logical_not(j_faces)
|
1362
|
+
if i_faces is None:
|
1363
|
+
open_i = np.ones((box_shape[0], box_shape[1], box_shape[2] - 1), dtype = bool)
|
1364
|
+
else:
|
1351
1365
|
i_faces = i_faces[box[0, 0]:box[1, 0], box[0, 1]:box[1, 1], box[0, 2]:box[1, 2] - 1]
|
1366
|
+
open_i = np.logical_not(i_faces)
|
1367
|
+
|
1368
|
+
# populate bisector array for box
|
1369
|
+
_fill_bisector(box_array, open_k, open_j, open_i)
|
1370
|
+
|
1371
|
+
# set up the full bisectors array and assigning the bounding box values
|
1372
|
+
array = np.zeros(grid_extent_kji, dtype = np.bool_)
|
1373
|
+
array[box[0, 0]:box[1, 0], box[0, 1]:box[1, 1], box[0, 2]:box[1, 2]] = box_array
|
1374
|
+
|
1375
|
+
# set bisector values outside of the bounding box
|
1376
|
+
_set_bisector_outside_box(array, box, box_array)
|
1377
|
+
|
1378
|
+
# check all array elements are not the same
|
1379
|
+
true_count = np.count_nonzero(array)
|
1380
|
+
cell_count = array.size
|
1381
|
+
assert (0 < true_count < cell_count), "face set for surface is leaky or empty (surface does not intersect grid)"
|
1382
|
+
|
1383
|
+
# negate the array if it minimises the mean k and determine if the surface is a curtain
|
1384
|
+
is_curtain = _shallow_or_curtain(array, true_count, raw_bisector)
|
1385
|
+
|
1386
|
+
return array, is_curtain
|
1387
|
+
|
1388
|
+
|
1389
|
+
def bisector_from_face_indices( # type: ignore
|
1390
|
+
grid_extent_kji: Tuple[int, int, int], k_faces_kji0: Union[np.ndarray, None], j_faces_kji0: Union[np.ndarray,
|
1391
|
+
None],
|
1392
|
+
i_faces_kji0: Union[np.ndarray, None], raw_bisector: bool) -> Tuple[np.ndarray, bool]:
|
1393
|
+
"""Creates a boolean array denoting the bisection of the grid by the face sets.
|
1394
|
+
|
1395
|
+
arguments:
|
1396
|
+
- grid_extent_kji (Tuple[int, int, int]): the shape of the grid
|
1397
|
+
- k_faces_kji0 (np.ndarray): an int array of indices of which faces represent the surface in the k dimension
|
1398
|
+
- j_faces_kji0 (np.ndarray): an int array of indices of which faces represent the surface in the j dimension
|
1399
|
+
- i_faces_kji0 (np.ndarray): an int array of indices of which faces represent the surface in the i dimension
|
1400
|
+
- raw_bisector (bool): if True, the bisector is returned without determining which side is shallower
|
1401
|
+
|
1402
|
+
returns:
|
1403
|
+
Tuple containing:
|
1404
|
+
- array (np.ndarray): boolean bisectors array where values are True for cells on the side
|
1405
|
+
of the surface that has a lower mean k index on average and False for cells on the other side.
|
1406
|
+
- is_curtain (bool): True if the surface is a curtain (vertical), otherwise False.
|
1407
|
+
|
1408
|
+
notes:
|
1409
|
+
- the face sets must form a single 'sealed' cut of the grid (eg. not waving in and out of the grid)
|
1410
|
+
- any 'boxed in' parts of the grid (completely enclosed by bisecting faces) will be consistently
|
1411
|
+
assigned to either the True or False part
|
1412
|
+
"""
|
1413
|
+
assert len(grid_extent_kji) == 3
|
1414
|
+
|
1415
|
+
# find the surface boundary (includes a buffer slice where surface does not reach edge of grid)
|
1416
|
+
box = get_boundary_from_indices(k_faces_kji0, j_faces_kji0, i_faces_kji0, grid_extent_kji)
|
1417
|
+
# set k_faces as bool arrays covering box
|
1418
|
+
k_faces, j_faces, i_faces = _box_face_arrays_from_indices(k_faces_kji0, j_faces_kji0, i_faces_kji0, box)
|
1352
1419
|
|
1353
1420
|
box_shape = box[1, :] - box[0, :]
|
1354
1421
|
|
@@ -1359,9 +1426,18 @@ def bisector_from_faces( # type: ignore
|
|
1359
1426
|
box_array[0, 0, 0] = True
|
1360
1427
|
|
1361
1428
|
# prepare to spread True values to neighbouring cells that are not the other side of a face
|
1362
|
-
|
1363
|
-
|
1364
|
-
|
1429
|
+
if k_faces is None:
|
1430
|
+
open_k = np.ones((box_shape[0] - 1, box_shape[1], box_shape[2]), dtype = bool)
|
1431
|
+
else:
|
1432
|
+
open_k = np.logical_not(k_faces)
|
1433
|
+
if j_faces is None:
|
1434
|
+
open_j = np.ones((box_shape[0], box_shape[1] - 1, box_shape[2]), dtype = bool)
|
1435
|
+
else:
|
1436
|
+
open_j = np.logical_not(j_faces)
|
1437
|
+
if i_faces is None:
|
1438
|
+
open_i = np.ones((box_shape[0], box_shape[1], box_shape[2] - 1), dtype = bool)
|
1439
|
+
else:
|
1440
|
+
open_i = np.logical_not(i_faces)
|
1365
1441
|
|
1366
1442
|
# populate bisector array for box
|
1367
1443
|
_fill_bisector(box_array, open_k, open_j, open_i)
|
@@ -1534,9 +1610,9 @@ def shadow_from_faces(extent_kji, k_faces):
|
|
1534
1610
|
|
1535
1611
|
|
1536
1612
|
def get_boundary( # type: ignore
|
1537
|
-
k_faces: np.ndarray,
|
1538
|
-
j_faces: np.ndarray,
|
1539
|
-
i_faces: np.ndarray,
|
1613
|
+
k_faces: Union[np.ndarray, None],
|
1614
|
+
j_faces: Union[np.ndarray, None],
|
1615
|
+
i_faces: Union[np.ndarray, None],
|
1540
1616
|
grid_extent_kji: Tuple[int, int, int],
|
1541
1617
|
) -> np.ndarray:
|
1542
1618
|
"""Cretaes a box of the indices that bound the surface (where the faces are True).
|
@@ -1561,6 +1637,9 @@ def get_boundary( # type: ignore
|
|
1561
1637
|
|
1562
1638
|
for f_i, faces in enumerate([k_faces, j_faces, i_faces]):
|
1563
1639
|
|
1640
|
+
if faces is None:
|
1641
|
+
continue
|
1642
|
+
|
1564
1643
|
# NB. k, j & i for rest of loop refer to indices of faces, regardless of which face set is being processed
|
1565
1644
|
|
1566
1645
|
where_k, where_j, where_i = _where_true(faces)
|
@@ -1584,21 +1663,21 @@ def get_boundary( # type: ignore
|
|
1584
1663
|
else:
|
1585
1664
|
if min_k > 0:
|
1586
1665
|
min_k -= 1
|
1587
|
-
if max_k <
|
1666
|
+
if max_k < grid_extent_kji[0] - 1:
|
1588
1667
|
max_k += 1
|
1589
1668
|
if f_i == 1:
|
1590
1669
|
max_j += 1
|
1591
1670
|
else:
|
1592
1671
|
if min_j > 0:
|
1593
1672
|
min_j -= 1
|
1594
|
-
if max_j <
|
1673
|
+
if max_j < grid_extent_kji[1] - 1:
|
1595
1674
|
max_j += 1
|
1596
1675
|
if f_i == 2:
|
1597
1676
|
max_i += 1
|
1598
1677
|
else:
|
1599
1678
|
if min_i > 0:
|
1600
1679
|
min_i -= 1
|
1601
|
-
if max_i <
|
1680
|
+
if max_i < grid_extent_kji[2] - 1:
|
1602
1681
|
max_i += 1
|
1603
1682
|
|
1604
1683
|
if starting:
|
@@ -1629,9 +1708,9 @@ def get_boundary( # type: ignore
|
|
1629
1708
|
|
1630
1709
|
|
1631
1710
|
def get_boundary_dict( # type: ignore
|
1632
|
-
k_faces: np.ndarray,
|
1633
|
-
j_faces: np.ndarray,
|
1634
|
-
i_faces: np.ndarray,
|
1711
|
+
k_faces: Union[np.ndarray, None],
|
1712
|
+
j_faces: Union[np.ndarray, None],
|
1713
|
+
i_faces: Union[np.ndarray, None],
|
1635
1714
|
grid_extent_kji: Tuple[int, int, int],
|
1636
1715
|
) -> Dict[str, int]:
|
1637
1716
|
"""Cretaes a dictionary of the indices that bound the surface (where the faces are True).
|
@@ -1783,63 +1862,6 @@ def intersect_numba(
|
|
1783
1862
|
return faces, offsets, triangle_per_face
|
1784
1863
|
|
1785
1864
|
|
1786
|
-
@njit # pragma: no cover
|
1787
|
-
def _seed_array(
|
1788
|
-
point: Tuple[int, int, int],
|
1789
|
-
k_faces: np.ndarray,
|
1790
|
-
j_faces: np.ndarray,
|
1791
|
-
i_faces: np.ndarray,
|
1792
|
-
box: np.ndarray,
|
1793
|
-
array: np.ndarray,
|
1794
|
-
) -> Tuple[np.ndarray, int, int, int]:
|
1795
|
-
"""Sets values of the array True up until a face is hit in each direction.
|
1796
|
-
|
1797
|
-
arguments:
|
1798
|
-
|
1799
|
-
- point (Tuple[int, int, int]): coordinates of the initial seed point
|
1800
|
-
- k_faces (np.ndarray): a boolean array of which faces represent the surface in the k dimension
|
1801
|
-
- j_faces (np.ndarray): a boolean array of which faces represent the surface in the j dimension
|
1802
|
-
- i_faces (np.ndarray): a boolean array of which faces represent the surface in the i dimension
|
1803
|
-
- box (numpy int array of shape (2, 3)): the boundaries of the surface in python protocol
|
1804
|
-
- array (np.ndarray): boolean array that will be seeded
|
1805
|
-
|
1806
|
-
returns:
|
1807
|
-
Tuple containing:
|
1808
|
-
|
1809
|
-
- array (np.ndarray): boolean array that has been seeded.
|
1810
|
-
- first_k (int): the index of the first k face in the k direction from the seed point or the
|
1811
|
-
array size in the k direction if there are no k faces.
|
1812
|
-
- first_j (int): the index of the first j face in the j direction from the seed point or the
|
1813
|
-
array size in the j direction if there are no j faces.
|
1814
|
-
- first_i (int): the index of the first i face in the i direction from the seed point or the
|
1815
|
-
array size in the i direction if there are no i faces.
|
1816
|
-
|
1817
|
-
note:
|
1818
|
-
|
1819
|
-
- this function is DEPRECATED as it is no longer in use
|
1820
|
-
"""
|
1821
|
-
k = point[0]
|
1822
|
-
j = point[1]
|
1823
|
-
i = point[2]
|
1824
|
-
|
1825
|
-
first_k = 0
|
1826
|
-
if k == 0:
|
1827
|
-
first_k = _first_true(k_faces[box[0, 0]:box[1, 0] - 1, box[0, 1] + j, box[0, 2] + i])
|
1828
|
-
array[:first_k, j, i] = True
|
1829
|
-
|
1830
|
-
first_j = 0
|
1831
|
-
if j == 0:
|
1832
|
-
first_j = _first_true(j_faces[box[0, 0] + k, box[0, 1]:box[1, 1] - 1, box[0, 2] + i])
|
1833
|
-
array[k, :first_j, i] = True
|
1834
|
-
|
1835
|
-
first_i = 0
|
1836
|
-
if i == 0:
|
1837
|
-
first_i = _first_true(i_faces[box[0, 0] + k, box[0, 1] + j, box[0, 2]:box[1, 2] - 1])
|
1838
|
-
array[k, j, :first_i] = True
|
1839
|
-
|
1840
|
-
return array, first_k, first_j, first_i
|
1841
|
-
|
1842
|
-
|
1843
1865
|
def _all_offsets(crs, k_offsets_list, j_offsets_list, i_offsets_list):
|
1844
1866
|
if crs.xy_units == crs.z_units:
|
1845
1867
|
return np.concatenate((k_offsets_list, j_offsets_list, i_offsets_list), axis = 0)
|
@@ -1913,8 +1935,9 @@ def _set_bisector_outside_box(a: np.ndarray, box: np.ndarray, box_array: np.ndar
|
|
1913
1935
|
a[:, :, :box[0, 2]] = True
|
1914
1936
|
|
1915
1937
|
|
1916
|
-
def _box_face_arrays_from_indices(
|
1917
|
-
|
1938
|
+
def _box_face_arrays_from_indices( # type: ignore
|
1939
|
+
k_faces_kji0: Union[np.ndarray, None], j_faces_kji0: Union[np.ndarray, None],
|
1940
|
+
i_faces_kji0: Union[np.ndarray, None], box: np.ndarray) -> Tuple[np.ndarray, np.ndarray, np.ndarray]:
|
1918
1941
|
box_shape = box[1, :] - box[0, :]
|
1919
1942
|
k_a = np.zeros((box_shape[0] - 1, box_shape[1], box_shape[2]), dtype = np.bool_)
|
1920
1943
|
j_a = np.zeros((box_shape[0], box_shape[1] - 1, box_shape[2]), dtype = np.bool_)
|
@@ -1922,14 +1945,20 @@ def _box_face_arrays_from_indices(k_faces: np.ndarray, j_faces: np.ndarray, i_fa
|
|
1922
1945
|
ko = box[0, 0]
|
1923
1946
|
jo = box[0, 1]
|
1924
1947
|
io = box[0, 2]
|
1925
|
-
|
1926
|
-
|
1927
|
-
|
1948
|
+
if k_faces_kji0 is not None:
|
1949
|
+
_set_face_array(k_a, k_faces_kji0, ko, jo, io)
|
1950
|
+
if j_faces_kji0 is not None:
|
1951
|
+
_set_face_array(j_a, j_faces_kji0, ko, jo, io)
|
1952
|
+
if i_faces_kji0 is not None:
|
1953
|
+
_set_face_array(i_a, i_faces_kji0, ko, jo, io)
|
1928
1954
|
return k_a, j_a, i_a
|
1929
1955
|
|
1930
1956
|
|
1931
1957
|
@njit # pragma: no cover
|
1932
1958
|
def _set_face_array(a: np.ndarray, indices: np.ndarray, ko: int, jo: int, io: int):
|
1959
|
+
k: int = 0
|
1960
|
+
j: int = 0
|
1961
|
+
i: int = 0
|
1933
1962
|
for ind in range(len(indices)):
|
1934
1963
|
k = indices[ind, 0] - ko
|
1935
1964
|
j = indices[ind, 1] - jo
|
@@ -1937,25 +1966,47 @@ def _set_face_array(a: np.ndarray, indices: np.ndarray, ko: int, jo: int, io: in
|
|
1937
1966
|
a[k, j, i] = True
|
1938
1967
|
|
1939
1968
|
|
1940
|
-
def get_boundary_from_indices(
|
1941
|
-
|
1969
|
+
def get_boundary_from_indices( # type: ignore
|
1970
|
+
k_faces_kji0: Union[np.ndarray, None], j_faces_kji0: Union[np.ndarray, None],
|
1971
|
+
i_faces_kji0: Union[np.ndarray, None], grid_extent_kji: Tuple[int, int, int]) -> np.ndarray:
|
1942
1972
|
"""Return python protocol box containing indices"""
|
1943
|
-
k_min_kji0 = np.min(
|
1944
|
-
k_max_kji0 = np.max(
|
1945
|
-
j_min_kji0 = np.min(
|
1946
|
-
j_max_kji0 = np.max(
|
1947
|
-
i_min_kji0 = np.min(
|
1948
|
-
i_max_kji0 = np.max(
|
1973
|
+
k_min_kji0 = None if k_faces_kji0 is None else np.min(k_faces_kji0, axis = 0)
|
1974
|
+
k_max_kji0 = None if k_faces_kji0 is None else np.max(k_faces_kji0, axis = 0)
|
1975
|
+
j_min_kji0 = None if j_faces_kji0 is None else np.min(j_faces_kji0, axis = 0)
|
1976
|
+
j_max_kji0 = None if j_faces_kji0 is None else np.max(j_faces_kji0, axis = 0)
|
1977
|
+
i_min_kji0 = None if i_faces_kji0 is None else np.min(i_faces_kji0, axis = 0)
|
1978
|
+
i_max_kji0 = None if i_faces_kji0 is None else np.max(i_faces_kji0, axis = 0)
|
1949
1979
|
box = np.empty((2, 3), dtype = np.int32)
|
1950
|
-
box[0,
|
1951
|
-
box[
|
1952
|
-
|
1953
|
-
|
1954
|
-
|
1955
|
-
|
1956
|
-
|
1980
|
+
box[0, :] = grid_extent_kji
|
1981
|
+
box[1, :] = -1
|
1982
|
+
if k_min_kji0 is not None:
|
1983
|
+
box[0, 0] = k_min_kji0[0]
|
1984
|
+
box[0, 1] = k_min_kji0[1]
|
1985
|
+
box[0, 2] = k_min_kji0[2]
|
1986
|
+
box[1, 0] = k_max_kji0[0] # type: ignore
|
1987
|
+
box[1, 1] = k_max_kji0[1] # type: ignore
|
1988
|
+
box[1, 2] = k_max_kji0[2] # type: ignore
|
1989
|
+
if j_min_kji0 is not None:
|
1990
|
+
box[0, 0] = min(box[0, 0], j_min_kji0[0])
|
1991
|
+
box[0, 1] = min(box[0, 1], j_min_kji0[1])
|
1992
|
+
box[0, 2] = min(box[0, 2], j_min_kji0[2])
|
1993
|
+
box[1, 0] = max(box[1, 0], j_max_kji0[0]) # type: ignore
|
1994
|
+
box[1, 1] = max(box[1, 1], j_max_kji0[1]) # type: ignore
|
1995
|
+
box[1, 2] = max(box[1, 2], j_max_kji0[2]) # type: ignore
|
1996
|
+
if i_min_kji0 is not None:
|
1997
|
+
box[0, 1] = min(box[0, 1], i_min_kji0[0])
|
1998
|
+
box[0, 2] = min(box[0, 2], i_min_kji0[1])
|
1999
|
+
box[0, 2] = min(box[0, 2], i_min_kji0[2])
|
2000
|
+
box[1, 0] = max(box[1, 0], i_max_kji0[0]) # type: ignore
|
2001
|
+
box[1, 1] = max(box[1, 1], i_max_kji0[1]) # type: ignore
|
2002
|
+
box[1, 2] = max(box[1, 2], i_max_kji0[2]) # type: ignore
|
2003
|
+
assert np.all(box[1] >= box[0]), 'attempt to find bounding box when all faces None'
|
1957
2004
|
# include buffer layer where box does not reach edge of grid
|
2005
|
+
box[0, :] = np.maximum(box[0, :] - 1, 0)
|
1958
2006
|
extent_kji = np.array(grid_extent_kji, dtype = np.int32)
|
2007
|
+
box[1, :] += 2 # buffer layer and python protocol
|
2008
|
+
box[1, :] = np.minimum(box[1, :], extent_kji)
|
2009
|
+
assert np.all(box[0] >= 0)
|
2010
|
+
assert np.all(box[1] > box[0])
|
1959
2011
|
assert np.all(box[1] <= grid_extent_kji)
|
1960
|
-
box[1, :] = np.minimum(box[1, :] + 1, extent_kji)
|
1961
2012
|
return box
|
@@ -949,7 +949,7 @@ class Surface(rqsb.BaseSurface):
|
|
949
949
|
v_index = None
|
950
950
|
for line in lines:
|
951
951
|
if "VRTX" in line:
|
952
|
-
words = line.rstrip().split(
|
952
|
+
words = line.rstrip().split()
|
953
953
|
v_i = int(words[1])
|
954
954
|
if v_index is None:
|
955
955
|
v_index = v_i
|
@@ -959,7 +959,7 @@ class Surface(rqsb.BaseSurface):
|
|
959
959
|
v_index = v_i
|
960
960
|
vertices.append(words[2:5])
|
961
961
|
elif "TRGL" in line:
|
962
|
-
triangles.append(line.rstrip().split(
|
962
|
+
triangles.append(line.rstrip().split()[1:4])
|
963
963
|
assert len(vertices) >= 3, 'vertices missing'
|
964
964
|
assert len(triangles) > 0, 'triangles missing'
|
965
965
|
t_type = np.int32 if len(vertices) <= 2_147_483_647 else np.int64
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{resqpy-4.17.2 → resqpy-4.17.7}/resqpy/derived_model/_add_edges_per_column_property_array.py
RENAMED
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
|