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

Healpix doc #2498

Open
wants to merge 25 commits into
base: main
Choose a base branch
from
Open

Healpix doc #2498

wants to merge 25 commits into from

Conversation

Vidushi-GitHub
Copy link
Member

@Vidushi-GitHub Vidushi-GitHub commented Jul 29, 2024

Description

Add document for parsing and using HEALPix docs

Explaining what it represents, how one can understand a skymap

  • Mollweide skymap shape, compare to map of glob projected onto flat surface
  • What are multi-order skymaps?
  • Explain difference between them, why they exist (size)
  • How to work with healpix maps
  • Which packages you need, here you can link to the various package documentations
  • What each of the packages do
  • Read in a skymap
  • How to identify credibility regions (existing IGWN docs are pretty much what we need)
  • Identifying a point being inside that credibility region
  • Finding probability of cone/polygon (essentially credibility region for x%) (another IGWN doc)
  • At the end of the section, link to IGWN docs for further information (or at start of section? Can discuss)
  • Usage of 2d/3d skymaps, link to more extensive docs on this topic
  • Moc papers?

Resolves: #2035

@lpsinger
Copy link
Member

Please fix the following build error:

css-bundle-entry-module:__remix_cssBundleEntryModule__:45:25: ERROR: [plugin: remix-mdx] Could not parse import/exports with acorn: SyntaxError: Unexpected token [plugin css-bundle-plugin]

The cause of this error is the imports in your Python sample code, which is enclosed in triple quotes ('''). Triple quotes don't do anything in Markdown, so the MDX parser is attempting to interpret those lines as JavaScript imports. The correct delimiter for a code block in Markdown is triple backticks (```).

app/routes/docs.notices.healpix.mdx Outdated Show resolved Hide resolved
app/routes/docs.client.samples.md Outdated Show resolved Hide resolved
@tylerbarna
Copy link
Member

Is there a reason why we still have this marked as a draft?

Copy link

codecov bot commented Oct 7, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 6.06%. Comparing base (9a85dc8) to head (8d0bd2c).
Report is 5 commits behind head on main.

Additional details and impacted files
@@          Coverage Diff          @@
##            main   #2498   +/-   ##
=====================================
  Coverage   6.06%   6.06%           
=====================================
  Files        171     171           
  Lines       4334    4334           
  Branches     476     476           
=====================================
  Hits         263     263           
  Misses      4069    4069           
  Partials       2       2           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@dakota002 dakota002 marked this pull request as ready for review October 9, 2024 16:29
@Vidushi-GitHub
Copy link
Member Author

Is there a reason why we still have this marked as a draft?

Following #2035, two points are still incomplete:
(a) making a joint skymap by multiplying and normalizing two skymaps
(b) describe usage of 2d and 3d skymaps

@jracusin
Copy link
Contributor

What happened to the documentation on including healpix maps in producing notices?

@Vidushi-GitHub
Copy link
Member Author

Vidushi-GitHub commented Dec 2, 2024

What happened to the documentation on including healpix maps in producing notices?

If I understand it correctly it should be similar as
"healpix_fits_url": {
"type": "string",
"description": "URL or file path to the HEALPix FITS map"
}

Then consumer needs document to read it from the above doc.

@Vidushi-GitHub
Copy link
Member Author

What happened to the documentation on including healpix maps in producing notices?

If I understand it correctly it should be similar as "healpix_fits_url": { "type": "string", "description": "URL or file path to the HEALPix FITS map" }

Then consumer needs document to read it from the above doc.

For attaching the fits file, it's mentioned in PR: https://github.com/nasa-gcn/gcn.nasa.gov/pull/2669/files

Is this sufficient?

@jracusin
Copy link
Contributor

Add a list of categories of sample codes at the top linking to the appropriate headings.

@Vidushi-GitHub
Copy link
Member Author

Vidushi-GitHub commented Dec 18, 2024

Recent Version screenshot! There are some breaks, which are not well captured with screenshots.
For cross-linking point of view, we haven's discussed any word about skymaps over Unified Schema page. Shall we, then only we can add link?

Screenshot 2024-12-18 at 2 48 42 PM Screenshot 2024-12-18 at 2 49 19 PM Screenshot 2024-12-18 at 2 49 30 PM Screenshot 2024-12-18 at 2 49 42 PM

Copy link
Member

@lpsinger lpsinger left a comment

Choose a reason for hiding this comment

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

This is starting to look good. Just some typos and code errors.

app/routes/docs.client.samples.md Outdated Show resolved Hide resolved
hpx, header = hp.read_map('*.fits.gz,0', h=True)

# Plotting a Mollweide-projection all-sky map
np.mollview(hpx)
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
np.mollview(hpx)
hp.mollview(hpx)

Copy link
Member

Choose a reason for hiding this comment

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

Also, if you actually want the plot to appear, then you have to add:

from matplotlib import pyplot as plt

plt.show()

app/routes/docs.client.samples.md Outdated Show resolved Hide resolved
app/routes/docs.client.samples.md Outdated Show resolved Hide resolved
app/routes/docs.client.samples.md Outdated Show resolved Hide resolved
app/routes/docs.client.samples.md Outdated Show resolved Hide resolved
app/routes/docs.client.samples.md Outdated Show resolved Hide resolved
app/routes/docs.client.samples.md Outdated Show resolved Hide resolved
app/routes/docs.client.samples.md Outdated Show resolved Hide resolved
Comment on lines +323 to +326
xyz = [[-0.5, -0.4, -0.5],
[-0.4, -0.4, -0.6],
[-0.6, -0.3, -0.6],
[-0.7 , -0.4, -0.5]]
Copy link
Member

Choose a reason for hiding this comment

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

These are not unit vectors.

Vidushi-GitHub and others added 20 commits December 21, 2024 19:59
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.

add documentation on parsing and using HEALPix maps
4 participants