shift-nth-row-n-steps 0.0.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,22 @@
1
+
2
+ MIT License
3
+
4
+ Copyright (c) 2024 34j
5
+
6
+ Permission is hereby granted, free of charge, to any person obtaining a copy
7
+ of this software and associated documentation files (the "Software"), to deal
8
+ in the Software without restriction, including without limitation the rights
9
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
10
+ copies of the Software, and to permit persons to whom the Software is
11
+ furnished to do so, subject to the following conditions:
12
+
13
+ The above copyright notice and this permission notice shall be included in all
14
+ copies or substantial portions of the Software.
15
+
16
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
21
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
22
+ SOFTWARE.
@@ -0,0 +1,109 @@
1
+ Metadata-Version: 2.1
2
+ Name: shift-nth-row-n-steps
3
+ Version: 0.0.0
4
+ Summary: Shift Nth row N steps in NumPy / PyTorch / TensorFlow / JAX
5
+ Home-page: https://github.com/34j/shift-nth-row-n-steps
6
+ License: MIT
7
+ Author: 34j
8
+ Author-email: 34j.github@proton.me
9
+ Requires-Python: >=3.8,<4.0
10
+ Classifier: Development Status :: 2 - Pre-Alpha
11
+ Classifier: Intended Audience :: Developers
12
+ Classifier: License :: OSI Approved :: MIT License
13
+ Classifier: Natural Language :: English
14
+ Classifier: Operating System :: OS Independent
15
+ Classifier: Programming Language :: Python :: 3
16
+ Classifier: Programming Language :: Python :: 3.8
17
+ Classifier: Programming Language :: Python :: 3.9
18
+ Classifier: Programming Language :: Python :: 3.10
19
+ Classifier: Programming Language :: Python :: 3.11
20
+ Classifier: Programming Language :: Python :: 3.12
21
+ Classifier: Programming Language :: Python :: 3.13
22
+ Classifier: Topic :: Software Development :: Libraries
23
+ Requires-Dist: rich (>=10)
24
+ Requires-Dist: typer[all] (>=0.9.0,<0.10.0)
25
+ Project-URL: Bug Tracker, https://github.com/34j/shift-nth-row-n-steps/issues
26
+ Project-URL: Changelog, https://github.com/34j/shift-nth-row-n-steps/blob/main/CHANGELOG.md
27
+ Project-URL: Documentation, https://shift-nth-row-n-steps.readthedocs.io
28
+ Project-URL: Repository, https://github.com/34j/shift-nth-row-n-steps
29
+ Description-Content-Type: text/markdown
30
+
31
+ # Shift Nth Row N Steps
32
+
33
+ <p align="center">
34
+ <a href="https://github.com/34j/shift-nth-row-n-steps/actions/workflows/ci.yml?query=branch%3Amain">
35
+ <img src="https://img.shields.io/github/actions/workflow/status/34j/shift-nth-row-n-steps/ci.yml?branch=main&label=CI&logo=github&style=flat-square" alt="CI Status" >
36
+ </a>
37
+ <a href="https://shift-nth-row-n-steps.readthedocs.io">
38
+ <img src="https://img.shields.io/readthedocs/shift-nth-row-n-steps.svg?logo=read-the-docs&logoColor=fff&style=flat-square" alt="Documentation Status">
39
+ </a>
40
+ <a href="https://codecov.io/gh/34j/shift-nth-row-n-steps">
41
+ <img src="https://img.shields.io/codecov/c/github/34j/shift-nth-row-n-steps.svg?logo=codecov&logoColor=fff&style=flat-square" alt="Test coverage percentage">
42
+ </a>
43
+ </p>
44
+ <p align="center">
45
+ <a href="https://python-poetry.org/">
46
+ <img src="https://img.shields.io/endpoint?url=https://python-poetry.org/badge/v0.json" alt="Poetry">
47
+ </a>
48
+ <a href="https://github.com/astral-sh/ruff">
49
+ <img src="https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json" alt="Ruff">
50
+ </a>
51
+ <a href="https://github.com/pre-commit/pre-commit">
52
+ <img src="https://img.shields.io/badge/pre--commit-enabled-brightgreen?logo=pre-commit&logoColor=white&style=flat-square" alt="pre-commit">
53
+ </a>
54
+ </p>
55
+ <p align="center">
56
+ <a href="https://pypi.org/project/shift-nth-row-n-steps/">
57
+ <img src="https://img.shields.io/pypi/v/shift-nth-row-n-steps.svg?logo=python&logoColor=fff&style=flat-square" alt="PyPI Version">
58
+ </a>
59
+ <img src="https://img.shields.io/pypi/pyversions/shift-nth-row-n-steps.svg?style=flat-square&logo=python&amp;logoColor=fff" alt="Supported Python versions">
60
+ <img src="https://img.shields.io/pypi/l/shift-nth-row-n-steps.svg?style=flat-square" alt="License">
61
+ </p>
62
+
63
+ ---
64
+
65
+ **Documentation**: <a href="https://shift-nth-row-n-steps.readthedocs.io" target="_blank">https://shift-nth-row-n-steps.readthedocs.io </a>
66
+
67
+ **Source Code**: <a href="https://github.com/34j/shift-nth-row-n-steps" target="_blank">https://github.com/34j/shift-nth-row-n-steps </a>
68
+
69
+ ---
70
+
71
+ Shift Nth row N steps in NumPy / PyTorch / TensorFlow / JAX
72
+
73
+ ## Installation
74
+
75
+ Install this via pip (or your favourite package manager):
76
+
77
+ `pip install shift-nth-row-n-steps`
78
+
79
+ ## Contributors ✨
80
+
81
+ Thanks goes to these wonderful people ([emoji key](https://allcontributors.org/docs/en/emoji-key)):
82
+
83
+ <!-- prettier-ignore-start -->
84
+ <!-- ALL-CONTRIBUTORS-LIST:START - Do not remove or modify this section -->
85
+ <!-- prettier-ignore-start -->
86
+ <!-- markdownlint-disable -->
87
+ <table>
88
+ <tbody>
89
+ <tr>
90
+ <td align="center" valign="top" width="14.28%"><a href="https://github.com/34j"><img src="https://avatars.githubusercontent.com/u/55338215?v=4?s=80" width="80px;" alt="34j"/><br /><sub><b>34j</b></sub></a><br /><a href="https://github.com/34j/shift-nth-row-n-steps/commits?author=34j" title="Code">💻</a> <a href="#ideas-34j" title="Ideas, Planning, & Feedback">🤔</a> <a href="https://github.com/34j/shift-nth-row-n-steps/commits?author=34j" title="Documentation">📖</a></td>
91
+ </tr>
92
+ </tbody>
93
+ </table>
94
+
95
+ <!-- markdownlint-restore -->
96
+ <!-- prettier-ignore-end -->
97
+
98
+ <!-- ALL-CONTRIBUTORS-LIST:END -->
99
+ <!-- prettier-ignore-end -->
100
+
101
+ This project follows the [all-contributors](https://github.com/all-contributors/all-contributors) specification. Contributions of any kind welcome!
102
+
103
+ ## Credits
104
+
105
+ This package was created with
106
+ [Copier](https://copier.readthedocs.io/) and the
107
+ [browniebroke/pypackage-template](https://github.com/browniebroke/pypackage-template)
108
+ project template.
109
+
@@ -0,0 +1,78 @@
1
+ # Shift Nth Row N Steps
2
+
3
+ <p align="center">
4
+ <a href="https://github.com/34j/shift-nth-row-n-steps/actions/workflows/ci.yml?query=branch%3Amain">
5
+ <img src="https://img.shields.io/github/actions/workflow/status/34j/shift-nth-row-n-steps/ci.yml?branch=main&label=CI&logo=github&style=flat-square" alt="CI Status" >
6
+ </a>
7
+ <a href="https://shift-nth-row-n-steps.readthedocs.io">
8
+ <img src="https://img.shields.io/readthedocs/shift-nth-row-n-steps.svg?logo=read-the-docs&logoColor=fff&style=flat-square" alt="Documentation Status">
9
+ </a>
10
+ <a href="https://codecov.io/gh/34j/shift-nth-row-n-steps">
11
+ <img src="https://img.shields.io/codecov/c/github/34j/shift-nth-row-n-steps.svg?logo=codecov&logoColor=fff&style=flat-square" alt="Test coverage percentage">
12
+ </a>
13
+ </p>
14
+ <p align="center">
15
+ <a href="https://python-poetry.org/">
16
+ <img src="https://img.shields.io/endpoint?url=https://python-poetry.org/badge/v0.json" alt="Poetry">
17
+ </a>
18
+ <a href="https://github.com/astral-sh/ruff">
19
+ <img src="https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json" alt="Ruff">
20
+ </a>
21
+ <a href="https://github.com/pre-commit/pre-commit">
22
+ <img src="https://img.shields.io/badge/pre--commit-enabled-brightgreen?logo=pre-commit&logoColor=white&style=flat-square" alt="pre-commit">
23
+ </a>
24
+ </p>
25
+ <p align="center">
26
+ <a href="https://pypi.org/project/shift-nth-row-n-steps/">
27
+ <img src="https://img.shields.io/pypi/v/shift-nth-row-n-steps.svg?logo=python&logoColor=fff&style=flat-square" alt="PyPI Version">
28
+ </a>
29
+ <img src="https://img.shields.io/pypi/pyversions/shift-nth-row-n-steps.svg?style=flat-square&logo=python&amp;logoColor=fff" alt="Supported Python versions">
30
+ <img src="https://img.shields.io/pypi/l/shift-nth-row-n-steps.svg?style=flat-square" alt="License">
31
+ </p>
32
+
33
+ ---
34
+
35
+ **Documentation**: <a href="https://shift-nth-row-n-steps.readthedocs.io" target="_blank">https://shift-nth-row-n-steps.readthedocs.io </a>
36
+
37
+ **Source Code**: <a href="https://github.com/34j/shift-nth-row-n-steps" target="_blank">https://github.com/34j/shift-nth-row-n-steps </a>
38
+
39
+ ---
40
+
41
+ Shift Nth row N steps in NumPy / PyTorch / TensorFlow / JAX
42
+
43
+ ## Installation
44
+
45
+ Install this via pip (or your favourite package manager):
46
+
47
+ `pip install shift-nth-row-n-steps`
48
+
49
+ ## Contributors ✨
50
+
51
+ Thanks goes to these wonderful people ([emoji key](https://allcontributors.org/docs/en/emoji-key)):
52
+
53
+ <!-- prettier-ignore-start -->
54
+ <!-- ALL-CONTRIBUTORS-LIST:START - Do not remove or modify this section -->
55
+ <!-- prettier-ignore-start -->
56
+ <!-- markdownlint-disable -->
57
+ <table>
58
+ <tbody>
59
+ <tr>
60
+ <td align="center" valign="top" width="14.28%"><a href="https://github.com/34j"><img src="https://avatars.githubusercontent.com/u/55338215?v=4?s=80" width="80px;" alt="34j"/><br /><sub><b>34j</b></sub></a><br /><a href="https://github.com/34j/shift-nth-row-n-steps/commits?author=34j" title="Code">💻</a> <a href="#ideas-34j" title="Ideas, Planning, & Feedback">🤔</a> <a href="https://github.com/34j/shift-nth-row-n-steps/commits?author=34j" title="Documentation">📖</a></td>
61
+ </tr>
62
+ </tbody>
63
+ </table>
64
+
65
+ <!-- markdownlint-restore -->
66
+ <!-- prettier-ignore-end -->
67
+
68
+ <!-- ALL-CONTRIBUTORS-LIST:END -->
69
+ <!-- prettier-ignore-end -->
70
+
71
+ This project follows the [all-contributors](https://github.com/all-contributors/all-contributors) specification. Contributions of any kind welcome!
72
+
73
+ ## Credits
74
+
75
+ This package was created with
76
+ [Copier](https://copier.readthedocs.io/) and the
77
+ [browniebroke/pypackage-template](https://github.com/browniebroke/pypackage-template)
78
+ project template.
@@ -0,0 +1,154 @@
1
+ [build-system]
2
+ build-backend = "poetry.core.masonry.api"
3
+ requires = [ "poetry-core>=1.0.0" ]
4
+
5
+ [tool.poetry]
6
+ name = "shift-nth-row-n-steps"
7
+ version = "0.0.0"
8
+ description = "Shift Nth row N steps in NumPy / PyTorch / TensorFlow / JAX"
9
+ authors = [ "34j <34j.github@proton.me>" ]
10
+ license = "MIT"
11
+ readme = "README.md"
12
+ repository = "https://github.com/34j/shift-nth-row-n-steps"
13
+ documentation = "https://shift-nth-row-n-steps.readthedocs.io"
14
+ classifiers = [
15
+ "Development Status :: 2 - Pre-Alpha",
16
+ "Intended Audience :: Developers",
17
+ "Natural Language :: English",
18
+ "Operating System :: OS Independent",
19
+ "Topic :: Software Development :: Libraries",
20
+ ]
21
+ packages = [
22
+ { include = "shift_nth_row_n_steps", from = "src" },
23
+ ]
24
+
25
+ [tool.poetry.urls]
26
+ "Bug Tracker" = "https://github.com/34j/shift-nth-row-n-steps/issues"
27
+ "Changelog" = "https://github.com/34j/shift-nth-row-n-steps/blob/main/CHANGELOG.md"
28
+
29
+ [tool.poetry.scripts]
30
+ shift-nth-row-n-steps = "shift_nth_row_n_steps.cli:app"
31
+
32
+ [tool.poetry.dependencies]
33
+ python = "^3.8"
34
+ rich = ">=10"
35
+ typer = { extras = [ "all" ], version = "^0.9.0" }
36
+
37
+ [tool.poetry.group.dev.dependencies]
38
+ pytest = "^8.0.0"
39
+ pytest-cov = "^5.0.0"
40
+
41
+ [tool.poetry.group.docs]
42
+ optional = true
43
+
44
+ [tool.poetry.group.docs.dependencies]
45
+ myst-parser = { version = ">=0.16", python = ">=3.11" }
46
+ sphinx = { version = ">=4.0", python = ">=3.11" }
47
+ furo = { version = ">=2023.5.20", python = ">=3.11" }
48
+ sphinx-autobuild = { version = ">=2024.0.0", python = ">=3.11" }
49
+
50
+ [tool.ruff]
51
+ target-version = "py38"
52
+ line-length = 88
53
+ lint.select = [
54
+ "B", # flake8-bugbear
55
+ "D", # flake8-docstrings
56
+ "C4", # flake8-comprehensions
57
+ "S", # flake8-bandit
58
+ "F", # pyflake
59
+ "E", # pycodestyle
60
+ "W", # pycodestyle
61
+ "UP", # pyupgrade
62
+ "I", # isort
63
+ "RUF", # ruff specific
64
+ ]
65
+ lint.ignore = [
66
+ "D203", # 1 blank line required before class docstring
67
+ "D212", # Multi-line docstring summary should start at the first line
68
+ "D100", # Missing docstring in public module
69
+ "D104", # Missing docstring in public package
70
+ "D107", # Missing docstring in `__init__`
71
+ "D401", # First line of docstring should be in imperative mood
72
+ ]
73
+ lint.per-file-ignores."conftest.py" = [ "D100" ]
74
+ lint.per-file-ignores."docs/conf.py" = [ "D100" ]
75
+ lint.per-file-ignores."setup.py" = [ "D100" ]
76
+ lint.per-file-ignores."tests/**/*" = [
77
+ "D100",
78
+ "D101",
79
+ "D102",
80
+ "D103",
81
+ "D104",
82
+ "S101",
83
+ ]
84
+ lint.isort.known-first-party = [ "shift_nth_row_n_steps", "tests" ]
85
+
86
+ [tool.pytest.ini_options]
87
+ addopts = """\
88
+ -v
89
+ -Wdefault
90
+ --cov=shift_nth_row_n_steps
91
+ --cov-report=term
92
+ --cov-report=xml
93
+ """
94
+ pythonpath = [ "src" ]
95
+
96
+ [tool.coverage.run]
97
+ branch = true
98
+
99
+ [tool.coverage.report]
100
+ exclude_lines = [
101
+ "pragma: no cover",
102
+ "@overload",
103
+ "if TYPE_CHECKING",
104
+ "raise NotImplementedError",
105
+ 'if __name__ == "__main__":',
106
+ ]
107
+
108
+ [tool.mypy]
109
+ check_untyped_defs = true
110
+ disallow_any_generics = true
111
+ disallow_incomplete_defs = true
112
+ disallow_untyped_defs = true
113
+ mypy_path = "src/"
114
+ no_implicit_optional = true
115
+ show_error_codes = true
116
+ warn_unreachable = true
117
+ warn_unused_ignores = true
118
+ exclude = [
119
+ 'docs/.*',
120
+ 'setup.py',
121
+ ]
122
+
123
+ [[tool.mypy.overrides]]
124
+ module = "tests.*"
125
+ allow_untyped_defs = true
126
+
127
+ [[tool.mypy.overrides]]
128
+ module = "docs.*"
129
+ ignore_errors = true
130
+
131
+ [tool.semantic_release]
132
+ version_toml = [ "pyproject.toml:tool.poetry.version" ]
133
+ version_variables = [
134
+ "src/shift_nth_row_n_steps/__init__.py:__version__",
135
+ "docs/conf.py:release",
136
+ ]
137
+ build_command = "pip install poetry && poetry build"
138
+
139
+ [tool.semantic_release.changelog]
140
+ exclude_commit_patterns = [
141
+ "chore.*",
142
+ "ci.*",
143
+ "Merge pull request .*",
144
+ ]
145
+
146
+ [tool.semantic_release.changelog.environment]
147
+ keep_trailing_newline = true
148
+
149
+ [tool.semantic_release.branches.main]
150
+ match = "main"
151
+
152
+ [tool.semantic_release.branches.noop]
153
+ match = "(?!main$)"
154
+ prerelease = true
@@ -0,0 +1 @@
1
+ __version__ = "0.0.0"
@@ -0,0 +1,5 @@
1
+ """Make the CLI runnable using python -m shift_nth_row_n_steps."""
2
+
3
+ from .cli import app
4
+
5
+ app(prog_name="shift-nth-row-n-steps")
@@ -0,0 +1,12 @@
1
+ import typer
2
+ from rich import print
3
+
4
+ from .main import add
5
+
6
+ app = typer.Typer()
7
+
8
+
9
+ @app.command()
10
+ def main(n1: int, n2: int) -> None:
11
+ """Add the arguments and print the result."""
12
+ print(add(n1, n2))
@@ -0,0 +1,3 @@
1
+ def add(n1: int, n2: int) -> int:
2
+ """Add the arguments."""
3
+ return n1 + n2