Possible issue with Loci.remap()
See original GitHub issueI am trying to remap a loci based on a different structure using Loci.remap()
. Sometimes this works, but sometimes it doesn’t and the output loci is empty (even if it shouldn’t be).
I have found the possible issue here: https://github.com/molstar/molstar/blob/0f5a6194ffc83b9963c2ce41e84f2625da00f203/src/mol-model/structure/structure/element/loci.ts#L152-L153
This issue could be entirely due to my wrong interpretation of how remap method should be used, but I have found that if i compare against unit.invariantId
instead of unit.id
everything seems to work fine.
if i get the unit in this way, it seems to work fine in every case in my code.
let unit
structure.units.forEach(u => {
if (u.invariantId === invId) unit = u
});
if (!unit) return
Issue Analytics
- State:
- Created a year ago
- Comments:11 (11 by maintainers)
Top Results From Across the Web
Coordinate remapping service - NCBI - NIH
We are sorry but a service supporting the Remap service is down. We expect this is a transient problem but if this persists,...
Read more >Network reconstruction for trans acting genetic loci using multi ...
We bridge the gap between the involved chromosomes by including transcription factor binding site (TFBS) information collected from ReMap [62, ...
Read more >dereneaton/ipyrad - Gitter
I ask because I'm scrounging for data and would like to find broken read pairs that map to only one side of focal...
Read more >ROS Topic Remap [Example] - The Robotics Back-End
Remapping a topic means that you'll change the topic name at run-time. If a node publishes on “topic1”, then you can make it...
Read more >How do I use OpenCV's remap function? - Stack Overflow
It and everyone on SO states you input an array (a map) of starting points, a map of ending points, and then remap()...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
All instances of the same unit have the same
chainGroupId
. Mol* doesn’t do “physical” copies of chains when rendering instances and this helps with performance of some algorithms.invariantId
will stay the between instanced copies of the same change (e.g. when creating an assembly/symmetry).From the code: