[FEATURE] - Add a 3d GEN writer
Les mainteneurs répondent en général sous 2 jours
Personne n'a encore pris cette issue.
Évaluation
- Difficulté
- 3/5
- Temps estimé
- 1-2 jours
- Accessibilité débutants
- 57/100
Piste de recherche
Start by reading the existing imod.formats.gen reader and gen.write implementation to see how ASCII and binary formats are handled. The issue gives no test file or exact writer API, so first locate the GEN format tests and check how they represent 3D vertices. Done means gen.write can produce 3D ASCII GEN output with Z values on each vertex.
Rédigé par le modèle d'indexation à partir du texte de l'issue.
Description
See https://github.com/Deltares/iMOD-Suite-transition-regional-models/pull/36
Summary
imod.formats.gen can read 3D ASCII GEN files (x, y, z per vertex) but cannot write them. gen.write only writes the binary format, from 2D coordinates. Downstream code that needs 3D GEN output has to write the text itself. I'd like iMOD Python to own this, so reading and writing of GEN files live in one place.
Use Case
The iMOD-Suite regional-model conversion CLI (Deltares/iMOD-Suite-transition-regional-models) has a GENSNAPTOGRID function. It snaps GEN lines to the cell edges of a grid and, with I3D=1, writes every snapped edge as a closed vertical wall polygon with a Z value on each vertex. iMOD5's GENSNAPTOGRID with I3D=1 does the same. The CLI currently has a private _write_gen_ascii_3d helper for this, marked as a TODO to move to iMOD Python.
Currently, write only writes the binary Fortran-record format. It writes the bounds and xy as float records, so Z is never written.
Follow-up in iMOD-Suite-transition-regional-models
Once this is merged, delete _write_gen_ascii_3d from src/snapping.py. snap_gen_file_to_grid then calls the new iMOD Python writer for I3D=1. The CLI tests that compare the 3D output with iMOD5 stay as they are.
- Langage dominant
- Python
- Étoiles
- 41
- Forks
- 12
- Merge moyen
- 2 j 8 h
- PR mergées (30 j)
- 13
Préparer son environnement
- Aucun Dockerfile ni fichier Docker Compose
- Propose un modèle de pull request
- Aucun guide de contribution
Par où commencer
- Lisez l'issue en entier, puis le guide de contribution du projet.
- Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
- Forkez le dépôt et travaillez sur une branche.
- Ouvrez une pull request qui référence le numéro de l'issue.
Autres issues de Deltares/imod-python
-
backwards_compatibility enhancement
Difficulté 2/5 1-3 heures Accessibilité débutants 69/100
Deltares/imod-python#1963 · 2 commentaires ·
Les mainteneurs répondent en général sous 2 jours
-
bug Deltares
Difficulté 2/5 1-3 heures Accessibilité débutants 72/100
Deltares/imod-python#1950 ·
Les mainteneurs répondent en général sous 2 jours
-
Deltares enhancement good first issue
Difficulté 2/5 1-3 heures Accessibilité débutants 74/100
Deltares/imod-python#1843 ·
Les mainteneurs répondent en général sous 2 jours
-
documentation
Difficulté 1/5 Moins d'une heure Accessibilité débutants 68/100
Deltares/imod-python#1684 ·
Les mainteneurs répondent en général sous 2 jours
-
Bugs found in a code review of master (6f0ec0bc)Peut-être pris @JoerivanEngelen l’a pris il y a 9 jours. Ouverte
Deltares/imod-python#1980 · 1 réaction · 1 personne assignée ·
Les mainteneurs répondent en général sous 2 jours
Toutes les issues de Deltares/imod-python
Issues similaires
-
docs(contributing): the two things that silently block a PRPeut-être pris Une pull request liée à cette issue est ouverte ou déjà fusionnée. Ouverteavailable documentation good first issue
Difficulté 1/5 1-3 heures Accessibilité débutants 95/100
Nixitov/Riptide-Native#944 ·
Les mainteneurs répondent en général sous 1 jour
-
bug
Difficulté 2/5 1-3 heures Accessibilité débutants 88/100
JTHCode/secretguard#24 ·
Les mainteneurs répondent en général sous 1 jour
-
area: middleware documentation good first issue
Difficulté 2/5 1-3 heures Accessibilité débutants 88/100
-
enhancement good first issue
Difficulté 2/5 1-3 heures Accessibilité débutants 88/100
Les mainteneurs répondent en général sous 1 jour
-
good first issue
Difficulté 1/5 Moins d'une heure Accessibilité débutants 95/100
omarelshamy25x/shamy-hijri#63 ·
Les mainteneurs répondent en général sous 1 jour