Add missing Pyre mode headers] [batch:11/N] [shard:17/N]

Differential Revision: D90237984

fbshipit-source-id: 526fd760f303bf31be4f743bdcd77760496de0de
This commit is contained in:
generatedunixname89002005307016
2026-01-07 05:16:41 -08:00
committed by meta-codesync[bot]
parent 5eb25fb54b
commit 7b89b8fc3f
155 changed files with 310 additions and 0 deletions

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
from .model_builder import build_sam3_image_model from .model_builder import build_sam3_image_model
__version__ = "0.1.0" __version__ = "0.1.0"

View File

@@ -1 +1,3 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
import copy import copy
import json import json
import os import os

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
import base64 import base64
import os import os
from typing import Any, Optional from typing import Any, Optional

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
import json import json
import os import os

View File

@@ -1 +1,3 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
import math import math
from enum import IntEnum, unique from enum import IntEnum, unique
from typing import List, Tuple, Union from typing import List, Tuple, Union

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
""" """
An awesome colormap for really neat visualizations. An awesome colormap for really neat visualizations.
Copied from Detectron, and removed gray colors. Copied from Detectron, and removed gray colors.

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
from typing import Any, List, Tuple, Union from typing import Any, List, Tuple, Union
import numpy as np import numpy as np

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
from typing import Dict, List from typing import Dict, List
import numpy as np import numpy as np

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
import copy import copy
import itertools import itertools
from typing import Any, Iterator, List, Union from typing import Any, Iterator, List, Union

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
import logging import logging
from contextlib import contextmanager from contextlib import contextmanager
from functools import wraps from functools import wraps

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
"""Some utilities for RLE encoding that doesn't require downloading the masks to the cpu""" """Some utilities for RLE encoding that doesn't require downloading the masks to the cpu"""
import numpy as np import numpy as np

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
from torch import nn from torch import nn
from torchvision.ops import roi_align from torchvision.ops import roi_align

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
from __future__ import absolute_import, division, print_function, unicode_literals from __future__ import absolute_import, division, print_function, unicode_literals
import math import math

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
import colorsys import colorsys
from dataclasses import dataclass from dataclasses import dataclass
from typing import List, Tuple from typing import List, Tuple

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
import colorsys import colorsys
import logging import logging
import math import math

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
import io import io
import math import math

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
import json import json
import os import os

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
import cv2 import cv2
import numpy as np import numpy as np
import pycocotools.mask as mask_utils import pycocotools.mask as mask_utils

View File

@@ -1 +1,3 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
import contextlib import contextlib
import copy import copy
import json import json

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
""" """
COCO evaluator that works in distributed mode. COCO evaluator that works in distributed mode.

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
""" """
This evaluator is meant for regular COCO mAP evaluation, for example on the COCO val set. This evaluator is meant for regular COCO mAP evaluation, for example on the COCO val set.

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
""" """
Self-contained COCO JSON re-indexing function that creates temporary files. Self-contained COCO JSON re-indexing function that creates temporary files.
""" """

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
""" """
COCO prediction dumper for distributed training. COCO prediction dumper for distributed training.

View File

@@ -1,4 +1,6 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
import json import json
import os import os
from collections import defaultdict from collections import defaultdict

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
""" """
This evaluator is based upon COCO evaluation, but evaluates the model in a "demo" setting. This evaluator is based upon COCO evaluation, but evaluates the model in a "demo" setting.
This means that the model's predictions are thresholded and evaluated as "hard" predictions. This means that the model's predictions are thresholded and evaluated as "hard" predictions.

View File

@@ -1 +1,3 @@
# flake8: noqa # flake8: noqa
# pyre-unsafe

View File

@@ -1,5 +1,7 @@
# flake8: noqa # flake8: noqa
# pyre-unsafe
"""run_youtube_vis.py """run_youtube_vis.py
Run example: Run example:
run_youtube_vis.py --USE_PARALLEL False --METRICS HOTA --TRACKERS_TO_EVAL STEm_Seg run_youtube_vis.py --USE_PARALLEL False --METRICS HOTA --TRACKERS_TO_EVAL STEm_Seg

View File

@@ -1,4 +1,6 @@
# flake8: noqa # flake8: noqa
# pyre-unsafe
from . import datasets, metrics, utils from . import datasets, metrics, utils
from .eval import Evaluator from .eval import Evaluator

View File

@@ -1,5 +1,7 @@
# flake8: noqa # flake8: noqa
# pyre-unsafe
import inspect import inspect
from functools import wraps from functools import wraps
from time import perf_counter from time import perf_counter

View File

@@ -1,4 +1,6 @@
# flake8: noqa # flake8: noqa
# pyre-unsafe
from .tao_ow import TAO_OW from .tao_ow import TAO_OW
from .youtube_vis import YouTubeVIS from .youtube_vis import YouTubeVIS

View File

@@ -1,5 +1,7 @@
# flake8: noqa # flake8: noqa
# pyre-unsafe
import csv import csv
import io import io
import os import os

View File

@@ -1,5 +1,7 @@
# flake8: noqa # flake8: noqa
# pyre-unsafe
import itertools import itertools
import json import json
import os import os

