lint: correct annotations for Python 3.9.

This commit is contained in:
Kevin Turner 2022-11-25 13:52:29 -08:00
parent 716ca8f8b9
commit 56153c2ebf
3 changed files with 9 additions and 0 deletions

View File

@ -2,6 +2,8 @@
Base class for ldm.invoke.generator.*
including img2img, txt2img, and inpaint
'''
from __future__ import annotations
import os
import os.path as osp
import random

View File

@ -1,3 +1,5 @@
from __future__ import annotations
import secrets
import warnings
from dataclasses import dataclass

View File

@ -4,15 +4,20 @@ They are moved between GPU and CPU as necessary. If CPU memory falls
below a preset minimum, the least recently used model will be
cleared and loaded from disk when next needed.
'''
from __future__ import annotations
import contextlib
import gc
import hashlib
import io
import os
import sys
import textwrap
import time
import traceback
import warnings
from pathlib import Path
from typing import Union
import torch
import transformers