Skip to main content
Pre-release

This release is a pre-release and may not be stable for production use.

oculix (Python)

Python wrapper for OculiX — visual automation for the real world.

Install

pip install oculix-operix

Requirements: Python 3.8+, Java 11+ on PATH (Eclipse Temurin or Azul Zulu).

The OculiX engine (~200 MB fat JAR) is downloaded on first use into ~/.oculix/lib/.

Quickstart

from oculix import Screen, App, VNCScreen

screen = Screen()
screen.click("login.png")
screen.type("admin")
screen.click("submit.png")
screen.wait("dashboard.png", 10)

# Open a desktop app
calc = App.open("calc")
screen.click("button_7.png")

# Drive a remote VNC display
vnc = VNCScreen.start("10.0.0.42", 5900, "", 1920, 1080)
vnc.click("logo.png")
vnc.stop()

With pytest

import pytest
from oculix import Screen, App

@pytest.fixture
def calc():
    a = App.open("calculator")
    yield a
    a.close()

def test_addition(calc):
    s = Screen()
    s.click("button_7.png")
    s.click("button_plus.png")
    s.click("button_3.png")
    s.click("button_equals.png")
    assert s.exists("result_10.png")

License

MIT

Java API parity

This fork exposes the complete pinned Oculix 4.0.0 public method surface: 211 public types with named Python methods, constructor/field access and every Java overload's arguments. from oculix import Screen, OCR, Pattern stays unchanged. Every class is also available through oculix.java; nested classes keep names such as OCR.Options and OCR.PSM.

from oculix import Screen, Pattern, Match, OCR, Location, JavaCallback, ObserverCallBack

screen = Screen()
match = screen.find(Pattern("button.png").similar(0.8))
assert isinstance(match, Match)
match.click()
screen.type("hello", 0)

options = OCR.Options().language("eng").psm(OCR.PSM.SINGLE_LINE)
text = OCR.readText("button.png", options)

# Ambiguous Java overloads can be selected explicitly.
options.psm.overload("org.sikuli.script.OCR$PSM")("SINGLE_LINE")

exists() returns Match or None, matching Java; truth checks continue to work. Java interface callbacks accept JavaCallback(interface_name, handler) and observer methods accept a Python function directly. Arrays/collections become Python sequences; maps become dictionaries; Java iterators support iteration.

This distribution uses the matching 1.1.1 JVM bridge from ajayrakde/Operix. Do not mix it with the older upstream bridge. It occupies the same oculix import namespace as upstream, so install only one of the two distributions in a virtual environment. See implementation and validation.

Metadata

Release files for oculix-operix 1.2.0b1

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

Source distribution (sdist)

Source distribution for oculix-operix 1.2.0b1
File Size Uploaded
oculix_operix-1.2.0b1.tar.gz 439.9 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for oculix-operix 1.2.0b1
File Interpreter ABI Platform
oculix_operix-1.2.0b1-py3-none-any.whl Python 3 none any Details

Total release size: 873.4 kB

Release files / oculix_operix-1.2.0b1.tar.gz

Download URL oculix_operix-1.2.0b1.tar.gz
Size 439.9 kB
Tags Source
SHA-256 checksum
How to use checksums
b7afde81d31e1ae97fb036dff3b1ffec096b7beccdfa85a3e92b06e5155a66e2
BLAKE2b-256 checksum
How to use checksums
ee959409cc01a3f9a8e363d945a19dca48641099031c91f63ccd82415da08233
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / oculix_operix-1.2.0b1-py3-none-any.whl

Download URL oculix_operix-1.2.0b1-py3-none-any.whl
Size 433.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
1470d03981dc8a52e12340b7f2f8d02a1fa9ad1d5fc186d3b9060fbb5a72ab8b
BLAKE2b-256 checksum
How to use checksums
a970970ce506fc5edb9d8f6f902a8da9353f67de6e41aa7c6925e01facf75bcd
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release history Release notifications | RSS feed

This release

1.2.0b1 This release

2 release files

1.1.1

2 release files

1.1.0

2 release files

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