Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

O-Lib/parsecore

ParseCore

All-in-one Python library for osu! beatmap parsing, mod handling, and pp calculation. The only osu! lib you'll ever need.

PyPI Version Python License Typing pre-commit Code Style Discord


Features

  • Beatmap Parsing - Full .osu file parsing including all sections: General, Metadata, Difficulty, Events, Timing Points, Hit Objects, Colors, and Editor
  • Mod Handling - Complete mod system supporting all osu! game modes (osu!, Taiko, Catch, Mania) with legacy and modern mod representations
  • Performance Calculation - PP calculation for all supported game modes (in active development)
  • Type-safe - Fully typed codebase, mypy-checked

Installation

pip install parsecore

Or with uv:

uv add parsecore

Requires Python 3.10+


Quick Start

Beatmap Parsing

from parsecore.Beatmap import Beatmap
beatmap = Beatmap.from_path("path/to/map.osu")
print(beatmap.metadata.title)
print(beatmap.metadata.version)
print(beatmap.difficulty.approach_rate)
print(beatmap.difficulty.circle_size)
for obj in beatmap.hit_objects.objects:
 print(obj)
for tp in beatmap.timing_points.control_points.timing_points:
 print(tp.bpm)

Mod Handling

from parsecore.Mods import GameMods, GameMode, HardRockOsu, DoubleTimeOsu
mods = GameMods([HardRockOsu(), DoubleTimeOsu()])
# Legacy bitfield conversion
legacy = mods.to_legacy()
print(legacy.value)
# From acronym strings
mods = GameMods.from_acronyms(["HD", "DT"], GameMode.OSU)
# Intermode mods
from parsecore.Mods import GameModsIntermode
intermode = GameModsIntermode.from_acronyms(["HD", "NC"])

Project Structure

parsecore/
├── Beatmap/ # .osu file parsing and encoding
│ ├── beatmap.py
│ ├── reader.py
│ ├── encode.py
│ └── section/ # Individual section parsers
│ ├── general.py
│ ├── metadata.py
│ ├── difficulty.py
│ ├── timing_points.py
│ ├── hit_objects/
│ └── ...
└── Mods/ # Mod system
 ├── game_mod.py
 ├── game_mods.py
 ├── game_mode.py
 ├── generated_mods.py
 └── ...

Contributing

Contributions are welcome! Please read CONTRIBUTING.md before submitting a pull request.

Security

To report a security vulnerability, see SECURITY.md.

© 2026-Present O!Lib Team

About

All-in-one Python library for osu! beatmap parsing, mod handling, and pp calculation. The only osu! lib you'll ever need.

Topics

Resources

License

Code of conduct

Contributing

Security policy

Stars

Watchers

Forks

Releases

No releases published

Packages

Contributors

Languages

AltStyle によって変換されたページ (->オリジナル) /