Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update here #226

Open
github-actions bot opened this issue Aug 19, 2024 · 0 comments
Open

Update here #226

github-actions bot opened this issue Aug 19, 2024 · 0 comments
Assignees
Labels

Comments

@github-actions
Copy link

# TODO: Update here

    return uhdr_manipulator


def update_info_json(info_file, url):
    with open(info_file, "r", encoding="utf-8") as f:
        info = json.load(f)
    # TODO: Update here
    if "profile" in info:
        if len(info["profile"]) > 1 and isinstance(info["profile"][1], dict):
            if "supports" in info["profile"][1]:
                info["profile"][1]["supports"].append(PROFILE_SUPPORTS)
            else:
                info["profile"][1]["supports"] = [PROFILE_SUPPORTS]

    if "sizes" in info:
        del info["sizes"]
    with open(info_file, "w", encoding="utf-8") as f:
        json.dump(info, f)


def full(infile, dir, uhdr_options):
    result = os.path.join(dir, FULL)
    os.makedirs(os.path.dirname(result))
    uhdr = UHDR(infile, **uhdr_options)
    uhdr.process(result)


def main(args):
    actions = get_processors()

    log_stream = StringIO()
    logging.basicConfig(stream=log_stream, level=logging.DEBUG)
    parser = argparse.ArgumentParser(description="Create a staic IIIF Image API directory and file structure")
    parser.add_argument(
        "--input",
        "-i",
        action="store",
        type=pathlib.Path,
        required=True,
        help="Input file",
    )
    parser.add_argument(
        "--output",
        "-o",
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant