Skip to main content

Simple bymlv2 parser + writer + converters

Features:

  • Supports v2, v3 and v4 files. These versions are respectively used by The Legend of Zelda: Breath of the Wild and Super Mario Odyssey.
  • Supports 64-bit node types which are used in Super Mario Odyssey.
  • Supports both endianness. The little-endian format is used on the Switch.
  • Cross platform.
  • Easy to edit and readable output. No ugly XML. Unobtrusive type information.

Quick usage

Install Python 3.6+, then run pip install byml.

The C module for PyYAML is currently a hard dependency. If you are on Windows, you don't have to do anything special. If you are on Linux or on macOS, you will need to install libyaml.

BYML to YAML

byml_to_yml  PATH_TO_BYML    PATH_TO_YAML

If the byml is compressed, this tool will automatically decompress them.

To reuse the input file name and only change the extension, use !!.NEW_EXTENSION as the second argument.

Example: to convert to YAML in the same directory as the BYML, use byml_to_yml path_to_botw/Actor/ActorInfo.product.sbyml !!.yml

YAML to BYML

yml_to_byml  PATH_TO_YAML    PATH_TO_BYML

Add -b at the end if big endian should be used. For the Wii U version of Breath of the Wild, you must pass that flag.

To reuse the input file name and only change the extension, use !!.NEW_EXTENSION as the second argument.

If the target file extension starts with .s, the tool will automatically compress the BYML using yaz0.

Note about YAML integers/floats

  • !u before an integer indicates that the value is unsigned. In general, you should keep the signedness unchanged.

  • !l is for signed 64 bit values. (Not used in BotW.)

  • !ul is for unsigned 64 bit values. (Not used in BotW.)

  • !f64 is for binary64 floating point values. (Not used in BotW.)

Advanced usage

By default, if the destination argument is not specified, output will be sent to stdout, which is handy for looking at bymls without creating temporary files.

Library usage

import byml

parser = byml.Byml(raw_bytes)
document = parser.parse()

writer = byml.Writer(document, be=big_endian_mode, version=byml_version)
writer.write(writable_seekable_stream)

License

This software is licensed under the terms of the GNU General Public License, version 2 or later.

Release files for byml 2.4.5.post1

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

Built distribution (wheel)

Table of built distributions (wheels) for byml 2.4.5.post1
File Interpreter ABI Platform
byml-2.4.5.post1-py3-none-any.whl Python 3 none any Details

Release files / byml-2.4.5.post1-py3-none-any.whl

Download URL byml-2.4.5.post1-py3-none-any.whl
Size 16.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
66669a41a507ac4450b336f099ef376b810a1588762e04813aa48259c5234fb3
BLAKE2b-256 checksum
How to use checksums
c09b61549cf2c51e23c3acd20532ce47c7349ffa8f99763f97abdff35f531573
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.0 CPython/3.12.4

Release history Release notifications | RSS feed

This release

2.4.5.post1 This release

1 release file

2.4.4

1 release file

2.4.3

1 release file

2.4.2

1 release file

2.4.1

1 release file

2.3.1

1 release file

2.3.0

1 release file

2.2.1

1 release file

2.2.0

1 release file

2.1.1

1 release file

2.1.0

1 release file

2.0.3

1 release file

2.0.2

1 release file

2.0.1

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