import os
import os.path as osp
import bisect
import argparse
import multiprocessing as mp
import numpy as np
from tqdm import tqdm
import megengine as mge
from megengine import distributed as dist
from megengine import optimizer as optim
import megengine.autodiff as autodiff
from megengine import jit
import dataset, network
from config import config as cfg
from misc_utils import ensure_dir
import socket
import pdb

ensure_dir(cfg.output_dir)
logger = 
mge.get_logger(__name__)