View File

@@ -1,5 +1,7 @@
# flake8: noqa # flake8: noqa
# pyre-unsafe
# note: this file has been modified from its original version in TrackEval in # note: this file has been modified from its original version in TrackEval in
# https://github.com/JonathonLuiten/TrackEval/blob/master/trackeval/datasets/youtube_vis.py # https://github.com/JonathonLuiten/TrackEval/blob/master/trackeval/datasets/youtube_vis.py
# to support the following: # to support the following:

View File

@@ -1,5 +1,7 @@
# flake8: noqa # flake8: noqa
# pyre-unsafe
import os import os
import time import time
import traceback import traceback

View File

@@ -1,4 +1,6 @@
# flake8: noqa # flake8: noqa
# pyre-unsafe
from .count import Count from .count import Count
from .hota import HOTA from .hota import HOTA

View File

@@ -1,5 +1,7 @@
# flake8: noqa # flake8: noqa
# pyre-unsafe
from abc import ABC, abstractmethod from abc import ABC, abstractmethod
import numpy as np import numpy as np

View File

@@ -1,5 +1,7 @@
# flake8: noqa # flake8: noqa
# pyre-unsafe
from .. import _timing from .. import _timing
from ._base_metric import _BaseMetric from ._base_metric import _BaseMetric

View File

@@ -1,5 +1,7 @@
# flake8: noqa # flake8: noqa
# pyre-unsafe
import os import os
import numpy as np import numpy as np

View File

@@ -1,5 +1,7 @@
# flake8: noqa # flake8: noqa
# pyre-unsafe
import argparse import argparse
import csv import csv
import os import os

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
"""Postprocessors class to transform MDETR output according to the downstream task""" """Postprocessors class to transform MDETR output according to the downstream task"""
import dataclasses import dataclasses

View File

@@ -1,4 +1,6 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
import argparse import argparse
import json import json
import os import os

View File

@@ -1,4 +1,6 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
import json import json
import os import os
import tempfile import tempfile

View File

@@ -1,5 +1,7 @@
# fmt: off # fmt: off
# flake8: noqa # flake8: noqa
# pyre-unsafe
from . import config, datasets, metrics, utils from . import config, datasets, metrics, utils
from .eval import Evaluator from .eval import Evaluator

View File

@@ -1,6 +1,8 @@
# fmt: off # fmt: off
# flake8: noqa # flake8: noqa
# pyre-unsafe
import inspect import inspect
from functools import wraps from functools import wraps
from time import perf_counter from time import perf_counter

View File

@@ -1,6 +1,8 @@
# fmt: off # fmt: off
# flake8: noqa # flake8: noqa
# pyre-unsafe
"""Config.""" """Config."""
import argparse import argparse
import os import os

View File

@@ -1,5 +1,7 @@
# fmt: off # fmt: off
# flake8: noqa # flake8: noqa
# pyre-unsafe
"""Datasets.""" """Datasets."""
from .coco import COCO from .coco import COCO
from .tao import TAO from .tao import TAO

View File

@@ -1,6 +1,8 @@
# fmt: off # fmt: off
# flake8: noqa # flake8: noqa
# pyre-unsafe
import csv import csv
import io import io
import os import os

View File

@@ -1,6 +1,8 @@
# fmt: off # fmt: off
# flake8: noqa # flake8: noqa
# pyre-unsafe
"""COCO Dataset.""" """COCO Dataset."""
import copy import copy
import itertools import itertools

View File

@@ -1,6 +1,8 @@
# fmt: off # fmt: off
# flake8: noqa # flake8: noqa
# pyre-unsafe
"""TAO Dataset.""" """TAO Dataset."""
import copy import copy
import itertools import itertools

View File

@@ -1,6 +1,8 @@
# fmt: off # fmt: off
# flake8: noqa # flake8: noqa
# pyre-unsafe
import copy import copy
import os import os
import pickle import pickle

View File

@@ -1,4 +1,6 @@
# fmt: off # fmt: off
# flake8: noqa # flake8: noqa
# pyre-unsafe
from .teta import TETA from .teta import TETA

View File

@@ -1,6 +1,8 @@
# fmt: off # fmt: off
# flake8: noqa # flake8: noqa
# pyre-unsafe
from abc import ABC, abstractmethod from abc import ABC, abstractmethod
import numpy as np import numpy as np

View File

@@ -1,6 +1,8 @@
# fmt: off # fmt: off
# flake8: noqa # flake8: noqa
# pyre-unsafe
"""Track Every Thing Accuracy metric.""" """Track Every Thing Accuracy metric."""
import numpy as np import numpy as np

View File

@@ -1,6 +1,8 @@
# fmt: off # fmt: off
# flake8: noqa # flake8: noqa
# pyre-unsafe
import csv import csv
import os import os
from collections import OrderedDict from collections import OrderedDict

View File

@@ -1,6 +1,8 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary. # (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
# pyre-unsafe
import copy import copy
import json import json
import logging import logging

View File

@@ -1,4 +1,6 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
import copy import copy
import gc import gc
import logging import logging

View File

