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

Dev snonis #93

Open
wants to merge 28 commits into
base: dev
Choose a base branch
from
Open

Dev snonis #93

wants to merge 28 commits into from

Conversation

snonis
Copy link

@snonis snonis commented Apr 22, 2024

  • New models for the antenna response (effective length).
  • New galactic noise calculations according to different antenna models.
  • New RF chain (version 2).
  • New coordinate transformations according to new convention for zenith and azimuth angles.
  • A notebook is added in the /example folder showing how to inserting/replacing new elements into the RF chain.

@mjtueros
Copy link
Contributor

hi stavros. Quick question, have you tried incorporating the new rf chain into the compute_efield2voltage.py script?. If the new code is too diferent (im on my phone now, didnt had time to check it yet), would it be posible for you to make a scrpt that provides the same functionality?. this would allow me to make comparisons with what i did for dc2.

@snonis
Copy link
Author

snonis commented Apr 25, 2024

hi Matias. You mean the script convert_efield2voltage.py? In this script yes i incorporate the new rf chain and the and the functionality is almost the same. I think you can make comparisons directly because the structure file is the same, just load the rf chain from rf_chain2.py instead of the rf_chain.py file.

Copy link
Contributor

@mjtueros mjtueros left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok, so i tried to review. I did not finish and had not looked to jupyter notebooks.
However, i already encountered some problems that did not let me test further, so im sending this change requests, in order to not stall the process.

Im worried about the fact that in the branch this is based on sim2root is very outdated, so i dont know if making the examples work is important or not for example. To be discussed in software meeting i guess.

grand/sim/detector/antenna_model.py Show resolved Hide resolved
grand/geo/coordinates.py Show resolved Hide resolved
sim2root/CoREASRawRoot/CoreasToRawROOT.py Show resolved Hide resolved
sim2root/CoREASRawRoot/CorsikaInfoFuncs.py Show resolved Hide resolved
grand/sim/efield2voltage.py Show resolved Hide resolved
scripts/convert_efield2voltage.py Outdated Show resolved Hide resolved
sim2root/CoREASRawRoot/Coreas_000004.root Outdated Show resolved Hide resolved
sim2root/CoREASRawRoot/Coreas_100018.root Outdated Show resolved Hide resolved
sim2root/CoREASRawRoot/IllustrateSimPipe.py Outdated Show resolved Hide resolved
examples/sim/efield2voltage_manually.py Outdated Show resolved Hide resolved
scripts/plot_noise.py Outdated Show resolved Hide resolved
scripts/plot_noise.py Outdated Show resolved Hide resolved
scripts/plot_noise.py Outdated Show resolved Hide resolved
Untitled.ipynb Outdated Show resolved Hide resolved
Copy link

@claireguepin claireguepin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • Most of these comments will be solved when changing paths and names for new rf_chain files.
  • The recurring problem of detector data not downloaded should be solved eventually, with some clarifications of the differences between RFchain_v1 and RFchain_v2

Example_Efield.ipynb Outdated Show resolved Hide resolved
Untitled.ipynb Outdated Show resolved Hide resolved

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All figures should be moved to a specific directory and named properly.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For information, the notebook crashes at [1], with the error
sh: 1: ../io/DataStoringExample.py: not found

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You are right but this notebook is part of the master branch, i have no involvement with the creation of this script.

"import os\n",
"import h5py\n",
"import scipy.fft as sf\n",
"import grand.sim.detector.rf_chain2 as grfc\n",

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Problem with path: change rf_chain2 -> rf_chain

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed

examples/sim/plot_VoltageAtDevice.ipynb Outdated Show resolved Hide resolved

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Crashed at [2]: FileNotFoundError: /home/grand/data/detector/RFchain_v2/NewMatchingNetworkX.s2p not found.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Crashed line 35 /home/grand/data/detector/RFchain_v2/NewMatchingNetworkX.s2p not found.

  • Similarly to figures, it could be interesting to have a directory in the examples directory with files to be used in the examples. (for instance here we use ../../data/test_efield.root)

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed

tests/sim/test_new_rf_chain_setup.ipynb Outdated Show resolved Hide resolved
@mjtueros
Copy link
Contributor

Ok, from my point of view i think all the issues i raised that could be solved where solved.

What is left standing are things that can be addressed in the future:

A) defaults for du_type? Here we have to choose between using no default and make it mandatory across all classes and functions (that i think i prefer) or choose a default (and mantain the code any time what is considered the default changes, or we can set a default name like "official du" and then make it equivalent to the one we consider to be the official at any point in time, so we change the code only where this equivalence is defined)

B) Class/function templates for documentation going forward? It would be nice to enforce that anyone creating a new function or class uses a template (even if parts of it are left empty...it kind of reminds you that you should document the function a little bit.

C) Implementing the definitive response for V2 rfchain when we know what that is in the future, as a new branch

Should i post this points as issues in github?

Once Claire is happy with the jupyter notebooks, and the comments she reviewed, we can try to go ahead with the merge.

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.

4 participants