-
Notifications
You must be signed in to change notification settings - Fork 2
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
tweaks to the alignstats reports and lumen theme #203
Conversation
📝 WalkthroughWalkthroughThis pull request updates various components across reporting configuration, document processing, styling, and a Python demultiplexing script. In the Quarto configuration file, the logo is changed from PNG to SVG, themes are updated, and a header section with favicon links is added. Two QMD report files have been streamlined by removing redundant checks and commented-out code while standardizing parameter usage and output handling. The SCSS file now defines new styling variables, and the demultiplexing script has refined its control flow by eliminating an unused dictionary and updating read-count logic. Changes
Sequence Diagram(s)sequenceDiagram
participant Input
participant process_input as "process_input()"
participant Calculator as "Metrics Calculator"
participant DataFrame as "datarow DataFrame"
Input->>process_input: Provide input table (tb)
process_input->>Calculator: Calculate metrics (reads, barcodes, stats)
Calculator-->>process_input: Return computed values
process_input->>process_input: Replace NA values with zeros
process_input->>DataFrame: Construct result datarow
DataFrame-->>process_input: Return datarow
sequenceDiagram
participant Reads as "Read Stream"
participant Demux as "demultiplex_gen1.py"
participant Map as "clear_read_map"
participant Logger as "Logger"
Reads->>Demux: Iterate over each read
alt Read status is "unclear"
Demux->>Demux: Skip processing for unclear read
else Read status is "corrected" or "found"
Demux->>Map: Update or initialize count in clear_read_map
end
Demux->>Logger: Log updated clear read counts
Possibly related PRs
Suggested labels
✨ Finishing Touches
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
🧹 Nitpick comments (4)
harpy/reports/align_bxstats.qmd (1)
76-77
: Consider removing commented-out code.These commented lines are no longer needed as the NA/NaN handling has been moved to line 86.
- #datarow[is.na(datarow)] <- 0 - #datarow[is.nan(datarow)] <- 0harpy/reports/_quarto.yml (3)
5-5
: Fix indentation for execute section.The execute section should be indented with 2 spaces to match YAML structure.
- echo: false + echo: false🧰 Tools
🪛 YAMLlint (1.35.1)
[warning] 5-5: wrong indentation: expected 2 but found 4
(indentation)
10-12
: Remove trailing space in theme section.Remove the trailing space after 'theme:' to maintain consistent formatting.
- theme: + theme:🧰 Tools
🪛 YAMLlint (1.35.1)
[error] 10-10: trailing spaces
(trailing-spaces)
23-26
: Add newline at end of file.Add a newline character at the end of the file to follow YAML best practices.
<link rel="icon" type="image/x-icon" href="https://raw.githubusercontent.com/pdimens/harpy/docs/static/favicon_report.svg"> +
🧰 Tools
🪛 YAMLlint (1.35.1)
[error] 26-26: no new line character at the end of file
(new-line-at-end-of-file)
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (5)
harpy/reports/_quarto.yml
(1 hunks)harpy/reports/align_bxstats.qmd
(1 hunks)harpy/reports/align_stats.qmd
(0 hunks)harpy/reports/harpy.scss
(1 hunks)harpy/scripts/demultiplex_gen1.py
(1 hunks)
💤 Files with no reviewable changes (1)
- harpy/reports/align_stats.qmd
🧰 Additional context used
🪛 YAMLlint (1.35.1)
harpy/reports/_quarto.yml
[warning] 5-5: wrong indentation: expected 2 but found 4
(indentation)
[error] 10-10: trailing spaces
(trailing-spaces)
[error] 26-26: no new line character at the end of file
(new-line-at-end-of-file)
⏰ Context from checks skipped due to timeout of 90000ms (1)
- GitHub Check: Build/Cache Container
🔇 Additional comments (6)
harpy/scripts/demultiplex_gen1.py (3)
137-139
: LGTM! Early return for unclear reads.The code now efficiently skips processing unclear reads by using an early continue statement.
139-144
: LGTM! Simplified corrected reads handling.The code correctly updates the count of corrected reads in clear_read_map, initializing if needed.
144-149
: LGTM! Streamlined found reads handling.The code efficiently updates the count of found reads in clear_read_map, initializing if needed.
harpy/reports/align_bxstats.qmd (2)
35-37
: LGTM! Simplified valid BX handling.The code efficiently processes valid BX tags with clear variable assignments and formatting.
86-86
: LGTM! Added NA handling for aggregate_df.This change aligns with the PR objective to handle NA values in sample statistics.
harpy/reports/harpy.scss (1)
1-17
: LGTM! Well-structured SCSS configuration.The SCSS file is well-organized with clear sections for defaults and rules. The font configuration with fallbacks and conditional import is a good practice.
NA
andNaN
sample stats as0
.lumen
theme to harpy reports, to mimic the cleaner style they were with flexdashboardTODO
There needs to be a followup PR where the
_quarto.yml
andharpy.scss
files are pulled from github in the rules. This design would make the report styles consistent with the latest design, regardless of what harpy version you're on.Summary by CodeRabbit
Style
Refactor