NNPDF / nnusf

An open source machine learning framework that provides predictions for all-energy neutrino structure functions.
https://nnpdf.github.io/nnusf/
GNU General Public License v3.0
0 stars 0 forks source link

Cosmetics on fit #15

Closed alecandido closed 2 years ago

alecandido commented 2 years ago

I added some colors to the table:

image

Now it highlights those with the highest per-point chi2: in yellow, if out by a $1\sigma$, in red, if out by $2\sigma$ or more.

The code is terrible, but it should be refactored together with the information coming from outside the function.

Moreover, you can now specify the print frequency (how many epochs between updates) in the runcard itself.

Radonirinaunimi commented 2 years ago

This is very useful!! I looked at the code, tested it, and everything looks fine. There are indeed various things we could/have to improve in terms of cosmetics, but for the time being I am if this gets merged.

While on it, I also realized that we are all using different options for black (especially for --line-length). We should perhaps impose a standard in the pre-commit hook and use this instead?

RoyStegeman commented 2 years ago

Yes I use line length of 80 because 88 is just a bit long for the xps monitor for my taste, and I think this outweighs the negatives of a shorter line length. Not really a huge issue though, so if a democratic vote favors 88 I'm happy to change my ways ;).

alecandido commented 2 years ago

I can adapt to whatever: I won't change my user-wide configurations, but I promise I will always run pre-commit, so whatever configs you put there I will commit with that one :)

Radonirinaunimi commented 2 years ago

Okay, let's settle to 80. We can define the configurations in a different PR and change everything at once.

RoyStegeman commented 2 years ago

I guess this can be merged?

Radonirinaunimi commented 2 years ago

I guess this can be merged?

Yep! Please go ahead.