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

Implement GA4GH Pedigree model #333

Closed
julesjacobsen opened this issue Mar 3, 2022 · 16 comments
Closed

Implement GA4GH Pedigree model #333

julesjacobsen opened this issue Mar 3, 2022 · 16 comments
Labels
enhancement New feature or request

Comments

@julesjacobsen
Copy link
Collaborator

julesjacobsen commented Mar 3, 2022

@buske

Will require an ethnicity field adding to Individual:

Re-opening given discussion with Pedigree group on 2022-03-03. This field is useful/required for many test ordering systems. The codes used will likely be national-specific codes and not necessarily universally applicable.

Originally posted by @julesjacobsen in #231 (comment)

@julesjacobsen
Copy link
Collaborator Author

@buske - please add the link to the conceptual model docs when this has been finalised.

@julesjacobsen julesjacobsen added the enhancement New feature or request label Mar 3, 2022
@julesjacobsen
Copy link
Collaborator Author

Plan is to add org.ga4gh.pedigree.Pedigree and component classes, composed using Phenopacket-schema entities i.e. Individual, OntologyClass.

The GA4GH Pedigree would be incorporated as a oneof in the Family.pedigree field.

@julesjacobsen
Copy link
Collaborator Author

  • Implement classes
  • Update Family
  • Test backwards compatibility
  • Update Docs
  • Drink Tea

A note on backward compatibility - if it is not possible for the pedigree to be made a oneof we will have to try another solution.

@pnrobinson
Copy link
Collaborator

@julesjacobsen I think this is something we will have to leave for a future version? Should we close?

@M-casado
Copy link

Hi everyone, sorry to budge in this thread, but I was wondering if you could give more details about the future population building block. I came from #231, and I also am interested in having ethnicity part of a phenopacket.

Regardless of what the final implementation is, would it include both ancestry informative markers (Ancestry category [HANCESTRO:0004]) and other less informative markers (in case the former are missing; e.g. National origin [NCIT:C28407] or Ethnic group [EFO:0001799]).

@julesjacobsen
Copy link
Collaborator Author

Currently 727b245

This is external to the phenopacket-schema as it lives in the org.ga4gh.pedigree namespace and imports Phenopacket and OntologyClass . This might change to use the Pedigree model Individual and potentially a Concept (would be identical to OntologyClass, only native to the Pedigree model to reduce depencencies)

@julesjacobsen
Copy link
Collaborator Author

@M-casado have you got a use-case and model in mind? If so please continue this in #231

@M-casado
Copy link

Hi @julesjacobsen, I do not a specific use-case and model in mind. There is a general desire from the users of my archive (EGA) to be able to provide the ethnicity of their probands, and we will try to conform to phenopackets.

@cmungall cmungall mentioned this issue May 13, 2024
@cmungall
Copy link
Member

What's the status of this?

@julesjacobsen
Copy link
Collaborator Author

This is work in progress and taking lead from the GA4GH-Pedigree working group.

@acabrelles
Copy link

Hello! I'm pretty new to the use of phenopackets, and I am trying to build one as complete as possible as an example via the Python modules created here, and I stumbled upon an issue with the Pedigrees (I thought It'd be a good idea to mention it here).

It may be my ignorance, but the Pedigrees are a list of Persons, and I have tried all my might to find this Person bit in the code. I was given an error that calls for phenopackets.schema.v2.core.pedigree_pb2.Person, but I have not had the ability to find it.

@julesjacobsen
Copy link
Collaborator Author

Hi @acabrelles how are you accessing this? Are you using the PyPi library?

@acabrelles
Copy link

@julesjacobsen Yes, that would be right. Also i made sure it was the last version by trying to update it just in case,but it seems I'm already up to date.

@ielis
Copy link
Contributor

ielis commented Dec 5, 2024

Hello @acabrelles ,

the phenopackets Python package deployed on PyPi mostly includes just the code generated by the Python Protobuf compiler, and the code is a bit clunky.

This is nicely shown in the Person class. In Phenopacket schema, the Person message is nested in Pedigree. Therefore, you do not really have to import it in Python, in order to use it.

Please try something like this to build a pedigree:

from phenopackets.schema.v2.core.individual_pb2 import MALE
from phenopackets.schema.v2.core.pedigree_pb2 import Pedigree

person = Pedigree.Person(
    family_id='FAM001',
    individual_id='ID1',
    paternal_id=None,
    maternal_id='ID2',
    affected_status=Pedigree.Person.AFFECTED,
    sex=MALE
)
pedigree = Pedigree()
pedigree.persons.append(
    person,
)

@acabrelles
Copy link

acabrelles commented Dec 5, 2024

@ielis thank you so much, I did not realize that it was right there this whole time! I assumed it'd be like Cohorts. Thank you!

Thank you for the quick replies!

@julesjacobsen
Copy link
Collaborator Author

Closing this issue as the Pedigree model project has been in limbo for a couple of years now.

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

No branches or pull requests

6 participants