Skip to content

Commit fb7d7ea

Browse files
committed
Initial commit
0 parents  commit fb7d7ea

108 files changed

Lines changed: 68543 additions & 0 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/copilot-instructions.md

Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
# AI agent guide for this repo
2+
3+
This repo is an Astro 5 + MDX site with optional React "islands," Tailwind CSS v4, math rendered through KaTeX, and a small PDF→image pipeline. It renders a single-page research project site from `src/paper.mdx` using `src/pages/index.astro` as the layout and a curated set of components.
4+
5+
## Architecture and key files
6+
7+
- Astro + MDX content
8+
- Entry content: `src/paper.mdx` (MDX with YAML frontmatter). Frontmatter keys: `title`, `authors`, `conference`, `notes`, `links`, `description`, `favicon`, `thumbnail`, `theme`.
9+
- Layout: `src/pages/index.astro` imports the content and frontmatter from `src/paper.mdx`, sets `<html data-theme>`, OpenGraph tags, favicon, and uses `import.meta.env.BASE_URL` to prefix public assets for GitHub Pages.
10+
- Components (examples)
11+
- `Figure.astro` provides a consistent figure/caption pattern via named slots `figure` and `caption`.
12+
- `Picture.astro` wraps `astro:assets` with PDF support via `src/lib/render-pdf.ts`. `src` accepts either an `ImageMetadata` import or a string path ending with `.pdf` (path is resolved relative to `./src/pages/`).
13+
- `Video.astro`, `YouTubeVideo.astro`, `ModelViewer.astro` (`<model-viewer>`), `Carousel.astro`/`CarouselSlide.astro`, `Comparison.tsx` (React compare slider). React components require a `client:*` hydration directive when used inside MDX/`.astro`.
14+
- Math is rendered with `remark-math` + `rehype-katex`, so just write inline `$...$` or block `$$...$$` expressions inside MDX—no dedicated component is needed.
15+
- Styling
16+
- Tailwind v4 via `@tailwindcss/vite`; global styles in `src/styles/global.css` with a custom `dark` variant keyed off `data-theme`.
17+
- Code blocks themed with `astro-expressive-code` (see `astro.config.ts` styleOverrides and theme selector).
18+
- TypeScript & paths
19+
- TS strict config with JSX set to React; alias `@/*``./src/*` in `tsconfig.json`.
20+
21+
## Developer workflows
22+
23+
- Node.js: Local docs recommend Node 24+. CI uses Node 20 (see `.github/workflows/astro.yml`). If you adopt Node 24-only features, update the workflow accordingly.
24+
- Install & run
25+
- `npm install`
26+
- `npm run dev`http://localhost:4321
27+
- `npm run build` runs typecheck (`astro check`) then `astro build`
28+
- `npm run preview` serves the built site
29+
- Lint/format (configured but no npm scripts):
30+
- ESLint: `eslint.config.ts` covers JS/TS/TSX, Astro, JSON, Markdown, and CSS (Tailwind v4 syntax). Run with `npx eslint .`.
31+
- Prettier: `prettier.config.ts` with `prettier-plugin-astro` and `prettier-plugin-tailwindcss`. Run with `npx prettier -w .`.
32+
- Deploy
33+
- GitHub Pages is the default. Pushing to `main` builds and deploys via `.github/workflows/astro.yml`. The workflow passes `--site`/`--base`, so use `import.meta.env.BASE_URL` for public URLs (the layout in `src/pages/index.astro` already handles favicon/OG). Vercel/Netlify buttons also exist in `README.md`.
34+
35+
## Project-specific conventions
36+
37+
- Content lives in `src/paper.mdx`; import components at top and optionally map MD elements (e.g., `export const components = { table: Table }`).
38+
- Layout logic lives in `src/pages/index.astro`, which imports the content and frontmatter from `src/paper.mdx` using `import { Content, frontmatter } from "../paper.mdx"`.
39+
- Use the provided components for consistent layout:
40+
- Wrap visuals in `<Figure>` with slots: `<slot name="figure"/>` and `<slot name="caption"/>`.
41+
- Prefer `<Picture>` for images. It accepts:
42+
- imported images (Astro's `ImageMetadata`) for optimized images; or
43+
- a relative PDF path like `"../assets/plot.pdf"` to auto-render page 1 to PNG during build/dev.
44+
- `Carousel` expects `CarouselSlide` children to render each slide; place any markup inside each slide and the component handles pagination buttons, swipe, and keyboard focus states for you.
45+
- For React, import the component and add a hydration directive where used, e.g., `<Comparison client:idle>…</Comparison>`.
46+
- Theme handling
47+
- Set `theme` in frontmatter to `device | light | dark`. The layout in `src/pages/index.astro` writes `data-theme` and Tailwind's custom `dark` variant reads it. Use class `dark:*` utilities as needed; you can invert images in dark mode via `<Picture invertInDarkMode />`.
48+
- Assets & paths
49+
- Public assets in `public/` are served at the base URL; when constructing absolute URLs in the layout (`src/pages/index.astro`) or components, prefix with `import.meta.env.BASE_URL` (the layout already exposes `prefix`).
50+
- PDF conversion reads from `./src/pages/<path>` and writes to `dist/_astro/<name>.png`. In dev, `Picture.astro` points to `../dist/_astro/...`; in prod it points to `_astro/...`. Only the first page is rendered at 4× scale.
51+
52+
## Integration points and examples
53+
54+
- Icons via `astro-icon` using Iconify sets (see dependencies `@iconify-json/academicons`, `@iconify-json/ri`). Example: frontmatter `links` items include `icon: academicons:arxiv`.
55+
- Code blocks are styled by `astro-expressive-code`; don't manually theme them—follow the existing configuration in `astro.config.ts`.
56+
- To add a new interactive component:
57+
1. Create it under `src/components/` (Astro or React).
58+
1. Import it in `src/paper.mdx`.
59+
1. For React, add `client:*` (e.g., `client:idle`) at the usage site.
60+
61+
If anything here seems off or incomplete (tests aren’t defined, additional pages, alt deploys), tell me what’s missing and I’ll refine these instructions.

.github/workflows/astro.yml

Lines changed: 83 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,83 @@
1+
# Sample workflow for building and deploying an Astro site to GitHub Pages
2+
#
3+
# To get started with Astro see: https://docs.astro.build/en/getting-started/
4+
#
5+
name: Deploy Astro site to Pages
6+
on:
7+
# Runs on pushes targeting the default branch
8+
push:
9+
branches: ["website"]
10+
# Allows you to run this workflow manually from the Actions tab
11+
workflow_dispatch:
12+
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
13+
permissions:
14+
contents: read
15+
pages: write
16+
id-token: write
17+
# Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued.
18+
# However, do NOT cancel in-progress runs as we want to allow these production deployments to complete.
19+
concurrency:
20+
group: "pages"
21+
cancel-in-progress: false
22+
env:
23+
BUILD_PATH: "." # default value when not using subfolders
24+
# BUILD_PATH: subfolder
25+
jobs:
26+
build:
27+
name: Build
28+
runs-on: ubuntu-latest
29+
steps:
30+
- name: Checkout
31+
uses: actions/checkout@v4
32+
- name: Detect package manager
33+
id: detect-package-manager
34+
run: |
35+
if [ -f "${{ github.workspace }}/yarn.lock" ]; then
36+
echo "manager=yarn" >> $GITHUB_OUTPUT
37+
echo "command=install" >> $GITHUB_OUTPUT
38+
echo "runner=yarn" >> $GITHUB_OUTPUT
39+
echo "lockfile=yarn.lock" >> $GITHUB_OUTPUT
40+
exit 0
41+
elif [ -f "${{ github.workspace }}/package.json" ]; then
42+
echo "manager=npm" >> $GITHUB_OUTPUT
43+
echo "command=ci" >> $GITHUB_OUTPUT
44+
echo "runner=npx --no-install" >> $GITHUB_OUTPUT
45+
echo "lockfile=package-lock.json" >> $GITHUB_OUTPUT
46+
exit 0
47+
else
48+
echo "Unable to determine package manager"
49+
exit 1
50+
fi
51+
- name: Setup Node
52+
uses: actions/setup-node@v4
53+
with:
54+
node-version: "20"
55+
cache: ${{ steps.detect-package-manager.outputs.manager }}
56+
cache-dependency-path: ${{ env.BUILD_PATH }}/${{ steps.detect-package-manager.outputs.lockfile }}
57+
- name: Setup Pages
58+
id: pages
59+
uses: actions/configure-pages@v5
60+
- name: Install dependencies
61+
run: ${{ steps.detect-package-manager.outputs.manager }} ${{ steps.detect-package-manager.outputs.command }}
62+
working-directory: ${{ env.BUILD_PATH }}
63+
- name: Build with Astro
64+
run: |
65+
${{ steps.detect-package-manager.outputs.runner }} astro build \
66+
--site "${{ steps.pages.outputs.origin }}" \
67+
--base "${{ steps.pages.outputs.base_path }}"
68+
working-directory: ${{ env.BUILD_PATH }}
69+
- name: Upload artifact
70+
uses: actions/upload-pages-artifact@v3
71+
with:
72+
path: ${{ env.BUILD_PATH }}/dist
73+
deploy:
74+
environment:
75+
name: github-pages
76+
url: ${{ steps.deployment.outputs.page_url }}
77+
needs: build
78+
runs-on: ubuntu-latest
79+
name: Deploy
80+
steps:
81+
- name: Deploy to GitHub Pages
82+
id: deployment
83+
uses: actions/deploy-pages@v4

.github/workflows/pre-commit.yml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
name: pre-commit
2+
on:
3+
pull_request:
4+
push:
5+
branches:
6+
- '*'
7+
- '*/*'
8+
- '**'
9+
jobs:
10+
pre-commit:
11+
runs-on: ubuntu-latest
12+
steps:
13+
- uses: actions/checkout@v3
14+
- uses: actions/setup-node@v4
15+
with:
16+
node-version: "22"
17+
cache: npm
18+
- run: npm ci
19+
- uses: actions/setup-python@v3
20+
- uses: pre-commit/action@v3.0.0

.gitignore

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
### VisualStudioCode ###
2+
.vscode/*
3+
!.vscode/settings.json
4+
!.vscode/tasks.json
5+
!.vscode/launch.json
6+
!.vscode/extensions.json
7+
!.vscode/*.code-snippets
8+
9+
# Local History for Visual Studio Code
10+
.history/
11+
12+
# Built Visual Studio Code Extensions
13+
*.vsix
14+
15+
### VisualStudioCode Patch ###
16+
# Ignore all local history of files
17+
.history
18+
.ionide
19+
20+
# build output
21+
dist/
22+
23+
# generated types
24+
.astro/
25+
26+
# dependencies
27+
node_modules/
28+
29+
# logs
30+
npm-debug.log*
31+
yarn-debug.log*
32+
yarn-error.log*
33+
pnpm-debug.log*
34+
35+
# environment variables
36+
.env
37+
.env.production
38+
39+
# macOS-specific files
40+
.DS_Store
41+
42+
# jetbrains setting folder
43+
.idea/
44+
45+
# vim swap files
46+
*.swp
47+
*.swo

.pre-commit-config.yaml

Lines changed: 101 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,101 @@
1+
---
2+
# See https://pre-commit.com for more information
3+
# See https://pre-commit.com/hooks.html for more hooks
4+
5+
# Don't run pre-commit on files under any thirdparty/, third_party/, third-party/, etc. sub-folders
6+
# But will run on directories like third/.../../party/, etc.
7+
exclude: (?i)^(.*third[^/]*party/.*|.*\.trt)$
8+
9+
repos:
10+
- repo: https://github.com/sirosen/check-jsonschema # check-jsonschema is a github actions and workflows verifier.
11+
rev: 0.37.1
12+
hooks:
13+
- id: check-github-actions
14+
- id: check-github-workflows
15+
16+
# Uses repo-root Prettier (prettier-plugin-astro, tailwind) + ESLint + Astro.
17+
# Requires `npm ci` first — see .github/workflows/pre-commit.yml.
18+
- repo: local
19+
hooks:
20+
- id: prettier
21+
name: prettier
22+
language: system
23+
entry: npm exec -- prettier --write --
24+
files: (^prettier\.config\.ts$)|(.*\.(astro|css|scss|json|[jt]sx?|mjs|cjs|mdx|html))$
25+
exclude: (?i)^(dist/.*|\.astro/.*|.*main.*scss)$
26+
- id: eslint
27+
name: eslint
28+
language: system
29+
entry: npm exec -- eslint --fix --max-warnings 0 --
30+
files: (^eslint\.config\.ts$)|(.*\.(astro|tsx?|jsx?|mjs|cjs|json|md|mts|cts))$
31+
exclude: (?i)^(dist/.*|\.astro/.*|package-lock\.json)$
32+
- id: astro-check
33+
name: astro check
34+
language: system
35+
entry: npm run check
36+
pass_filenames: false
37+
38+
- repo: https://github.com/google/yamlfmt
39+
rev: v0.21.0
40+
hooks:
41+
- id: yamlfmt
42+
exclude: (?i)(.pre-commit-config.yaml)$
43+
44+
- repo: https://github.com/jonasbb/pre-commit-latex-hooks
45+
rev: v1.5.0
46+
hooks:
47+
- id: american-eg-ie
48+
- id: cleveref-capitalization
49+
- id: consistent-spelling
50+
args:
51+
[
52+
"--emph=et al.",
53+
"--emph=a priori",
54+
"--emph=a posteriori",
55+
'--regex=naive=\bna(i|\\"i)ve',
56+
]
57+
- id: csquotes
58+
- id: ensure-labels-for-sections
59+
args:
60+
[
61+
# If present only check that there is a \label{} but not the value
62+
"--ignore-label-content",
63+
]
64+
- id: no-space-in-cite
65+
- id: tilde-cite
66+
- id: unique-labels
67+
# args:
68+
# [
69+
# # If present only check for uniqueness within each file.
70+
# # Can be useful if a repository contains multiple main files.
71+
# "--individual",
72+
# ]
73+
- id: cleveref-instead-of-autoref
74+
75+
- repo: https://github.com/cmhughes/latexindent.pl.git
76+
rev: V4.0
77+
hooks:
78+
- id: latexindent
79+
80+
- repo: https://github.com/executablebooks/mdformat # mdformat is a markdown formatter.
81+
rev: 1.0.0
82+
hooks:
83+
- id: mdformat
84+
85+
- repo: https://github.com/pre-commit/pre-commit-hooks # pre-commit-hooks is a collection of additional pre-commit hooks.
86+
rev: v6.0.0
87+
hooks:
88+
# - id: requirements-txt-fixer # fixes requirements.txt and requirements-dev.txt.
89+
# - id: check-added-large-files # prevents giant files from being committed.
90+
- id: check-case-conflict # checks for files that would conflict in case-insensitive filesystem.
91+
- id: check-merge-conflict # checks for files that contain merge conflict strings.
92+
- id: check-yaml # checks yaml files for parseable syntax.
93+
args:
94+
- --allow-multiple-documents
95+
- --unsafe
96+
# - id: check-executables-have-shebangs # ensures that (non-binary) executables have a shebang.
97+
# - id: check-shebang-scripts-are-executable # ensures that (non-binary) files with a shebang are executable.
98+
- id: end-of-file-fixer # ensures that a file is either empty, or ends with one newline.
99+
- id: fix-byte-order-marker # removes utf-8 byte order marker.
100+
- id: mixed-line-ending # replaces or checks mixed line ending.
101+
- id: trailing-whitespace # trims trailing whitespace.

.prettierignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# As of 2025-10-18, Prettier only supports MDX v1.0.
2+
# See https://github.com/prettier/prettier/issues/12209 for updates.
3+
*.mdx

CITATION.cff

Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
cff-version: 1.2.0
2+
title: "Unified Spherical Frontend"
3+
message: "If you use this software, please cite it using the metadata from this file."
4+
type: software
5+
authors:
6+
- given-names: Mukai
7+
family-names: Yu
8+
affiliation: "Carnegie Mellon University"
9+
orcid: "https://orcid.org/0000-0002-3838-4172"
10+
- given-names: Mosam
11+
family-names: Dabhi
12+
affiliation: "Carnegie Mellon University"
13+
orcid: "https://orcid.org/0000-0001-5822-3838"
14+
- given-names: Liuyue
15+
family-names: Xie
16+
affiliation: "Carnegie Mellon University"
17+
orcid: "https://orcid.org/0000-0001-7125-5084"
18+
- given-names: Sebastian
19+
family-names: Scherer
20+
affiliation: "Carnegie Mellon University"
21+
orcid: "https://orcid.org/0000-0002-8373-4688"
22+
- given-names: "László A."
23+
family-names: Jeni
24+
affiliation: "Carnegie Mellon University"
25+
orcid: "https://orcid.org/0000-0002-2830-700X"
26+
repository-code: "https://github.com/Tom-Notch/USF"
27+
url: "https://tomnotch.com/USF"
28+
license: GPL-3.0
29+
preferred-citation:
30+
type: conference-paper
31+
title: "Unified Spherical Frontend: Learning Rotation-Equivariant Representations of Spherical Images from Any Camera"
32+
authors:
33+
- given-names: Mukai
34+
family-names: Yu
35+
affiliation: "Carnegie Mellon University"
36+
orcid: "https://orcid.org/0000-0002-3838-4172"
37+
- given-names: Mosam
38+
family-names: Dabhi
39+
affiliation: "Carnegie Mellon University"
40+
orcid: "https://orcid.org/0000-0001-5822-3838"
41+
- given-names: Liuyue
42+
family-names: Xie
43+
affiliation: "Carnegie Mellon University"
44+
orcid: "https://orcid.org/0000-0001-7125-5084"
45+
- given-names: Sebastian
46+
family-names: Scherer
47+
affiliation: "Carnegie Mellon University"
48+
orcid: "https://orcid.org/0000-0002-8373-4688"
49+
- given-names: "László A."
50+
family-names: Jeni
51+
affiliation: "Carnegie Mellon University"
52+
orcid: "https://orcid.org/0000-0002-2830-700X"
53+
collection-title: "IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR)"
54+
year: 2026
55+
month: 6
56+
publisher:
57+
name: IEEE

0 commit comments

Comments
 (0)