Skip to content

Optimizations to LINGER - #74

Open
arnavg115 wants to merge 4 commits into
Durenlab:mainfrom
arnavg115:main
Open

Optimizations to LINGER#74
arnavg115 wants to merge 4 commits into
Durenlab:mainfrom
arnavg115:main

Conversation

@arnavg115

Copy link
Copy Markdown
  • GPU support: GPU support for training is added but, the performance increase is negligible to negative, likely because LINGER trains many smaller neural networks. The overhead of moving tensors etc. between the cpu and gpu outweighs the performance gains. Currently I defaulted to using the cpu since it's slightly faster.
  • pd.concat: Moved pd.concat outside of loops. Due to how pd.concat copies dataframes it is inefficient to be run repetitively inside loops. Rather it's better to run once outside of a loop.
  • Minor function improvements: I made minor improvements to a couple functions like cosine_similarity and introduced new versions that are slightly faster due to using torch under the hood.
  • Vectorized T-tests: Rather than use an iterative variant, I introduced a vectorized variant which is slightly faster.
  • Formatting: I ran the black python formatter and isort. This has no effect on functionality, but does make the code easier to read.

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.

1 participant