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

add synapse_with_neuron schema #84

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

jinhan
Copy link

@jinhan jinhan commented Apr 8, 2024

Adding SynapseWithNeuron class that inherits SynapseSchema.
In SynapseWithNeuron, pre_neuron_pt is a point of the sample voxel of the neuron where the presynaptic compartment of the synapse is located. post_neuron_pt is for the postsynaptic compartment.

@fcollman
Copy link
Collaborator

fcollman commented Apr 8, 2024

It seems you just want to use this schema.. https://github.com/CAVEconnectome/EMAnnotationSchemas/blob/master/emannotationschemas/schemas/synapse.py#L10

I think you should just add this to the advertised set of schemas.. you have made subtle changes to the column names which don't follow the conventions of other synapse schemas.

@jinhan
Copy link
Author

jinhan commented Apr 8, 2024

I would like to add each of the pre_neuron_pt and post_neuron_pt while keeping the synapse schema. Could you explain more about how to add to the advertised set of schemas?

@fcollman
Copy link
Collaborator

fcollman commented Apr 8, 2024

from the README of the repo:

Import this schema into init.py, and add the schema to the type_mapping dictionary, giving it a string based key. This will be the annotation_type of your new class of annotation.

you didn't add this to the dictionary.. this is how you go from string>python class.

I'm suggesting that you import the already existing BaseSynapseSchema with 'pre_pt' and 'post_pt' so this schema matches all the other synapse schemas, rather than pre_pt_neuron and post_pt_neuron. This will just make the column names longer 'pre_pt_neuron_root_id' and 'post_pt_neuron_root_id' which is kind of a lot to type and not really that much clearer. Plus you can have synapses not onto neurons (i.e. OPC and astrocyte) so its not good from a biology point of view.

@jinhan
Copy link
Author

jinhan commented Apr 8, 2024

I added the schema name to the dictionary.

I'm sorry that my goal for this new schema is unclear. I want to use both pre_pt and pre_neuron_pt in the same schema. So I need to add other columns for neuron ids even though I inherit BaseSynapseSchema. This image shows the schema that I expected.
Screenshot 2024-04-08 at 16 02 58

I agree that neuron is inappropriate term regarding generalization.

@fcollman
Copy link
Collaborator

fcollman commented Apr 8, 2024 via email

@jinhan
Copy link
Author

jinhan commented Apr 9, 2024

I think neuron_pts may only be needed for our synapses table. As you know, I try to utilize pre/post neuron id in our dataset to solve the problem of some synapses and segments not being linked. And I thought that BoundSpatialPoints was the way to get supervoxe_id and root_id.
If this is a case specific to our dataset, should I just use it in my repository rather than push it to this repository?

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