Skip to main content

Capture window - run yolov5 - show results

pip install yolov5windowdetect

Update 2022/10/25

Run multiple detection models

winca = (

    Yolov5WindowDetect(

        pt_file=r"C:\Users\Gamer\anaconda3\envs\dfdir\yolov5\runs\train\playerbutton7\weights\best.pt",

        repo_or_dir="./yolov5",

        model="custom",

        source="local",

    )

    .add_models(

        pt_file=r"C:\Users\Gamer\anaconda3\envs\dfdir\yolov5\runs\train\playerbutton6\weights\best.pt",

        repo_or_dir="./yolov5",

        model="custom",

        source="local",

    )

    .get_hwnd_window(window_title_regex=r"[Bb]lue[sS]tacks.*")

    .take_screenshot_and_run_yolov(

        confidence_thresh=0.3,

        show_results=True,

        quit_key="q",

        sleep_time=0.04,

        rununtilstopped=True,

    )

)
from yolov5windowdetect import Yolov5WindowDetect

winca = (

    Yolov5WindowDetect(

        pt_file=r"C:\Users\.....\best.pt",

        repo_or_dir="./yolov5",

        model="custom",

        source="local",

    )

    .get_hwnd_window(window_title_regex=r"[Bb]lue[Ss]tacks.*")

    .take_screenshot_and_run_yolov(

        confidence_thresh=0.3,

        show_results=True,

        quit_key="q",

        sleep_time=0.04,

        rununtilstopped=True,

    )

)



# window capture -> don't show results, only results as df

winca.get_hwnd_window(

    window_title_regex=r"[Bb]lue[Ss]tacks.*"

).take_screenshot_and_run_yolov(

    confidence_thresh=0.3, show_results=False, rununtilstopped=False,

).get_results_as_df()





# adb capture

winca.get_adb_window(

    adb_path=r"C:\ProgramData\adb\adb.exe", adb_serial="localhost:5555",

).take_screenshot_and_run_yolov(

    confidence_thresh=0.3, show_results=False, rununtilstopped=False,

).get_results_as_df()

Example

  <a href="https://www.youtube.com/watch?v=-jXqL39Tf5w">

     <img src="https://img.youtube.com/vi/-jXqL39Tf5w/0.jpg" style="width:100%;">

  </a>

Metadata

Release files for yolov5windowdetect 0.11

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for yolov5windowdetect 0.11
File Size Uploaded Provenance Actions
yolov5windowdetect-0.11.tar.gz 6.2 kB Without provenance Details for yolov5windowdetect-0.11.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for yolov5windowdetect 0.11
File Interpreter ABI Platform Actions
yolov5windowdetect-0.11-py3-none-any.whl Python 3 none any Details for yolov5windowdetect-0.11-py3-none-any.whl

Total release size: 13.9 kB

Release files / yolov5windowdetect-0.11.tar.gz

Download URL yolov5windowdetect-0.11.tar.gz
Size 6.2 kB
Tags Source
SHA-256 checksum
How to use checksums
405de5ee61d778ea8158ccc64f52a79312a15dfd12cd1ce013ab4c713fe63604
BLAKE2b-256 checksum
How to use checksums
e6e0b563da3770acf026b88b3b9d51e2427f158cf090419b449abe620f9b85c8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.9.13

Release files / yolov5windowdetect-0.11-py3-none-any.whl

Download URL yolov5windowdetect-0.11-py3-none-any.whl
Size 7.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
ce2c0dffda4d4142bc93ae5f493ca3f367d67dbb66e67bb4d053e47ebeff1067
BLAKE2b-256 checksum
How to use checksums
9ad54e477c80ddc9632a494695d3da2877fca73b55eeb0f399bd72447a27d25d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.9.13

Security for yolov5windowdetect 0.11

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.11 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page