-
Notifications
You must be signed in to change notification settings - Fork 1
Cleanup actions #81
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
Cleanup actions #81
Conversation
… deploy tests on a PR, cleand up the makefile, and added stuff to contributing on the documentation.
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.
Pull Request Overview
This PR applies automated code formatting across the ceREEBerus codebase using Black, a Python auto-formatter. The changes standardize code style including quote consistency (single to double quotes), spacing around operators and parameters, line breaks, and indentation.
Key Changes
- Converted all string quotes from single to double quotes throughout the codebase
- Standardized spacing around operators, function parameters, and assignments
- Reformatted long lines and function calls for better readability
- Added trailing commas in multi-line structures
- Removed extraneous blank lines and standardized comment formatting
Reviewed Changes
Copilot reviewed 36 out of 37 changed files in this pull request and generated 40 comments.
Show a summary per file
| File | Description |
|---|---|
| requirements.txt | New file listing project dependencies |
| doc_source/contributing.rst | Expanded contributing guide with formatting, testing, and PR guidelines |
| cereeberus/cereeberus/reeb/reebgraph.py | Reformatted with consistent spacing and quote style |
| cereeberus/cereeberus/reeb/merge.py | Reformatted with consistent spacing and quote style |
| cereeberus/cereeberus/reeb/mapper.py | Reformatted with consistent spacing and quote style |
| cereeberus/cereeberus/reeb/lowerstar.py | Reformatted with consistent spacing and quote style |
| cereeberus/cereeberus/reeb/embeddedgraph.py | Reformatted with consistent spacing and quote style |
| cereeberus/cereeberus/reeb/init.py | Reformatted with double quotes |
| cereeberus/cereeberus/distance/labeled_blocks.py | Reformatted with consistent spacing and quote style |
| cereeberus/cereeberus/distance/interleave.py | Reformatted with consistent spacing and quote style |
| cereeberus/cereeberus/distance/ilp.py | Reformatted with consistent spacing and quote style |
| cereeberus/cereeberus/distance/init.py | Reformatted with double quotes |
| cereeberus/cereeberus/data/*.py | Multiple data module files reformatted with consistent style |
| cereeberus/cereeberus/compute/*.py | Compute module files reformatted with consistent style |
Comments suppressed due to low confidence (2)
cereeberus/cereeberus/distance/interleave.py:4
- Import of 'block_diag' is not used.
from scipy.linalg import block_diag
cereeberus/cereeberus/distance/interleave.py:6
- Import of 'UnionFind' is not used.
from ..compute.unionfind import UnionFind
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| viridis = mpl.colormaps["viridis"].resampled(16) | ||
|
|
Copilot
AI
Nov 4, 2025
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.
Variable viridis is not used.
| viridis = mpl.colormaps["viridis"].resampled(16) |
| search_data = {} | ||
| search_data = {} | ||
|
|
||
| # -- Set the initial value of the distance bound to be infinity | ||
| distance_bound = np.inf |
Copilot
AI
Nov 4, 2025
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.
Variable distance_bound is not used.
| distance_bound = np.inf |
| titles[3] = f"$D_{{{end_graph}^{{n}}}}^{{V}} \\cdot ({titles[2][1:-1]})$" | ||
|
|
||
| fig, axs = self._draw_matrix_mult(Top, Bottom, Result, Result_Dist, titles = titles) | ||
| fig, axs = self._draw_matrix_mult( |
Copilot
AI
Nov 4, 2025
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.
Variable fig is not used.
| fig, axs = self._draw_matrix_mult( | |
| self._draw_matrix_mult( |
| titles[3] = f"$D_{{{end_graph}^{{n}}}}^{{V}} \\cdot ({titles[2][1:-1]})$" | ||
|
|
||
| fig, axs = self._draw_matrix_mult(Top, Bottom, Result, Result_Dist, titles = titles) | ||
| fig, axs = self._draw_matrix_mult( |
Copilot
AI
Nov 4, 2025
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.
Variable axs is not used.
| fig, axs = self._draw_matrix_mult( | |
| fig = self._draw_matrix_mult( |
|
|
||
| fig, axs = self._draw_matrix_mult(Top, Bottom, Result, Result_Dist, titles = titles) | ||
| fig, axs = self._draw_matrix_mult( |
Copilot
AI
Nov 4, 2025
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.
Variable fig is not used.
| fig, axs = self._draw_matrix_mult( | |
| self._draw_matrix_mult( |
| except: | ||
| print("Error") | ||
| print(f"c: {c}") | ||
| print(f"map_dict: {map_dict}") | ||
| print(f"cols_: {cols_}") | ||
| print(f"rows_: {rows_}") | ||
| print(f"blocks[i]: {self.blocks[i]}") | ||
| ValueError("Column object {c} not in map_dict") |
Copilot
AI
Nov 4, 2025
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.
Except block directly handles BaseException.
| except: | |
| print("Error") | |
| print(f"c: {c}") | |
| print(f"map_dict: {map_dict}") | |
| print(f"cols_: {cols_}") | |
| print(f"rows_: {rows_}") | |
| print(f"blocks[i]: {self.blocks[i]}") | |
| ValueError("Column object {c} not in map_dict") | |
| except KeyError: | |
| print("Error") | |
| print(f"c: {c}") | |
| print(f"map_dict: {map_dict}") | |
| print(f"cols_: {cols_}") | |
| print(f"rows_: {rows_}") | |
| print(f"blocks[i]: {self.blocks[i]}") | |
| raise ValueError(f"Column object {c} not in map_dict") |
| try: | ||
| nx.shortest_path(S.to_undirected(), u, v) | ||
| return n | ||
| except: |
Copilot
AI
Nov 4, 2025
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.
Except block directly handles BaseException.
| comp_to_new_vert = {} | ||
| # comp_to_new_vert is a dictionary with keys as indices of connected components in the list C and values as the name of the vertex in R_eps | ||
| for i,c in enumerate(C): | ||
| for i, c in enumerate(C): |
Copilot
AI
Nov 4, 2025
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.
Nested for statement uses loop variable 'i' of enclosing for statement.
| for i,c in enumerate(C_edge): | ||
| V_inv, E_inv = self.inv_image(cv - delta) | ||
|
|
||
| for i, c in enumerate(C_edge): |
Copilot
AI
Nov 4, 2025
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.
Nested for statement uses loop variable 'i' of enclosing for statement.
| print(f"cols_: {cols_}") | ||
| print(f"rows_: {rows_}") | ||
| print(f"blocks[i]: {self.blocks[i]}") | ||
| ValueError("Column object {c} not in map_dict") |
Copilot
AI
Nov 4, 2025
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.
Instantiating an exception, but not raising it, has no effect.
| ValueError("Column object {c} not in map_dict") | |
| raise ValueError(f"Column object {c} not in map_dict") |
| branches: [ "main" ] | ||
| pull_request: | ||
| branches: [ "main" ] | ||
|
|
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.
needs to be master instead
Description
Lots of folder cleanup, no changes to the code.
Motivation and Context
Neurotic cleanup. Plus we want a nice version for anonymizing later.
How has this been tested?
Types of changes
Checklist
pyproject.tomlfile if a new version needs to be pushed to pypi (note that not incrementing the number won't push to pypi and throw an error, but it will update the documentation).