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

Adds grip edge/vertex generation functionality from FHIR files. #24

Closed
wants to merge 31 commits into from

Conversation

matthewpeterkort
Copy link
Collaborator

@matthewpeterkort matthewpeterkort commented Oct 31, 2023

vertex generation test: python -m pytest tests/integration/simplified/test_simplify_task_grip.py -s

iceberg data simplify tests/fixtures/simplify/synthea grip_data --schema_path https://raw.githubusercontent.com/bmeg/iceberg/feature/updated-schemas/schemas/graph/graph-fhir.json --dialect GRIP --project_id synthea-test
works

See #25 for description of use case. (BW)

Copy link
Contributor

@bwalsh bwalsh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good. One minor comment below re. debugging statements.
See issue, please write up a use case that describes what this is and when / why to use it.

# uuid regex
pattern = r'[a-zA-Z]+/[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}'
names = []
print("SIMPLIFIED ORIG: ", simplified)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should remove debugging statement.

for elems in names:
simplified.pop(elems)

print("SIMPLIFIED: ", simplified)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same ...

@@ -88,10 +88,10 @@ def create_fhir_definitions_lookup(iceberg_path: str = "~/.iceberg"):
connection = sqlite3.connect(path)

with connection:
connection.execute(f'DROP table IF EXISTS element_bindings')
connection.execute(f'CREATE TABLE if not exists element_bindings (id PRIMARY KEY, entity Text)')
connection.execute('DROP table IF EXISTS element_bindings')
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good catch, thanks

@matthewpeterkort
Copy link
Collaborator Author

This got implemented in https://github.com/bmeg/jsonschemagraph instead

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants