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

Avoid getFeatures refetch for some re-rendering operations #4081

Open
cmdcolin opened this issue Nov 22, 2023 · 4 comments
Open

Avoid getFeatures refetch for some re-rendering operations #4081

cmdcolin opened this issue Nov 22, 2023 · 4 comments
Labels

Comments

@cmdcolin
Copy link
Collaborator

This is a challenge with our RPC architecture. In some ways points away from using RPC for rendering. If we change the height of e.g. the SNPCoverage track, it performs a full re-render that includes re-fetching all the features via getFeatures. It also does not abort properly it seems like. Aborting may be some measure of improvement, but the true improvement I think is to skip the re-getFeatures operation entirely.

If you imagined that the "rendering" component only had a e.g. useEffect to fetch the features, and then also did drawing code in the main thread in a separate useEffect, then the drawing code would only react to the track height changing by redrawing, not by refetching the features.

In order to achive a similar behavior for the above, we would need to establish a clause of what requires re-fetching features (similar to a useEffect dependency array). This might be possible with RPC, but an alternative approach would be to remove RPC for rendering.

@cmdcolin
Copy link
Collaborator Author

linked issue #1730

@cmdcolin
Copy link
Collaborator Author

example of specific technical component of this issue: any change to renderProps requires re-fetching through getFeatures

@cmdcolin
Copy link
Collaborator Author

cmdcolin commented Dec 5, 2023

There are a number of optimization related issues for this when RNA-seq is concerned. @carolinebridge-oicr sent some sample data that is deep iso-seq style RNA-seq and it really slows down even for relatively small amount of data (3 megabyte bam file)

@cmdcolin
Copy link
Collaborator Author

one optimization was added for this which is called the ultralongfeaturescache. it could potentially help, it reduces re-calculating the mismatches datastructure. this is a tough issue though is is on of those HOURS_WASTED_HERE++ type things when you get into the code. still high impact though

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

No branches or pull requests

1 participant