applied isort and removed unused imports

This commit is contained in:
jinzr 2023-07-06 15:16:32 +08:00
parent d377d7bc65
commit 3a85f49c1a
5 changed files with 5 additions and 10 deletions

View File

@ -50,7 +50,6 @@ import argparse
import logging import logging
from pathlib import Path from pathlib import Path
from typing import Dict, Tuple from typing import Dict, Tuple
import re
import k2 import k2
import onnx import onnx
@ -68,7 +67,7 @@ from icefall.checkpoint import (
find_checkpoints, find_checkpoints,
load_checkpoint, load_checkpoint,
) )
from icefall.utils import setup_logger, str2bool, num_tokens from icefall.utils import num_tokens, setup_logger, str2bool
def get_parser(): def get_parser():

View File

@ -86,7 +86,6 @@ with the following commands:
import argparse import argparse
import logging import logging
from pathlib import Path from pathlib import Path
import re
import k2 import k2
import torch import torch
@ -100,7 +99,7 @@ from icefall.checkpoint import (
find_checkpoints, find_checkpoints,
load_checkpoint, load_checkpoint,
) )
from icefall.utils import str2bool, num_tokens from icefall.utils import num_tokens, str2bool
def get_parser(): def get_parser():

View File

@ -74,7 +74,6 @@ import onnx
import torch import torch
import torch.nn as nn import torch.nn as nn
from decoder import Decoder from decoder import Decoder
from export import num_tokens
from onnxruntime.quantization import QuantType, quantize_dynamic from onnxruntime.quantization import QuantType, quantize_dynamic
from scaling_converter import convert_scaled_to_non_scaled from scaling_converter import convert_scaled_to_non_scaled
from train import add_model_arguments, get_model, get_params from train import add_model_arguments, get_model, get_params
@ -86,7 +85,7 @@ from icefall.checkpoint import (
find_checkpoints, find_checkpoints,
load_checkpoint, load_checkpoint,
) )
from icefall.utils import str2bool from icefall.utils import num_tokens, str2bool
def get_parser(): def get_parser():

View File

@ -71,7 +71,6 @@ import onnx
import torch import torch
import torch.nn as nn import torch.nn as nn
from decoder import Decoder from decoder import Decoder
from export import num_tokens
from onnxruntime.quantization import QuantType, quantize_dynamic from onnxruntime.quantization import QuantType, quantize_dynamic
from scaling_converter import convert_scaled_to_non_scaled from scaling_converter import convert_scaled_to_non_scaled
from train import add_model_arguments, get_model, get_params from train import add_model_arguments, get_model, get_params
@ -83,7 +82,7 @@ from icefall.checkpoint import (
find_checkpoints, find_checkpoints,
load_checkpoint, load_checkpoint,
) )
from icefall.utils import make_pad_mask, str2bool from icefall.utils import make_pad_mask, num_tokens, str2bool
def get_parser(): def get_parser():

View File

@ -160,7 +160,6 @@ with the following commands:
import argparse import argparse
import logging import logging
import re
from pathlib import Path from pathlib import Path
from typing import List, Tuple from typing import List, Tuple
@ -176,7 +175,7 @@ from icefall.checkpoint import (
find_checkpoints, find_checkpoints,
load_checkpoint, load_checkpoint,
) )
from icefall.utils import make_pad_mask, str2bool, num_tokens from icefall.utils import make_pad_mask, num_tokens, str2bool
def get_parser(): def get_parser():