mirror of
https://github.com/deepseek-ai/DreamCraft3D
synced 2024-12-04 18:15:11 +00:00
37 lines
574 B
Python
37 lines
574 B
Python
|
__modules__ = {}
|
||
|
|
||
|
|
||
|
def register(name):
|
||
|
def decorator(cls):
|
||
|
__modules__[name] = cls
|
||
|
return cls
|
||
|
|
||
|
return decorator
|
||
|
|
||
|
|
||
|
def find(name):
|
||
|
return __modules__[name]
|
||
|
|
||
|
|
||
|
### grammar sugar for logging utilities ###
|
||
|
import logging
|
||
|
|
||
|
logger = logging.getLogger("pytorch_lightning")
|
||
|
|
||
|
from pytorch_lightning.utilities.rank_zero import (
|
||
|
rank_zero_debug,
|
||
|
rank_zero_info,
|
||
|
rank_zero_only,
|
||
|
)
|
||
|
|
||
|
debug = rank_zero_debug
|
||
|
info = rank_zero_info
|
||
|
|
||
|
|
||
|
@rank_zero_only
|
||
|
def warn(*args, **kwargs):
|
||
|
logger.warn(*args, **kwargs)
|
||
|
|
||
|
|
||
|
from . import data, models, systems
|