-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
c9d7233
commit 72ee11f
Showing
4 changed files
with
44 additions
and
34 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -19,14 +19,14 @@ | |
|
||
# -- Project information ----------------------------------------------------- | ||
|
||
project = u'card_board' | ||
copyright = u'2021, Jared Crawford <[email protected]>' | ||
author = u'Jared Crawford <[email protected]>' | ||
project = u"card_board" | ||
copyright = u"2021, Jared Crawford <[email protected]>" | ||
author = u"Jared Crawford <[email protected]>" | ||
|
||
# The short X.Y version | ||
version = u'' | ||
version = u"" | ||
# The full version, including alpha/beta/rc tags | ||
release = u'' | ||
release = u"" | ||
|
||
|
||
# -- General configuration --------------------------------------------------- | ||
|
@@ -39,23 +39,23 @@ | |
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom | ||
# ones. | ||
extensions = [ | ||
'sphinx.ext.autodoc', | ||
'sphinx.ext.doctest', | ||
'sphinx.ext.coverage', | ||
'sphinx.ext.viewcode', | ||
"sphinx.ext.autodoc", | ||
"sphinx.ext.doctest", | ||
"sphinx.ext.coverage", | ||
"sphinx.ext.viewcode", | ||
] | ||
|
||
# Add any paths that contain templates here, relative to this directory. | ||
templates_path = ['_templates'] | ||
templates_path = ["_templates"] | ||
|
||
# The suffix(es) of source filenames. | ||
# You can specify multiple suffix as a list of string: | ||
# | ||
# source_suffix = ['.rst', '.md'] | ||
source_suffix = '.rst' | ||
source_suffix = ".rst" | ||
|
||
# The master toctree document. | ||
master_doc = 'index' | ||
master_doc = "index" | ||
|
||
# The language for content autogenerated by Sphinx. Refer to documentation | ||
# for a list of supported languages. | ||
|
@@ -67,7 +67,7 @@ | |
# List of patterns, relative to source directory, that match files and | ||
# directories to ignore when looking for source files. | ||
# This pattern also affects html_static_path and html_extra_path. | ||
exclude_patterns = [u'_build', 'Thumbs.db', '.DS_Store'] | ||
exclude_patterns = [u"_build", "Thumbs.db", ".DS_Store"] | ||
|
||
# The name of the Pygments (syntax highlighting) style to use. | ||
pygments_style = None | ||
|
@@ -78,7 +78,7 @@ | |
# The theme to use for HTML and HTML Help pages. See the documentation for | ||
# a list of builtin themes. | ||
# | ||
html_theme = 'alabaster' | ||
html_theme = "alabaster" | ||
|
||
# Theme options are theme-specific and customize the look and feel of a theme | ||
# further. For a list of options available for each theme, see the | ||
|
@@ -89,7 +89,7 @@ | |
# Add any paths that contain custom static files (such as style sheets) here, | ||
# relative to this directory. They are copied after the builtin static files, | ||
# so a file named "default.css" will overwrite the builtin "default.css". | ||
html_static_path = ['_static'] | ||
html_static_path = ["_static"] | ||
|
||
# Custom sidebar templates, must be a dictionary that maps document names | ||
# to template names. | ||
|
@@ -105,7 +105,7 @@ | |
# -- Options for HTMLHelp output --------------------------------------------- | ||
|
||
# Output file base name for HTML help builder. | ||
htmlhelp_basename = 'card_boarddoc' | ||
htmlhelp_basename = "card_boarddoc" | ||
|
||
|
||
# -- Options for LaTeX output ------------------------------------------------ | ||
|
@@ -114,15 +114,12 @@ | |
# The paper size ('letterpaper' or 'a4paper'). | ||
# | ||
# 'papersize': 'letterpaper', | ||
|
||
# The font size ('10pt', '11pt' or '12pt'). | ||
# | ||
# 'pointsize': '10pt', | ||
|
||
# Additional stuff for the LaTeX preamble. | ||
# | ||
# 'preamble': '', | ||
|
||
# Latex figure (float) alignment | ||
# | ||
# 'figure_align': 'htbp', | ||
|
@@ -132,19 +129,21 @@ | |
# (source start file, target name, title, | ||
# author, documentclass [howto, manual, or own class]). | ||
latex_documents = [ | ||
(master_doc, 'card_board.tex', u'card_board Documentation', | ||
u'Jared Crawford \\textless{}[email protected]\\textgreater{}', 'manual'), | ||
( | ||
master_doc, | ||
"card_board.tex", | ||
u"card_board Documentation", | ||
u"Jared Crawford \\textless{}[email protected]\\textgreater{}", | ||
"manual", | ||
), | ||
] | ||
|
||
|
||
# -- Options for manual page output ------------------------------------------ | ||
|
||
# One entry per manual page. List of tuples | ||
# (source start file, name, description, authors, manual section). | ||
man_pages = [ | ||
(master_doc, 'card_board', u'card_board Documentation', | ||
[author], 1) | ||
] | ||
man_pages = [(master_doc, "card_board", u"card_board Documentation", [author], 1)] | ||
|
||
|
||
# -- Options for Texinfo output ---------------------------------------------- | ||
|
@@ -153,9 +152,15 @@ | |
# (source start file, target name, title, author, | ||
# dir menu entry, description, category) | ||
texinfo_documents = [ | ||
(master_doc, 'card_board', u'card_board Documentation', | ||
author, 'card_board', 'One line description of project.', | ||
'Miscellaneous'), | ||
( | ||
master_doc, | ||
"card_board", | ||
u"card_board Documentation", | ||
author, | ||
"card_board", | ||
"One line description of project.", | ||
"Miscellaneous", | ||
), | ||
] | ||
|
||
|
||
|
@@ -174,7 +179,7 @@ | |
# epub_uid = '' | ||
|
||
# A list of files that should not be packed into the epub file. | ||
epub_exclude_files = ['search.html'] | ||
epub_exclude_files = ["search.html"] | ||
|
||
|
||
# -- Extension configuration ------------------------------------------------- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
from setuptools import setup | ||
|
||
setup() | ||
setup() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,10 @@ | ||
import cv2 | ||
import pytesseract | ||
|
||
|
||
def card_from_image(path: str) -> str: | ||
custom_config = r'--oem 3 --psm 6' | ||
return pytesseract.image_to_string(path, config=custom_config) | ||
custom_config = r"--oem 3 --psm 6" | ||
return pytesseract.image_to_string(path, config=custom_config) | ||
|
||
|
||
all = ('card_from_image') | ||
all = "card_from_image" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters