Skip to content

GitLab

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
  • Sign in
pygwinc
pygwinc
  • Project overview
    • Project overview
    • Details
    • Activity
    • Releases
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
    • Locked Files
  • Issues 30
    • Issues 30
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
    • Iterations
  • Merge Requests 2
    • Merge Requests 2
  • Requirements
    • Requirements
    • List
  • CI / CD
    • CI / CD
    • Pipelines
    • Jobs
    • Schedules
    • Test Cases
  • Security & Compliance
    • Security & Compliance
    • Dependency List
    • License Compliance
  • Operations
    • Operations
    • Incidents
    • Environments
  • Packages & Registries
    • Packages & Registries
    • Container Registry
  • Analytics
    • Analytics
    • CI / CD
    • Code Review
    • Insights
    • Issue
    • Repository
    • Value Stream
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Members
    • Members
  • Collapse sidebar
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
  • gwinc
  • pygwincpygwinc
  • Merge Requests
  • !31

Merged
Opened Aug 17, 2018 by Christopher Wipf@christopher.wipfOwner

Speed up quad sus tf calculation 10x, by pre-solving the system symbolically

  • Overview 3
  • Commits 2
  • Pipelines 3
  • Changes 1

Profiling of precompIFO() before this change:

%timeit gwinc.precompIFO(freq, ifo)

404 ms ± 24 ms per loop (mean ± std. dev. of 7 runs, 1 loop each)

%prun ifo2 = gwinc.precompIFO(freq, ifo)

      693645 function calls (693211 primitive calls) in 0.833 seconds

Ordered by: internal time

ncalls  tottime  percall  cumtime  percall filename:lineno(function)
 30000    0.362    0.000    0.695    0.000 linalg.py:319(solve)
    10    0.083    0.008    0.778    0.078 suspension.py:39(calc_transfer_functions)
 30008    0.065    0.000    0.109    0.000 linalg.py:141(_commonType)
 30018    0.056    0.000    0.056    0.000 {method 'astype' of 'numpy.ndarray' objects}
 60012    0.046    0.000    0.098    0.000 linalg.py:108(_makearray)
 etc, etc

And after:

%timeit gwinc.precompIFO(freq, ifo)

28.6 ms ± 4.87 ms per loop (mean ± std. dev. of 7 runs, 10 loops each)

%prun ifo2 = gwinc.precompIFO(freq, ifo)

      3596 function calls (3162 primitive calls) in 0.032 seconds

Ordered by: internal time

ncalls  tottime  percall  cumtime  percall filename:lineno(function)
    74    0.016    0.000    0.016    0.000 coatingthermal.py:743(getCoatRefl)
    10    0.006    0.001    0.006    0.001 suspension.py:30(tst_force_to_tst_displ)
     1    0.005    0.005    0.012    0.012 suspension.py:51(suspQuad)
   137    0.001    0.000    0.001    0.000 {built-in method numpy.core.multiarray.zeros}
     2    0.001    0.000    0.001    0.000 suspension.py:40(top_displ_to_tst_displ)
etc, etc
Assignee
Assign to
Reviewer
Request review from
None
Milestone
None
Assign milestone
Time tracking
Reference: gwinc/pygwinc!31
Source branch: fast-susp-tf

Revert this merge request

This will create a new commit in order to revert the existing changes.

Switch branch
Cancel
A new branch will be created in your fork and a new merge request will be started.

Cherry-pick this merge request

Switch branch
Cancel
A new branch will be created in your fork and a new merge request will be started.