-
Notifications
You must be signed in to change notification settings - Fork 1
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
Updates on NN architecture, Filters, redshift and tests #17
Open
haukekoehn
wants to merge
30
commits into
ThibeauWouters:main
Choose a base branch
from
haukekoehn:train_fluxes
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
variational autoencoders.
training and use of conditional variational autoencoders.
lightcurve_model.py. Additionally, adapted settings for AfterglowData.py for pbag.
DataManager class. Also added some of the principle for utils.ImageScaler
method to the Filter class.
preprocess_svd method to it for LightCurveTrainer. Also removed now superfluous lines at the end of neuralnets.py.
it can deal both with LightcurveModels and FluxModels.
SVDLightcurveTrainer. Preprocessing is done by DataManager.
vectorized get_mag method.
FluxModels now use the proper filter get_mags method that is mapped over the spectral flux array using jax.tree.map
github. Also small changes in pylint workflow.
flake8 from the unittest workflow, because flake8 does not recognize the jaxtyping options Array[Float, "n"] and we have an extra workflow with pylint anyways.
For the installation with pip install . Despite not necessary since python 3.3 I found that it does not work without it in my setup. Also changed the installation in the workflow files.
Remove benchmark result of the models as these are not necessary to have on the repo. Updated.gitignore accordingly
Surrogates will now take redshift and luminosity distance into account, i.e. the predict() method directly returns the apparent magnitude in the specified filters. This also means that for the flux models the times are rescaled, so we will have to see how to deal with that.
magnitude function is now defined when initializing a utils.Filter instance depending whether it is a monochromatic or not, so branching with jax.lax.cond is not necessary anymore.
afgpy, pbag, and surrogates.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Some commits that all together now incorporate a couple new features in a consistent way to the package.
New features are:
-cVAEs for for surrogate models
-old SVDModel (nmma style) for surrogate models
-Conversions for spectral flux densities, in particular Filter instances can now calculate the magnitude lightcurve from a 2D flux array.
-Unittest workflow that (as of now) tests some components of the code.
-Surrogate models now predict the apparent magnitude based on the redshift and luminosity distance passed on to them