pyrekordbox.anlz package#

pyrekordbox.anlz.is_anlz_file(path)[source]#

Checks if the name of a file matches the ANLZ file name pattern.

Parameters:
pathstr or Path

The file path to check

Returns:
is_anlzbool

True if the file is an ANLZ file.

Examples

>>> is_anlz_file("ANLZ0000.DAT")
True
>>> is_anlz_file("/path/to/ANLZ0000.DAT")
False
>>> is_anlz_file("ANLZ.DAT")
False
pyrekordbox.anlz.get_anlz_paths(root)[source]#

Returns the paths of all existing ANLZ files in a directory.

Parameters:
rootstr or Path

The path of the directory containing ANLZ files.

Returns:
anlz_pathsdict[str, Path]

The file paths stored as dictionary with the type of ANLZ file as keys (“DAT”, “EXT”, “EX2”)

Examples

>>> p = get_anlz_paths("directory/")
>>> p["DAT"]
directory/ANLZ0000.DAT
pyrekordbox.anlz.walk_anlz_dirs(root_dir)[source]#

Finds all ANLZ directory paths recursively.

Parameters:
root_dirstr or Path

The path of the root directory.

Yields:
anlz_dirstr

The path of a directory containing ANLZ files

pyrekordbox.anlz.walk_anlz_paths(root_dir)[source]#

Finds all ANLZ directory paths and the containing file paths recursively.

Parameters:
root_dirstr or Path

The path of the root directory.

Yields:
anlz_dirstr

The path of a directory containing ANLZ files.

anlz_filesSequence of str

The file paths of the ANLZ files in anlz_dir.

pyrekordbox.anlz.read_anlz_files(root='')[source]#

Open all ANLZ files in the given root directory.

Parameters:
rootstr or Path, optional

The root directory of the ANLZ files to open.

Returns:
anlz_filesdict

The opened ANLZ files stored in a dict with the corresponding file paths as keys.

Submodules#