@@ -1,4 +1,6 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
import logging import logging
import os import os

View File

@@ -1 +1,3 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
import inspect import inspect
from functools import wraps from functools import wraps
from typing import Callable, TypeVar, Union from typing import Callable, TypeVar, Union

View File

@@ -1,4 +1,6 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
""" """
Utilities for bounding box manipulation and GIoU. Utilities for bounding box manipulation and GIoU.
""" """

View File

@@ -1,4 +1,6 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
""" """
Misc functions, including distributed helpers. Misc functions, including distributed helpers.
""" """

View File

@@ -1,4 +1,6 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
""" """
Transformer decoder. Transformer decoder.
Inspired from Pytorch's version, adds the pre-norm variant Inspired from Pytorch's version, adds the pre-norm variant

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
"""Triton kernel for euclidean distance transform (EDT)""" """Triton kernel for euclidean distance transform (EDT)"""
import torch import torch

View File

@@ -1,6 +1,8 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# Based on https://github.com/IDEA-Research/GroundingDINO # Based on https://github.com/IDEA-Research/GroundingDINO
# pyre-unsafe
from typing import Any, Dict, List, Optional, Tuple from typing import Any, Dict, List, Optional, Tuple
import torch import torch

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
from typing import Tuple from typing import Tuple
import torch import torch

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
import contextlib import contextlib
import os import os
import queue import queue

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
import math import math
from typing import Dict, List, Optional from typing import Dict, List, Optional

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
import math import math
from typing import Tuple from typing import Tuple

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
"""Various utility models""" """Various utility models"""
import copy import copy

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
"""Necks are the interface between a vision backbone and the rest of the detection model""" """Necks are the interface between a vision backbone and the rest of the detection model"""
from copy import deepcopy from copy import deepcopy

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
import math import math
from typing import Optional from typing import Optional

View File

@@ -1,6 +1,8 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# All rights reserved. # All rights reserved.
# pyre-unsafe
# This source code is licensed under the license found in the # This source code is licensed under the license found in the
# LICENSE file in the root directory of this source tree. # LICENSE file in the root directory of this source tree.

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
import os import os
from copy import deepcopy from copy import deepcopy
from typing import Dict, List, Optional, Tuple from typing import Dict, List, Optional, Tuple

View File

@@ -1,4 +1,6 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
from typing import Dict, List from typing import Dict, List
import numpy as np import numpy as np

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
import logging import logging
import torch import torch

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
import numpy as np import numpy as np
import torch import torch
import torch.nn.functional as F import torch.nn.functional as F

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
import logging import logging
from collections import OrderedDict from collections import OrderedDict

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
import datetime import datetime
import logging import logging
import math import math

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
import logging import logging
from collections import defaultdict from collections import defaultdict

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
import datetime import datetime
import gc import gc
import multiprocessing as mp import multiprocessing as mp

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
from collections import OrderedDict from collections import OrderedDict
from typing import Callable, List, Optional, Tuple, Union from typing import Callable, List, Optional, Tuple, Union

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
""" """
Text Tokenizer. Text Tokenizer.

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# All rights reserved. # All rights reserved.
# pyre-unsafe
# This source code is licensed under the license found in the # This source code is licensed under the license found in the
# LICENSE file in the root directory of this source tree. # LICENSE file in the root directory of this source tree.

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
from collections import defaultdict from collections import defaultdict
from dataclasses import fields, is_dataclass from dataclasses import fields, is_dataclass
from typing import Any, Mapping, Protocol, runtime_checkable from typing import Any, Mapping, Protocol, runtime_checkable

View File

@@ -1,6 +1,8 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# All rights reserved. # All rights reserved.
# pyre-unsafe
# This source code is licensed under the license found in the # This source code is licensed under the license found in the
# LICENSE file in the root directory of this source tree. # LICENSE file in the root directory of this source tree.

View File

@@ -1,6 +1,8 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# All rights reserved. # All rights reserved.
# pyre-unsafe
# This source code is licensed under the license found in the # This source code is licensed under the license found in the
# LICENSE file in the root directory of this source tree. # LICENSE file in the root directory of this source tree.

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
""" """
ViTDet backbone adapted from Detectron2. ViTDet backbone adapted from Detectron2.
This module implements Vision Transformer (ViT) backbone for object detection. This module implements Vision Transformer (ViT) backbone for object detection.

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
"""Provides utility to combine a vision backbone with a language backbone.""" """Provides utility to combine a vision backbone with a language backbone."""
from copy import copy from copy import copy

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
import os import os
from typing import Optional from typing import Optional

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
import os import os
is_enabled = False is_enabled = False

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
from collections import defaultdict from collections import defaultdict
import torch import torch

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
import torch import torch

View File

@@ -1,4 +1,6 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
import logging import logging
import torch import torch

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
import torch import torch

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
import torch import torch

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
import logging import logging
import numpy as np import numpy as np

View File

@@ -1,5 +1,7 @@
# Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved # Copyright (c) Meta Platforms, Inc. and affiliates. All Rights Reserved
# pyre-unsafe
import os import os
import numpy as np import numpy as np

Some files were not shown because too many files have changed in this diff Show More