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

Tutorial is missing import statements #8

Closed
cmbiwer opened this issue Dec 5, 2023 · 3 comments
Closed

Tutorial is missing import statements #8

cmbiwer opened this issue Dec 5, 2023 · 3 comments

Comments

@cmbiwer
Copy link

cmbiwer commented Dec 5, 2023

This page is missing the import statements to make the code useful to the user: https://pygwb.docs.ligo.org/pygwb/simulator.html#injecting-a-power-spectrum-in-random-ligo-noise

I am finding myself, stumbling through finding all the missing import statements to do it. It would be much more helpful if these were provided. Especially since gwpy.frequencyseries cannot be imported as from gwpy import frequencyseries.

@cmbiwer cmbiwer changed the title Tutorial is missing import statments Tutorial is missing import statements Dec 5, 2023
@cmbiwer
Copy link
Author

cmbiwer commented Dec 5, 2023

There is also a typo in this tutorial. There's an extra indentation in:

 net_HL = Network('HL', ifo_list)

@cmbiwer
Copy link
Author

cmbiwer commented Dec 5, 2023

And now I am stuck at:

Traceback (most recent call last):
  File "/Users/cmbiwer/src/pygwb/test.py", line 55, in <module>
    H1 = Interferometer.get_empty_interferometer("H1") #LIGO Hanford detector
AttributeError: type object 'Interferometer' has no attribute 'get_empty_interferometer'

Looking at the link to that the tutorial gives: https://lscsoft.docs.ligo.org/bilby/api/bilby.gw.detector.html

It doesn't look like this function exists?

It seems I need maybe something like:

import bilby.gw.detector

And maybe:

from pygwb.detector import Interferometer

And there's still more after that.

It seems this page needs a little bit more to help the user without debugging too much.

@kevinturbang
Copy link
Collaborator

Dear @cmbiwer, thank you for going through the tutorial. Indeed, this tutorial could have used a bit more polishing. This has been addressed in the most recent merge request. The above comments have been addressed in the new version of the tutorial.

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

No branches or pull requests

2 participants