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

Format, restructure and invalidiations #195

Merged
merged 25 commits into from
Jun 14, 2024
Merged

Conversation

oameye
Copy link
Member

@oameye oameye commented Jun 13, 2024

The PR does many things:

  • I added a formatter CI, which formats all files to have a uniform stye. If someone makes a PR, It will format the branch to a unified chose style. Atm I went for JuliaDiff/BlueStyle: A Julia style guide that lives in a blue world (github.com).
  • I checked that there are now implicit imports with ExplicitImports.jl. This makes sure that there are no name clashes and every code that is used from a dependency is explicitly stated. This makes our lives also easier when debugging code. I added these checks also to the test suite.
  • I tested the package with JuliaTesting/Aqua.jl: Auto QUality Assurance for Julia packages (github.com). The packages check if the quality of the code is up to standards, i.e., no method-ambiguities (see example), no stale dependencies, all dependencies have compat entry, no type-piracy, etc ... Again, these test are also added to the test suite.
  • I also did some quick checks with JET.jl. This package is the most exciting. It hunt for type-instabilities. This increase the performance of the code by making it easier for the compiler to compile the function methods. Type instabilities is the largest reason that our time-to-first-execution is so large when computing the equations. I have hunted down a couple, but we still need to do more.
  • I added a bit more test, although we need much more in general. I think only 40% of the code is covered in the tests.

https://github.com/aviatesk/JET.jl
https://github.com/ericphanson/ExplicitImports.jl
https://github.com/domluna/JuliaFormatter.jl
https://github.com/MilesCranmer/DispatchDoctor.jl
https://github.com/JuliaTesting/Aqua.jl

src/Symbolics_customised.jl Outdated Show resolved Hide resolved
src/modules/KrylovBogoliubov.jl Outdated Show resolved Hide resolved
@oameye oameye mentioned this pull request Jun 13, 2024
oameye and others added 2 commits June 13, 2024 09:58
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
@oameye oameye marked this pull request as draft June 13, 2024 09:31
oameye and others added 2 commits June 13, 2024 11:53
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
src/Symbolics_utils.jl Outdated Show resolved Hide resolved
This commit refactors the `HarmonicBalance.jl` file to export only the necessary functions and modules. It removes the `ODEProblem`, `solve`, `ODESystem`, and `plot_1D_solutions_branch` functions, as well as the `HC_wrapper.jl` and `LimitCycles.jl` modules. Additionally, it adds the `get_cycle_variables`, `get_limit_cycles`, and `add_pairs!` functions from the `LimitCycles.jl` module.
src/DifferentialEquation.jl Outdated Show resolved Hide resolved
src/modules/LinearResponse/Lorentzian_spectrum.jl Outdated Show resolved Hide resolved
test/HarmonicVariable.jl Outdated Show resolved Hide resolved
@oameye oameye marked this pull request as ready for review June 14, 2024 07:50
@oameye oameye linked an issue Jun 14, 2024 that may be closed by this pull request
test/hysteresis_sweep.jl Outdated Show resolved Hide resolved
test/limit_cycle.jl Outdated Show resolved Hide resolved
@oameye oameye merged commit 0441755 into master Jun 14, 2024
4 checks passed
@oameye oameye deleted the format_style_invalidationsv2 branch June 14, 2024 09:31
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.

Check implicit imports
2 participants