repo_full_name stringlengths 6 93 | repo_url stringlengths 25 112 | repo_api_url stringclasses 28
values | owner stringclasses 28
values | repo_name stringclasses 28
values | description stringclasses 28
values | stars int64 617 98.8k | forks int64 31 355 ⌀ | watchers int64 990 999 ⌀ | license stringclasses 2
values | default_branch stringclasses 2
values | repo_created_at timestamp[s]date 2012-07-24 23:12:50 2025-06-16 08:07:28 ⌀ | repo_updated_at timestamp[s]date 2026-02-23 15:23:15 2026-05-03 18:52:12 ⌀ | repo_topics listlengths 0 13 ⌀ | repo_languages unknown | is_fork bool 1
class | open_issues int64 3 104 ⌀ | file_path stringlengths 3 208 | file_name stringclasses 509
values | file_extension stringclasses 1
value | file_size_bytes int64 101 84k ⌀ | file_url stringclasses 627
values | file_raw_url stringclasses 627
values | file_sha stringclasses 624
values | language stringclasses 8
values | parsed_at stringdate 2026-05-04 01:12:36 2026-05-04 19:41:55 | text stringlengths 100 102k |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
google-deepmind/mujoco_playground | https://github.com/google-deepmind/mujoco_playground | null | null | null | null | 1,916 | null | null | apache-2.0 | null | null | null | null | null | null | null | mujoco_playground/_src/dm_control_suite/swimmer.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:10.937878 | # Copyright 2025 DeepMind Technologies Limited
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agre... |
google-deepmind/mujoco_playground | https://github.com/google-deepmind/mujoco_playground | null | null | null | null | 1,916 | null | null | apache-2.0 | null | null | null | null | null | null | null | mujoco_playground/_src/dm_control_suite/reacher.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:10.962322 | # Copyright 2025 DeepMind Technologies Limited
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agre... |
google-deepmind/mujoco_playground | https://github.com/google-deepmind/mujoco_playground | null | null | null | null | 1,916 | null | null | apache-2.0 | null | null | null | null | null | null | null | mujoco_playground/_src/dm_control_suite/pendulum.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:10.972944 | # Copyright 2025 DeepMind Technologies Limited
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agre... |
google-deepmind/mujoco_playground | https://github.com/google-deepmind/mujoco_playground | null | null | null | null | 1,916 | null | null | apache-2.0 | null | null | null | null | null | null | null | mujoco_playground/_src/dm_control_suite/humanoid.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:11.019156 | # Copyright 2025 DeepMind Technologies Limited
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agre... |
google-deepmind/mujoco_playground | https://github.com/google-deepmind/mujoco_playground | null | null | null | null | 1,916 | null | null | apache-2.0 | null | null | null | null | null | null | null | mujoco_playground/_src/dm_control_suite/walker.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:11.412269 | # Copyright 2025 DeepMind Technologies Limited
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agre... |
google-deepmind/mujoco_playground | https://github.com/google-deepmind/mujoco_playground | null | null | null | null | 1,916 | null | null | apache-2.0 | null | null | null | null | null | null | null | mujoco_playground/_src/locomotion/apollo/__init__.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:11.446801 | # Copyright 2025 DeepMind Technologies Limited
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agre... |
google-deepmind/mujoco_playground | https://github.com/google-deepmind/mujoco_playground | null | null | null | null | 1,916 | null | null | apache-2.0 | null | null | null | null | null | null | null | mujoco_playground/_src/gait.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:11.489386 | # Copyright 2025 DeepMind Technologies Limited
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agre... |
google-deepmind/mujoco_playground | https://github.com/google-deepmind/mujoco_playground | null | null | null | null | 1,916 | null | null | apache-2.0 | null | null | null | null | null | null | null | mujoco_playground/_src/locomotion/apollo/constants.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:11.502026 | # Copyright 2025 DeepMind Technologies Limited
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agre... |
google-deepmind/mujoco_playground | https://github.com/google-deepmind/mujoco_playground | null | null | null | null | 1,916 | null | null | apache-2.0 | null | null | null | null | null | null | null | mujoco_playground/_src/locomotion/apollo/base.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:11.506812 | # Copyright 2025 DeepMind Technologies Limited
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agre... |
google-deepmind/mujoco_playground | https://github.com/google-deepmind/mujoco_playground | null | null | null | null | 1,916 | null | null | apache-2.0 | null | null | null | null | null | null | null | mujoco_playground/_src/locomotion/apollo/joystick.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:11.517165 | # Copyright 2025 DeepMind Technologies Limited
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agre... |
google-deepmind/mujoco_playground | https://github.com/google-deepmind/mujoco_playground | null | null | null | null | 1,916 | null | null | apache-2.0 | null | null | null | null | null | null | null | mujoco_playground/_src/locomotion/barkour/__init__.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:11.544690 | # Copyright 2025 DeepMind Technologies Limited
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agre... |
google-deepmind/mujoco_playground | https://github.com/google-deepmind/mujoco_playground | null | null | null | null | 1,916 | null | null | apache-2.0 | null | null | null | null | null | null | null | mujoco_playground/_src/locomotion/__init__.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:11.552409 | # Copyright 2025 DeepMind Technologies Limited
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agre... |
google-deepmind/mujoco_playground | https://github.com/google-deepmind/mujoco_playground | null | null | null | null | 1,916 | null | null | apache-2.0 | null | null | null | null | null | null | null | mujoco_playground/_src/locomotion/berkeley_humanoid/__init__.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:11.571119 | # Copyright 2025 DeepMind Technologies Limited
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agre... |
google-deepmind/mujoco_playground | https://github.com/google-deepmind/mujoco_playground | null | null | null | null | 1,916 | null | null | apache-2.0 | null | null | null | null | null | null | null | mujoco_playground/_src/locomotion/barkour/joystick.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:11.694812 | # Copyright 2025 DeepMind Technologies Limited
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agre... |
google-deepmind/mujoco_playground | https://github.com/google-deepmind/mujoco_playground | null | null | null | null | 1,916 | null | null | apache-2.0 | null | null | null | null | null | null | null | mujoco_playground/_src/locomotion/berkeley_humanoid/base.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:11.965720 | # Copyright 2025 DeepMind Technologies Limited
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agre... |
google-deepmind/mujoco_playground | https://github.com/google-deepmind/mujoco_playground | null | null | null | null | 1,916 | null | null | apache-2.0 | null | null | null | null | null | null | null | mujoco_playground/_src/locomotion/berkeley_humanoid/berkeley_humanoid_constants.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:12.041499 | # Copyright 2025 DeepMind Technologies Limited
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agre... |
google-deepmind/mujoco_playground | https://github.com/google-deepmind/mujoco_playground | null | null | null | null | 1,916 | null | null | apache-2.0 | null | null | null | null | null | null | null | mujoco_playground/_src/locomotion/berkeley_humanoid/joystick.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:12.108038 | # Copyright 2025 DeepMind Technologies Limited
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agre... |
google-deepmind/mujoco_playground | https://github.com/google-deepmind/mujoco_playground | null | null | null | null | 1,916 | null | null | apache-2.0 | null | null | null | null | null | null | null | mujoco_playground/_src/locomotion/g1/__init__.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:12.109866 | # Copyright 2025 DeepMind Technologies Limited
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agre... |
google-deepmind/mujoco_playground | https://github.com/google-deepmind/mujoco_playground | null | null | null | null | 1,916 | null | null | apache-2.0 | null | null | null | null | null | null | null | mujoco_playground/_src/locomotion/g1/joystick.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:12.111289 | # Copyright 2025 DeepMind Technologies Limited
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agre... |
google-deepmind/mujoco_playground | https://github.com/google-deepmind/mujoco_playground | null | null | null | null | 1,916 | null | null | apache-2.0 | null | null | null | null | null | null | null | mujoco_playground/_src/locomotion/g1/base.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:12.124296 | # Copyright 2025 DeepMind Technologies Limited
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agre... |
google-deepmind/mujoco_playground | https://github.com/google-deepmind/mujoco_playground | null | null | null | null | 1,916 | null | null | apache-2.0 | null | null | null | null | null | null | null | mujoco_playground/_src/locomotion/g1/g1_constants.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:12.146404 | # Copyright 2025 DeepMind Technologies Limited
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agre... |
google-deepmind/mujoco_playground | https://github.com/google-deepmind/mujoco_playground | null | null | null | null | 1,916 | null | null | apache-2.0 | null | null | null | null | null | null | null | mujoco_playground/_src/locomotion/berkeley_humanoid/randomize.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:12.213664 | # Copyright 2025 DeepMind Technologies Limited
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agre... |
google-deepmind/mujoco_playground | https://github.com/google-deepmind/mujoco_playground | null | null | null | null | 1,916 | null | null | apache-2.0 | null | null | null | null | null | null | null | mujoco_playground/_src/locomotion/go1/__init__.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:12.215237 | # Copyright 2025 DeepMind Technologies Limited
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agre... |
google-deepmind/mujoco_playground | https://github.com/google-deepmind/mujoco_playground | null | null | null | null | 1,916 | null | null | apache-2.0 | null | null | null | null | null | null | null | mujoco_playground/_src/locomotion/g1/randomize.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:12.239203 | # Copyright 2025 DeepMind Technologies Limited
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agre... |
google-deepmind/mujoco_playground | https://github.com/google-deepmind/mujoco_playground | null | null | null | null | 1,916 | null | null | apache-2.0 | null | null | null | null | null | null | null | mujoco_playground/_src/locomotion/go1/base.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:12.619848 | # Copyright 2025 DeepMind Technologies Limited
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agre... |
google-deepmind/mujoco_playground | https://github.com/google-deepmind/mujoco_playground | null | null | null | null | 1,916 | null | null | apache-2.0 | null | null | null | null | null | null | null | mujoco_playground/_src/locomotion/go1/getup.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:12.620925 | # Copyright 2025 DeepMind Technologies Limited
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agre... |
google-deepmind/mujoco_playground | https://github.com/google-deepmind/mujoco_playground | null | null | null | null | 1,916 | null | null | apache-2.0 | null | null | null | null | null | null | null | mujoco_playground/_src/locomotion/go1/go1_constants.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:12.658175 | # Copyright 2025 DeepMind Technologies Limited
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agre... |
google-deepmind/mujoco_playground | https://github.com/google-deepmind/mujoco_playground | null | null | null | null | 1,916 | null | null | apache-2.0 | null | null | null | null | null | null | null | mujoco_playground/_src/locomotion/go1/handstand.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:12.669283 | # Copyright 2025 DeepMind Technologies Limited
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agre... |
google-deepmind/mujoco_playground | https://github.com/google-deepmind/mujoco_playground | null | null | null | null | 1,916 | null | null | apache-2.0 | null | null | null | null | null | null | null | mujoco_playground/_src/locomotion/go1/randomize.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:12.669916 | # Copyright 2025 DeepMind Technologies Limited
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agre... |
google-deepmind/mujoco_playground | https://github.com/google-deepmind/mujoco_playground | null | null | null | null | 1,916 | null | null | apache-2.0 | null | null | null | null | null | null | null | mujoco_playground/_src/locomotion/go1/joystick.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:12.723190 | # Copyright 2025 DeepMind Technologies Limited
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agre... |
google-deepmind/mujoco_playground | https://github.com/google-deepmind/mujoco_playground | null | null | null | null | 1,916 | null | null | apache-2.0 | null | null | null | null | null | null | null | mujoco_playground/_src/locomotion/h1/__init__.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:12.733260 | # Copyright 2025 DeepMind Technologies Limited
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agre... |
google-deepmind/mujoco_playground | https://github.com/google-deepmind/mujoco_playground | null | null | null | null | 1,916 | null | null | apache-2.0 | null | null | null | null | null | null | null | mujoco_playground/_src/locomotion/h1/base.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:12.763826 | # Copyright 2025 DeepMind Technologies Limited
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agre... |
google-deepmind/mujoco_playground | https://github.com/google-deepmind/mujoco_playground | null | null | null | null | 1,916 | null | null | apache-2.0 | null | null | null | null | null | null | null | mujoco_playground/_src/locomotion/h1/h1_constants.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:12.774097 | # Copyright 2025 DeepMind Technologies Limited
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agre... |
google-deepmind/mujoco_playground | https://github.com/google-deepmind/mujoco_playground | null | null | null | null | 1,916 | null | null | apache-2.0 | null | null | null | null | null | null | null | mujoco_playground/_src/locomotion/h1/inplace_gait_tracking.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:12.838524 | # Copyright 2025 DeepMind Technologies Limited
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agre... |
ZiYang-xie/WorldGen | https://github.com/ZiYang-xie/WorldGen | null | null | null | null | 1,914 | null | null | apache-2.0 | null | null | null | null | null | null | null | src/worldgen/__init__.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:15.153315 | # This file makes src/worldgen a Python package
from .worldgen import WorldGen
__all__ = ['WorldGen'] |
ZiYang-xie/WorldGen | https://github.com/ZiYang-xie/WorldGen | null | null | null | null | 1,914 | null | null | apache-2.0 | null | null | null | null | null | null | null | src/worldgen/pano_depth.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:15.153829 | import torch
import numpy as np
from PIL import Image
from da2.model.spherevit import SphereViT
from .utils.general_utils import pano_unit_rays
MAX_DISTANCE = 20.0 # Scale DA-2's scale-invariant output so max distance = 20 meters
# Default config matching DA-2's inference settings
DA2_CONFIG = {
"inference": {
... |
ZiYang-xie/WorldGen | https://github.com/ZiYang-xie/WorldGen | null | null | null | null | 1,914 | null | null | apache-2.0 | null | null | null | null | null | null | null | src/worldgen/models/inpaint_model.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:15.163220 | import os
import numpy as np
import cv2
import torch
LAMA_MODEL_URL = os.environ.get(
"LAMA_MODEL_URL",
"https://github.com/Sanster/models/releases/download/add_big_lama/big-lama.pt",
)
LAMA_MODEL_MD5 = os.environ.get("LAMA_MODEL_MD5", "e3aa4aaa15225a33ec84f9f4bc47e500")
class LaMa:
@staticmethod
def ... |
ZiYang-xie/WorldGen | https://github.com/ZiYang-xie/WorldGen | null | null | null | null | 1,914 | null | null | apache-2.0 | null | null | null | null | null | null | null | src/worldgen/pano_inpaint.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:15.164551 | from PIL import Image
import cv2
import torch
import numpy as np
from .utils.general_utils import pano_to_cube, cube_to_pano
def build_inpaint_model(device: torch.device = 'cuda'):
from worldgen.models.inpaint_model import LaMa
model = LaMa(device=device)
return model
def inpaint_image(model, image: Image... |
ZiYang-xie/WorldGen | https://github.com/ZiYang-xie/WorldGen | null | null | null | null | 1,914 | null | null | apache-2.0 | null | null | null | null | null | null | null | demo.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:15.172338 | import viser
import torch
import os
import imageio
import numpy as np
from PIL import Image
from typing import Optional, Union, Tuple
from scipy.spatial.transform import Rotation as R
from tqdm import tqdm
import time
from pathlib import Path
from worldgen.utils.splat_utils import SplatFile
from worldgen import WorldG... |
ZiYang-xie/WorldGen | https://github.com/ZiYang-xie/WorldGen | null | null | null | null | 1,914 | null | null | apache-2.0 | null | null | null | null | null | null | null | src/worldgen/pano_seg.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:15.175945 | from PIL import Image
import torch
import argparse
import numpy as np
from transformers import OneFormerProcessor, OneFormerForUniversalSegmentation
from .utils.general_utils import pano_to_cube, cube_to_pano
def build_segment_model(device: torch.device = 'cuda'):
processor = OneFormerProcessor.from_pretrained("sh... |
ZiYang-xie/WorldGen | https://github.com/ZiYang-xie/WorldGen | null | null | null | null | 1,914 | null | null | apache-2.0 | null | null | null | null | null | null | null | src/worldgen/models/flux_pano_fill_pipeline.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:15.188898 | # Copyright 2024 Black Forest Labs and The HuggingFace Team. All rights reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless... |
ZiYang-xie/WorldGen | https://github.com/ZiYang-xie/WorldGen | null | null | null | null | 1,914 | null | null | apache-2.0 | null | null | null | null | null | null | null | src/worldgen/models/flux_pano_gen_pipeline.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:15.225762 | # Adpted from LayerPano3D
# https://huggingface.co/ysmikey/Layerpano3D-FLUX-Panorama-LoRA/blob/main/pipeline_flux.py
# Copyright 2024 Black Forest Labs and The HuggingFace Team. All rights reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance wit... |
ZiYang-xie/WorldGen | https://github.com/ZiYang-xie/WorldGen | null | null | null | null | 1,914 | null | null | apache-2.0 | null | null | null | null | null | null | null | src/worldgen/pano_gen.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:15.260180 | import os
import torch
import tempfile
from pathlib import Path
from huggingface_hub import hf_hub_download
from .models.flux_pano_gen_pipeline import FluxPipeline
from .models.flux_pano_fill_pipeline import FluxFillPipeline
from nunchaku import NunchakuFluxTransformer2dModel
from nunchaku.utils import get_precision
fr... |
ZiYang-xie/WorldGen | https://github.com/ZiYang-xie/WorldGen | null | null | null | null | 1,914 | null | null | apache-2.0 | null | null | null | null | null | null | null | src/worldgen/utils/equirectangular.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:15.702102 | from __future__ import annotations
import logging
import math
from typing import NamedTuple
import numpy as np
import torch
import torch.nn.functional as F
LOGGER = logging.getLogger(__name__)
class CubemapFaces(NamedTuple):
"""Container for 6 cubemap face images."""
front: torch.Tensor # +Z direction
... |
ZiYang-xie/WorldGen | https://github.com/ZiYang-xie/WorldGen | null | null | null | null | 1,914 | null | null | apache-2.0 | null | null | null | null | null | null | null | src/worldgen/utils/lora_utils.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:15.759059 | import os
import torch
import safetensors.torch
from nunchaku.lora.flux.compose import compose_lora
import re
from typing import Dict, Tuple, List
def get_block_number(key):
"""Extract block number from key if present."""
match = re.search(r'single_transformer_blocks\.(\d+)', key)
return int(match.group(1)... |
ZiYang-xie/WorldGen | https://github.com/ZiYang-xie/WorldGen | null | null | null | null | 1,914 | null | null | apache-2.0 | null | null | null | null | null | null | null | src/worldgen/pano_sharp.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:15.771567 | import numpy as np
import math
import torch
import torch.nn.functional as F
import torch.utils.data
from pytorch3d.transforms import quaternion_to_matrix
from PIL import Image
from sharp.models import (
PredictorParams,
RGBGaussianPredictor,
create_predictor,
)
from sharp.utils import color_space as cs_uti... |
ZiYang-xie/WorldGen | https://github.com/ZiYang-xie/WorldGen | null | null | null | null | 1,914 | null | null | apache-2.0 | null | null | null | null | null | null | null | src/worldgen/worldgen.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:15.776757 | import torch
import numpy as np
import cv2
from PIL import Image
import open3d as o3d
from .pano_depth import build_depth_model, pred_pano_depth, pred_depth
from .pano_seg import build_segment_model, seg_pano_fg
from .pano_gen import build_pano_gen_model, gen_pano_image, build_pano_fill_model, gen_pano_fill_image
from... |
ZiYang-xie/WorldGen | https://github.com/ZiYang-xie/WorldGen | null | null | null | null | 1,914 | null | null | apache-2.0 | null | null | null | null | null | null | null | src/worldgen/utils/__init__.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:15.832929 | from .general_utils import (
pano_to_cube,
cube_to_pano,
resize_img,
resize_img_and_rays,
pano_unit_rays,
batch_nearest_dot,
fill_mask_from_contour,
map_image_to_pano,
depth_match
)
from .splat_utils import (
SplatFile,
convert_rgbd_to_gs,
mask_splat,
merge_splats
)
... |
ZiYang-xie/WorldGen | https://github.com/ZiYang-xie/WorldGen | null | null | null | null | 1,914 | null | null | apache-2.0 | null | null | null | null | null | null | null | src/worldgen/utils/splat_utils.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:15.864869 |
import numpy as np
import torch
from pytorch3d.transforms import matrix_to_quaternion
from plyfile import PlyData, PlyElement
class SplatFile:
def __init__(
self,
centers: np.ndarray,
rgbs: np.ndarray,
opacities: np.ndarray,
covariances: np.ndarray,
rotations: np.nd... |
ZiYang-xie/WorldGen | https://github.com/ZiYang-xie/WorldGen | null | null | null | null | 1,914 | null | null | apache-2.0 | null | null | null | null | null | null | null | src/worldgen/utils/general_utils.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:15.879030 | import py360convert
from PIL import Image
import numpy as np
import torch
import torch.nn.functional as F
from skimage import measure, draw
from typing import Optional, Literal
import open3d as o3d
def pano_to_cube(pano_img: Image.Image, face_w: int, mode: str = 'bilinear') -> list[Image.Image]:
"""Converts a pano... |
openai/privacy-filter | https://github.com/openai/privacy-filter | null | null | null | null | 1,913 | null | null | apache-2.0 | null | null | null | null | null | null | null | opf/_cli/render.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:23.131329 | from __future__ import annotations
import argparse
import sys
from types import SimpleNamespace
from typing import Mapping, Sequence, TYPE_CHECKING
from .._common.terminal_colors import style_labeled_text
if TYPE_CHECKING:
from .._api import OPF
from .._core.runtime import DetectedSpan
def render_color_cod... |
openai/privacy-filter | https://github.com/openai/privacy-filter | null | null | null | null | 1,913 | null | null | apache-2.0 | null | null | null | null | null | null | null | opf/_common/constants.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:23.141292 | """Cross-cutting internal constants shared across OPF subsystems."""
from pathlib import Path
from typing import Final
DEFAULT_MODEL_ENV_VAR: Final[str] = "OPF_CHECKPOINT"
"""Environment variable used to override the default checkpoint directory."""
DEFAULT_MODEL_PATH: Final[Path] = Path.home() / ".opf" / "privacy_... |
openai/privacy-filter | https://github.com/openai/privacy-filter | null | null | null | null | 1,913 | null | null | apache-2.0 | null | null | null | null | null | null | null | opf/__main__.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:23.144823 | import argparse
import json
import sys
import time
from typing import Sequence
from ._cli.common import CliHelpFormatter, add_checkpoint_arg, resolve_prog
from ._cli.args import (
add_common_redaction_args,
iter_inputs,
using_interactive_prompt,
)
_SUBCOMMANDS = frozenset({"redact", "eval", "train"})
_ROO... |
openai/privacy-filter | https://github.com/openai/privacy-filter | null | null | null | null | 1,913 | null | null | apache-2.0 | null | null | null | null | null | null | null | opf/_cli/args.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:23.151571 | from __future__ import annotations
import argparse
import sys
from pathlib import Path
from typing import Iterator
from .common import (
add_decode_mode_arg,
add_device_arg,
add_discard_overlapping_predicted_spans_arg,
add_n_ctx_arg,
add_output_mode_arg,
add_trim_whitespace_args,
add_viter... |
openai/privacy-filter | https://github.com/openai/privacy-filter | null | null | null | null | 1,913 | null | null | apache-2.0 | null | null | null | null | null | null | null | opf/_cli/common.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:23.152788 | import argparse
import sys
from pathlib import Path
from .._common.constants import (
DEFAULT_MODEL_ENV_VAR,
DEFAULT_MODEL_PATH,
OUTPUT_MODES,
)
CHECKPOINT_HELP = (
"Override checkpoint directory. If omitted, OPF uses "
f"{DEFAULT_MODEL_ENV_VAR} or downloads/reuses {DEFAULT_MODEL_PATH}."
)
N_CTX_H... |
openai/privacy-filter | https://github.com/openai/privacy-filter | null | null | null | null | 1,913 | null | null | apache-2.0 | null | null | null | null | null | null | null | opf/_common/checkpoint_download.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:23.154403 | from __future__ import annotations
from pathlib import Path
import shutil
import sys
from typing import Final
from .constants import DEFAULT_MODEL_ENV_VAR, DEFAULT_MODEL_PATH
DEFAULT_HF_MODEL_REPO: Final[str] = "openai/privacy-filter"
def _checkpoint_override_message() -> str:
return (
"pass --checkpo... |
openai/privacy-filter | https://github.com/openai/privacy-filter | null | null | null | null | 1,913 | null | null | apache-2.0 | null | null | null | null | null | null | null | opf/_api.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:23.155553 | from __future__ import annotations
from dataclasses import dataclass
import functools
import json
import os
from pathlib import Path
from typing import Literal, TypeVar
from ._common.checkpoint_download import ensure_default_checkpoint
from ._core.decoding import ViterbiCRFDecoder, build_sequence_decoder
from ._commo... |
openai/privacy-filter | https://github.com/openai/privacy-filter | null | null | null | null | 1,913 | null | null | apache-2.0 | null | null | null | null | null | null | null | opf/__init__.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:23.158801 | """Public OPF package."""
__all__ = ["DecodeOptions", "INHERIT", "OPF", "RedactionResult", "redact"]
def redact(text: str) -> str:
"""Redact one text string with the default local OPF model.
Args:
text: Input text to redact.
Returns:
The redacted text only.
Raises:
ValueErr... |
openai/privacy-filter | https://github.com/openai/privacy-filter | null | null | null | null | 1,913 | null | null | apache-2.0 | null | null | null | null | null | null | null | opf/_common/__init__.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:23.159305 | """Internal shared support code used across OPF subsystems.
This package contains cross-cutting constants, versioned label-space
definitions, and terminal-rendering helpers used by multiple internal modules.
It is internal API; external callers should import the supported surface from
:mod:`opf` instead.
"""
|
openai/privacy-filter | https://github.com/openai/privacy-filter | null | null | null | null | 1,913 | null | null | apache-2.0 | null | null | null | null | null | null | null | opf/_eval/__init__.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:24.756927 | """Internal eval helpers for parser wiring, dataset preprocessing, metrics, previews, and runner orchestration."""
|
openai/privacy-filter | https://github.com/openai/privacy-filter | null | null | null | null | 1,913 | null | null | apache-2.0 | null | null | null | null | null | null | null | opf/_core/decoding.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:24.758253 | """Sequence decoders and Viterbi bias-resolution helpers."""
from __future__ import annotations
import json
from pathlib import Path
from dataclasses import dataclass
from typing import Mapping, Sequence
import torch
from .sequence_labeling import LabelInfo
# Large negative score used to mask impossible CRF transi... |
openai/privacy-filter | https://github.com/openai/privacy-filter | null | null | null | null | 1,913 | null | null | apache-2.0 | null | null | null | null | null | null | null | opf/_core/__init__.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:25.103161 | """Internal OPF inference core.
This package owns runtime loading, decode configuration, sequence-labeling
structures, and token/span/character offset reconstruction shared by CLI and
eval flows.
"""
|
openai/privacy-filter | https://github.com/openai/privacy-filter | null | null | null | null | 1,913 | null | null | apache-2.0 | null | null | null | null | null | null | null | opf/_common/env.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:25.248732 | """Environment variable parsing helpers."""
from __future__ import annotations
import os
TRUE_ENV_VALUES = frozenset({"1", "true", "yes", "on"})
def get_env_bool(name: str, *, default: bool = False) -> bool:
"""Return whether one environment variable is set to a truthy value."""
raw = os.environ.get(name)
... |
openai/privacy-filter | https://github.com/openai/privacy-filter | null | null | null | null | 1,913 | null | null | apache-2.0 | null | null | null | null | null | null | null | opf/_common/terminal_colors.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:25.250049 | """ANSI terminal color helpers shared by CLI and eval renderers."""
from typing import Final, Mapping, Sequence
from .label_space import BACKGROUND_CLASS_LABEL
ANSI_RESET: Final[str] = "\x1b[0m"
"""ANSI escape sequence that resets terminal styling."""
# ANSI 256-color foreground codes used for terminal label highl... |
openai/privacy-filter | https://github.com/openai/privacy-filter | null | null | null | null | 1,913 | null | null | apache-2.0 | null | null | null | null | null | null | null | opf/_core/sequence_labeling.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:25.251189 | """Sequence-labeling data structures and window construction helpers."""
from __future__ import annotations
from dataclasses import dataclass
from typing import Iterator, Mapping, Sequence
import torch
from .._common.label_space import (
BACKGROUND_CLASS_LABEL,
BOUNDARY_PREFIXES,
)
@dataclass(frozen=True)
... |
openai/privacy-filter | https://github.com/openai/privacy-filter | null | null | null | null | 1,913 | null | null | apache-2.0 | null | null | null | null | null | null | null | opf/_core/spans.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:25.259527 | """Shared span and character-offset helpers for inference and eval."""
from bisect import bisect_left, bisect_right
from collections import defaultdict
from typing import Protocol, Sequence
import tiktoken
def _decode_text_and_token_char_ranges(
token_ids: Sequence[int], encoding: tiktoken.Encoding
) -> tuple[s... |
openai/privacy-filter | https://github.com/openai/privacy-filter | null | null | null | null | 1,913 | null | null | apache-2.0 | null | null | null | null | null | null | null | opf/_eval/args.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:25.280501 | import argparse
from .._cli.common import (
CliHelpFormatter,
add_checkpoint_arg,
add_decode_mode_arg,
add_device_arg,
add_discard_overlapping_predicted_spans_arg,
add_n_ctx_arg,
add_trim_whitespace_args,
add_viterbi_args,
resolve_prog,
)
def build_parser(*, prog: str | None = Non... |
openai/privacy-filter | https://github.com/openai/privacy-filter | null | null | null | null | 1,913 | null | null | apache-2.0 | null | null | null | null | null | null | null | opf/_common/label_space.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:25.364650 | """Versioned internal label-space definitions used across OPF subsystems."""
import json
from pathlib import Path
from typing import Final, Mapping, Sequence
BACKGROUND_CLASS_LABEL: Final[str] = "O"
"""Background token label used for non-entity positions."""
BOUNDARY_PREFIXES: Final[tuple[str, ...]] = ("B", "I", "E"... |
openai/privacy-filter | https://github.com/openai/privacy-filter | null | null | null | null | 1,913 | null | null | apache-2.0 | null | null | null | null | null | null | null | opf/_core/runtime.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:25.385738 | """Core runtime loading and one-shot text prediction helpers."""
from __future__ import annotations
import json
import math
import os
import re
from dataclasses import dataclass
from pathlib import Path
from typing import Sequence
import torch
import torch.nn.functional as F
import tiktoken
from .._common.constants... |
openai/privacy-filter | https://github.com/openai/privacy-filter | null | null | null | null | 1,913 | null | null | apache-2.0 | null | null | null | null | null | null | null | opf/_eval/preprocess.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:25.823306 | from __future__ import annotations
from bisect import bisect_right
from collections import defaultdict
from dataclasses import dataclass
import hashlib
import json
from typing import Mapping, Sequence
import torch
import tiktoken
from .._core.sequence_labeling import LabelInfo, TokenizedExample
from .._core.spans im... |
openai/privacy-filter | https://github.com/openai/privacy-filter | null | null | null | null | 1,913 | null | null | apache-2.0 | null | null | null | null | null | null | null | opf/_eval/metrics.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:25.824530 | import os
import json
import math
import time
from concurrent.futures import ThreadPoolExecutor
from collections import OrderedDict, defaultdict
from dataclasses import dataclass
from pathlib import Path
from typing import Any, Callable, Mapping, Sequence
import torch
import tiktoken
from .._common.env import get_env... |
openai/privacy-filter | https://github.com/openai/privacy-filter | null | null | null | null | 1,913 | null | null | apache-2.0 | null | null | null | null | null | null | null | opf/_eval/data.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:26.066229 | import glob
import gzip
import io
import json
import os
import re
from typing import Iterable, Iterator, Mapping, Sequence
MESSAGE_PREFIX_RE = re.compile(r"(?:^|\n\n)(user|assistant): ")
def _split_message_spans(text: str) -> list[tuple[int, int]]:
"""Split a chat transcript into message-body character spans.""... |
openai/privacy-filter | https://github.com/openai/privacy-filter | null | null | null | null | 1,913 | null | null | apache-2.0 | null | null | null | null | null | null | null | opf/_train/args.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:26.426676 | from __future__ import annotations
import argparse
from .._cli.common import (
CliHelpFormatter,
add_checkpoint_arg,
add_device_arg,
add_n_ctx_arg,
resolve_prog,
)
def build_parser(*, prog: str | None = None) -> argparse.ArgumentParser:
"""Build the ``opf train`` argument parser."""
epil... |
openai/privacy-filter | https://github.com/openai/privacy-filter | null | null | null | null | 1,913 | null | null | apache-2.0 | null | null | null | null | null | null | null | opf/_train/runner.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:26.427337 | from __future__ import annotations
import json
import math
import os
import random
import time
from dataclasses import dataclass
from pathlib import Path
from typing import Iterable, Mapping, Sequence
import torch
import torch.nn.functional as F
import tiktoken
from .args import parse_args
from .._api import resolve... |
openai/privacy-filter | https://github.com/openai/privacy-filter | null | null | null | null | 1,913 | null | null | apache-2.0 | null | null | null | null | null | null | null | opf/_eval/runner.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:26.883658 | from __future__ import annotations
import argparse
import functools
import json
import os
import sys
import time
from collections import defaultdict
from concurrent.futures import ProcessPoolExecutor
from pathlib import Path
from typing import Iterable, Iterator, Mapping, Sequence, TextIO
from .args import parse_args... |
openai/privacy-filter | https://github.com/openai/privacy-filter | null | null | null | null | 1,913 | null | null | apache-2.0 | null | null | null | null | null | null | null | opf/_eval/render.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:26.933601 | import codecs
from typing import Sequence
import tiktoken
from .._common.label_space import BACKGROUND_CLASS_LABEL
from .._common.terminal_colors import build_label_color_map, style_labeled_text
def build_prediction_preview(
*,
example_id: str,
text: str,
token_ids: Sequence[int],
predicted_spans... |
openai/privacy-filter | https://github.com/openai/privacy-filter | null | null | null | null | 1,913 | null | null | apache-2.0 | null | null | null | null | null | null | null | opf/_model/__init__.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:26.990219 | """Internal transformer, attention, weight-loading, and MoE helpers."""
from .model import Transformer
__all__ = ["Transformer"]
|
openai/privacy-filter | https://github.com/openai/privacy-filter | null | null | null | null | 1,913 | null | null | apache-2.0 | null | null | null | null | null | null | null | opf/_model/triton_moe.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:26.990710 | """Triton kernels for grouped MoE matmuls and fused SwiGLU projection."""
from __future__ import annotations
import torch
import triton
import triton.language as tl
@triton.jit
def _grouped_matmul_kernel(
a_ptr,
w_ptr,
c_ptr,
offsets_ptr,
lengths_ptr,
E,
K,
N,
stride_am,
stri... |
openai/privacy-filter | https://github.com/openai/privacy-filter | null | null | null | null | 1,913 | null | null | apache-2.0 | null | null | null | null | null | null | null | opf/_model/model.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:27.176248 | """Transformer architecture and checkpoint contract logic for OPF models."""
import dataclasses
import json
import math
import os
from dataclasses import dataclass
import torch
import torch.nn.functional as F
import torch.distributed as dist
from .._common.env import get_env_bool
from .weights import Checkpoint
try... |
openai/privacy-filter | https://github.com/openai/privacy-filter | null | null | null | null | 1,913 | null | null | apache-2.0 | null | null | null | null | null | null | null | opf/_model/weights.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:31.248032 | """Checkpoint loading helpers for OPF model weights."""
import math
import os
from pathlib import Path
from typing import Mapping
import torch
from safetensors import safe_open
from safetensors.torch import save_file
FP4_VALUES = [
+0.0,
+0.5,
+1.0,
+1.5,
+2.0,
+3.0,
+4.0,
+6.0,
-... |
Yuanshi9815/OminiControl | https://github.com/Yuanshi9815/OminiControl | null | null | null | null | 1,912 | null | null | apache-2.0 | null | null | null | null | null | null | null | omini/train_flux/train_spatial_alignment.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:33.556612 | import torch
from torch.utils.data import Dataset
import torchvision.transforms as T
import os
import random
import numpy as np
from PIL import Image, ImageDraw
from datasets import load_dataset
from .trainer import OminiModel, get_config, train
from ..pipeline.flux_omini import Condition, convert_to_condition, gene... |
Yuanshi9815/OminiControl | https://github.com/Yuanshi9815/OminiControl | null | null | null | null | 1,912 | null | null | apache-2.0 | null | null | null | null | null | null | null | omini/train_flux/train_multi_condition.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:33.559757 | import torch
import os
import random
from PIL import Image, ImageDraw
from datasets import load_dataset
from .trainer import OminiModel, get_config, train
from ..pipeline.flux_omini import Condition, convert_to_condition, generate
from .train_spatial_alignment import ImageConditionDataset
class ImageMultiCondition... |
Yuanshi9815/OminiControl | https://github.com/Yuanshi9815/OminiControl | null | null | null | null | 1,912 | null | null | apache-2.0 | null | null | null | null | null | null | null | omini/train_flux/train_token_integration.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:33.564676 | import torch
import os
import random
from PIL import Image, ImageDraw
from datasets import load_dataset
from .trainer import OminiModel, get_config, train
from ..pipeline.flux_omini import Condition, generate
from .train_spatial_alignment import ImageConditionDataset
class TokenIntergrationDataset(ImageConditionDa... |
Yuanshi9815/OminiControl | https://github.com/Yuanshi9815/OminiControl | null | null | null | null | 1,912 | null | null | apache-2.0 | null | null | null | null | null | null | null | omini/pipeline/flux_omini.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:33.565476 | import torch
from typing import List, Union, Optional, Dict, Any, Callable, Type, Tuple
from diffusers.pipelines import FluxPipeline
from diffusers.pipelines.flux.pipeline_flux import (
FluxPipelineOutput,
FluxTransformer2DModel,
calculate_shift,
retrieve_timesteps,
np,
)
from diffusers.models.atte... |
Yuanshi9815/OminiControl | https://github.com/Yuanshi9815/OminiControl | null | null | null | null | 1,912 | null | null | apache-2.0 | null | null | null | null | null | null | null | omini/train_flux/train_subject.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:33.567464 | import torch
from torch.utils.data import Dataset
import torchvision.transforms as T
import os
import random
import numpy as np
from PIL import Image
from datasets import load_dataset
from .trainer import OminiModel, get_config, train
from ..pipeline.flux_omini import Condition, generate
class Subject200KDataset(D... |
Yuanshi9815/OminiControl | https://github.com/Yuanshi9815/OminiControl | null | null | null | null | 1,912 | null | null | apache-2.0 | null | null | null | null | null | null | null | omini/train_flux/train_custom.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:33.568339 | import torch
import os
import random
from torch.utils.data import DataLoader, Dataset
from PIL import Image
from datasets import load_dataset
from .trainer import OminiModel, get_config, train
from ..pipeline.flux_omini import Condition, generate
class CustomDataset(Dataset):
def __getitem__(self, idx):
... |
Yuanshi9815/OminiControl | https://github.com/Yuanshi9815/OminiControl | null | null | null | null | 1,912 | null | null | apache-2.0 | null | null | null | null | null | null | null | omini/train_flux/trainer.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:33.598667 | import lightning as L
from diffusers.pipelines import FluxPipeline
import torch
import wandb
import os
import yaml
from peft import LoraConfig, get_peft_model_state_dict
from torch.utils.data import DataLoader
import time
from typing import List
import prodigyopt
from ..pipeline.flux_omini import transformer_forward... |
mistio/mist-ce | https://github.com/mistio/mist-ce | null | null | null | null | 1,910 | null | null | apache-2.0 | null | null | null | null | null | null | null | docker/elasticsearch-manage/scripts/add_templates.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:43.539203 | #!/usr/bin/env python
import os
import sys
import time
import json
import argparse
import traceback
import certifi
from elasticsearch import Elasticsearch
EXCLUDED = ('heapster', 'audit', ) # Templates to be excluded.
def es_client():
es = Elasticsearch(
os.getenv('ELASTIC_HOST', 'elasticsearch'),
... |
mistio/mist-ce | https://github.com/mistio/mist-ce | null | null | null | null | 1,910 | null | null | apache-2.0 | null | null | null | null | null | null | null | ci/release.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:43.539747 | #!/usr/bin/env python
import os
import sys
import hashlib
import argparse
import magic
import requests
def main():
args = parse_args()
request = Client(args.owner, args.repo, args.token)
update_release(
request, args.tag, msg=args.msg, files=args.files,
prerelease=args.prerelease, draft=... |
mistio/mist-ce | https://github.com/mistio/mist-ce | null | null | null | null | 1,910 | null | null | apache-2.0 | null | null | null | null | null | null | null | docker/elasticsearch-manage/scripts/delete_indices.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:43.765088 | #!/usr/bin/env python
import os
import sys
import traceback
import certifi
from elasticsearch import Elasticsearch
def es_client():
return Elasticsearch(
os.getenv('ELASTIC_HOST', 'elasticsearch'),
port=os.getenv('ELASTIC_PORT', '9200'),
http_auth=(os.getenv('ELASTIC_USER', ''),
... |
S-LoRA/S-LoRA | https://github.com/S-LoRA/S-LoRA | null | null | null | null | 1,909 | null | null | apache-2.0 | null | null | null | null | null | null | null | benchmarks/run_exp.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:47.193731 | """
To run with real mode:
python run_exp.py --backend slora --suite a10g --breakdown --mode real
with synthetic mode:
python run_exp.py --backend slora --suite a10g --breakdown --mode synthetic
default to synthetic mode.
"""
import argparse
import asyncio
import csv
import json
import numpy as np
import os
import sy... |
S-LoRA/S-LoRA | https://github.com/S-LoRA/S-LoRA | null | null | null | null | 1,909 | null | null | apache-2.0 | null | null | null | null | null | null | null | benchmarks/trace.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:47.196702 | from collections import Counter
import json
import logging
from itertools import groupby
import numpy as np
from typing import List, Tuple, Any
from tqdm import tqdm
import random
from transformers import AutoTokenizer
class Request:
def __init__(self, req_id, model_dir, adapter_dir, prompt, prompt_len, output_len... |
S-LoRA/S-LoRA | https://github.com/S-LoRA/S-LoRA | null | null | null | null | 1,909 | null | null | apache-2.0 | null | null | null | null | null | null | null | benchmarks/run_exp_peft.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:47.197950 | """
To run with real mode:
python run_exp_peft.py --backend slora --suite a10g --breakdown --mode real
with synthetic mode:
python run_exp_peft.py --backend slora --suite a10g --breakdown --mode synthetic
default to synthetic mode.
"""
import argparse
import asyncio
import csv
import json
import numpy as np
import os... |
S-LoRA/S-LoRA | https://github.com/S-LoRA/S-LoRA | null | null | null | null | 1,909 | null | null | apache-2.0 | null | null | null | null | null | null | null | benchmarks/paper/ablation_mem/run_no_mem_ablation.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:47.199642 | import argparse
import os
import signal
import subprocess
import time
from exp_suite import BASE_MODEL, LORA_DIR
NUM_ADAPTER = {
"a10g": {
"S1": 200,
"S2": 200,
"S3": 200,
"S4": 200,
}
}
MEM_SIZE = {
"a10g": {
"S1": 15000,
"S2": 15000,
"S3": 10000,... |
S-LoRA/S-LoRA | https://github.com/S-LoRA/S-LoRA | null | null | null | null | 1,909 | null | null | apache-2.0 | null | null | null | null | null | null | null | benchmarks/real_trace/clean_chat_data.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:47.203425 | """
Clean chatbot arena chat log.
Usage:
python3 clean_chat_data.py
"""
import argparse
import datetime
import json
import os
from pytz import timezone
import time
from tqdm import tqdm
from fastchat.serve.monitor.basic_stats import NUM_SERVERS
from fastchat.serve.monitor.clean_battle_data import (
to_openai_fo... |
S-LoRA/S-LoRA | https://github.com/S-LoRA/S-LoRA | null | null | null | null | 1,909 | null | null | apache-2.0 | null | null | null | null | null | null | null | setup.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:47.204808 | import pathlib
from setuptools import setup, find_packages
import torch.utils.cpp_extension as torch_cpp_ext
root = pathlib.Path(__name__).parent
print(root)
def glob(pattern):
return [str(p) for p in root.glob(pattern)]
def remove_unwanted_pytorch_nvcc_flags():
REMOVE_NVCC_FLAGS = [
'-D__CUDA_NO_HALF_OPE... |
S-LoRA/S-LoRA | https://github.com/S-LoRA/S-LoRA | null | null | null | null | 1,909 | null | null | apache-2.0 | null | null | null | null | null | null | null | benchmarks/exp_suite.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:47.206937 | from collections import namedtuple
import itertools
BASE_MODEL = {
"S1": "huggyllama/llama-7b",
"S2": "huggyllama/llama-7b",
"S3": "huggyllama/llama-13b",
"S4": "huggyllama/llama-13b",
"Real": "huggyllama/llama-7b",
}
LORA_DIR = {
"S1": ["dummy-lora-7b-rank-8"],
... |
S-LoRA/S-LoRA | https://github.com/S-LoRA/S-LoRA | null | null | null | null | 1,909 | null | null | apache-2.0 | null | null | null | null | null | null | null | benchmarks/time_stats.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:47.214369 | import re
if __name__ == "__main__":
with open("log", "r") as f:
lines = f.readlines()
load = 0
prefetch = 0
offload = 0
prefill = 0
decode = 0
filter = 0
filter_free_mem = 0
load_scan = 0
offload_free_mem = 0
offload_torch_empty = 0
offload_scan = 0
offloa... |
S-LoRA/S-LoRA | https://github.com/S-LoRA/S-LoRA | null | null | null | null | 1,909 | null | null | apache-2.0 | null | null | null | null | null | null | null | benchmarks/real_trace/parse_into_trace.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:47.220088 | import argparse
import random
import json
from tqdm import tqdm
from transformers import AutoTokenizer
model_mapping = {}
# copy from trace.py; (TODO) refactor
class Request:
def __init__(self, req_id, model_dir, adapter_dir, prompt, prompt_len, output_len, req_time):
self.req_id = req_id
self.mod... |
S-LoRA/S-LoRA | https://github.com/S-LoRA/S-LoRA | null | null | null | null | 1,909 | null | null | apache-2.0 | null | null | null | null | null | null | null | benchmarks/launch_server.py | null | null | null | null | null | null | Python | 2026-05-04T02:48:47.245730 | import argparse
import os
import psutil
import sys
from exp_suite import BASE_MODEL, LORA_DIR
if __name__ == "__main__":
parser = argparse.ArgumentParser()
parser.add_argument("--device", type=str, default="debug")
parser.add_argument("--backend", type=str, default="slora",
choice... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.