Skip to content

Commit

Permalink
add scripts to pyproject.toml
Browse files Browse the repository at this point in the history
  • Loading branch information
zeptofine committed Oct 7, 2023
1 parent a382be8 commit 0083821
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
6 changes: 4 additions & 2 deletions imdataset_creator/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
)

CPU_COUNT = int(cpu_count())
logging.basicConfig(level=logging.CRITICAL, format="%(message)s", datefmt="[%X]", handlers=[RichHandler()])
logging.basicConfig(level=logging.INFO, format="%(message)s", datefmt="[%X]", handlers=[RichHandler()])
app = typer.Typer(pretty_exceptions_show_locals=True, pretty_exceptions_short=True)
log = logging.getLogger()

Expand Down Expand Up @@ -78,7 +78,9 @@ def main(
) -> int:
"""Takes a crap ton of images and creates dataset pairs"""
if not config_path.exists():
log.error(f"{config_path} does not exist. create it in the gui and restart this program.")
log.error(
f"{config_path} does not exist. create it in the gui (imdataset-creator-gui or gui.py) and restart this program."
)
return 0

with config_path.open("r") as f:
Expand Down
4 changes: 4 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ packages = [
]
readme = "README.md"
version = "0.1.0"

[tool.poetry.dependencies]
ImageHash = "^4.3.1"
Pillow = "^10.0.1"
Expand All @@ -24,6 +25,9 @@ typer = {extras = ["all"], version = "^0.9.0"}
ujson = "^5.8.0"
wcmatch = "^8.5"

[tool.poetry.scripts]
imdataset-creator = "imdataset_creator.__main__:app"
imdataset-creator-gui = "imdataset_creator.gui.main_window:main"
[build-system]
build-backend = "poetry.core.masonry.api"
requires = ["poetry-core"]

0 comments on commit 0083821

Please sign in to comment.