Skip to content

Commit

Permalink
update copyright header
Browse files Browse the repository at this point in the history
Summary:
close facebookresearch#2200

Pull Request resolved: fairinternal/detectron2#478

Reviewed By: alexander-kirillov

Differential Revision: D24752469

Pulled By: ppwwyyxx

fbshipit-source-id: d32f287a9827c2a50eeb69cfea9cf518999e2a3d
  • Loading branch information
ppwwyyxx authored and facebook-github-bot committed Nov 5, 2020
1 parent 8cf79c4 commit 60d7a1f
Show file tree
Hide file tree
Showing 343 changed files with 357 additions and 349 deletions.
12 changes: 9 additions & 3 deletions INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ Two possibilities:
you need to either install a different build of PyTorch (or build by yourself)
to match your local CUDA installation, or install a different version of CUDA to match PyTorch.

* PyTorch/torchvision/Detectron2 is not built for the correct GPU architecture (aka. compute capability).
* PyTorch/torchvision/Detectron2 is not built for the correct GPU SM architecture (aka. compute capability).

The architecture included by PyTorch/detectron2/torchvision is available in the "architecture flags" in
`python -m detectron2.utils.collect_env`. It must include
Expand Down Expand Up @@ -183,7 +183,7 @@ to match your local CUDA installation, or install a different version of CUDA to

<details>
<summary>
C++ compilation errors from NVCC / NVRTC
C++ compilation errors from NVCC / NVRTC; "Unsupported gpu architecture"
</summary>

1. Local CUDA/NVCC version has to match the CUDA version of your PyTorch. Both can be found in
Expand All @@ -192,7 +192,13 @@ C++ compilation errors from NVCC / NVRTC
you need to either install a different build of PyTorch (or build by yourself)
to match your local CUDA installation, or install a different version of CUDA to match PyTorch.

2. The combination of NVCC and GCC you use is incompatible. You need to change one of their versions.
2. Local CUDA/NVCC version shall support the SM architecture (a.k.a. compute capability) of your GPU.
The capability of your GPU can be found at [developer.nvidia.com/cuda-gpus](https://developer.nvidia.com/cuda-gpus).
The capability supported by NVCC is listed at [here](https://gist.github.com/ax3l/9489132).
If your NVCC version is too old, this can be workaround a lower capability.environment variable
`TORCH_CUDA_ARCH_LIST` to a lower, supported capability.

3. The combination of NVCC and GCC you use is incompatible. You need to change one of their versions.
See [here](https://gist.github.com/ax3l/9489132) for some valid combinations.

The CUDA/GCC version used by PyTorch can be found by `print(torch.__config__.show())`.
Expand Down
3 changes: 2 additions & 1 deletion LICENSE
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,8 @@ file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.

Copyright 2019 - present, Facebook, Inc
Copyright [yyyy] [name of copyright owner]


Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
Expand Down
2 changes: 1 addition & 1 deletion datasets/prepare_ade20k_sem_seg.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
import numpy as np
import os
from pathlib import Path
Expand Down
2 changes: 1 addition & 1 deletion datasets/prepare_cocofied_lvis.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.

import copy
import json
Expand Down
2 changes: 1 addition & 1 deletion datasets/prepare_for_tests.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#!/bin/bash -e
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.

# Download some files needed for running tests.

Expand Down
2 changes: 1 addition & 1 deletion datasets/prepare_panoptic_fpn.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.

import functools
import json
Expand Down
2 changes: 1 addition & 1 deletion demo/demo.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
import argparse
import glob
import multiprocessing as mp
Expand Down
2 changes: 1 addition & 1 deletion demo/predictor.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
import atexit
import bisect
import multiprocessing as mp
Expand Down
2 changes: 1 addition & 1 deletion detectron2/__init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved.
# Copyright (c) Facebook, Inc. and its affiliates.

from .utils.env import setup_environment

Expand Down
2 changes: 1 addition & 1 deletion detectron2/checkpoint/__init__.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# -*- coding: utf-8 -*-
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
# File:


Expand Down
2 changes: 1 addition & 1 deletion detectron2/checkpoint/c2_model_loading.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
import copy
import logging
import re
Expand Down
2 changes: 1 addition & 1 deletion detectron2/checkpoint/catalog.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
import logging

from detectron2.utils.file_io import PathHandler, PathManager
Expand Down
2 changes: 1 addition & 1 deletion detectron2/checkpoint/detection_checkpoint.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
import pickle
from fvcore.common.checkpoint import Checkpointer

Expand Down
2 changes: 1 addition & 1 deletion detectron2/config/__init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
from .compat import downgrade_config, upgrade_config
from .config import CfgNode, get_cfg, global_cfg, set_global_cfg, configurable

Expand Down
2 changes: 1 addition & 1 deletion detectron2/config/compat.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
"""
Backward compatibility of configs.
Expand Down
2 changes: 1 addition & 1 deletion detectron2/config/config.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# -*- coding: utf-8 -*-
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.

import functools
import inspect
Expand Down
2 changes: 1 addition & 1 deletion detectron2/config/defaults.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
from .config import CfgNode as CN

# -----------------------------------------------------------------------------
Expand Down
2 changes: 1 addition & 1 deletion detectron2/data/__init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
from . import transforms # isort:skip

from .build import (
Expand Down
2 changes: 1 addition & 1 deletion detectron2/data/build.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
import itertools
import logging
import numpy as np
Expand Down
2 changes: 1 addition & 1 deletion detectron2/data/catalog.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
import copy
import logging
import types
Expand Down
2 changes: 1 addition & 1 deletion detectron2/data/common.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
import copy
import itertools
import logging
Expand Down
2 changes: 1 addition & 1 deletion detectron2/data/dataset_mapper.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
import copy
import logging
import numpy as np
Expand Down
2 changes: 1 addition & 1 deletion detectron2/data/datasets/__init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
from .coco import load_coco_json, load_sem_seg, register_coco_instances
from .coco_panoptic import register_coco_panoptic, register_coco_panoptic_separated
from .lvis import load_lvis_json, register_lvis_instances, get_lvis_instances_meta
Expand Down
2 changes: 1 addition & 1 deletion detectron2/data/datasets/builtin.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# -*- coding: utf-8 -*-
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.


"""
Expand Down
2 changes: 1 addition & 1 deletion detectron2/data/datasets/builtin_meta.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# -*- coding: utf-8 -*-
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.


# All coco categories, together with their nice-looking visualization colors
Expand Down
2 changes: 1 addition & 1 deletion detectron2/data/datasets/cityscapes.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
import functools
import json
import logging
Expand Down
2 changes: 1 addition & 1 deletion detectron2/data/datasets/cityscapes_panoptic.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
import json
import logging
import os
Expand Down
2 changes: 1 addition & 1 deletion detectron2/data/datasets/coco.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
import contextlib
import datetime
import io
Expand Down
2 changes: 1 addition & 1 deletion detectron2/data/datasets/coco_panoptic.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
import copy
import json
import os
Expand Down
2 changes: 1 addition & 1 deletion detectron2/data/datasets/lvis.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
import logging
import os
from fvcore.common.timer import Timer
Expand Down
2 changes: 1 addition & 1 deletion detectron2/data/datasets/lvis_v0_5_categories.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
# Autogen with
# with open("lvis_v0.5_val.json", "r") as f:
# a = json.load(f)
Expand Down
2 changes: 1 addition & 1 deletion detectron2/data/datasets/lvis_v1_categories.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
# Autogen with
# with open("lvis_v1_val.json", "r") as f:
# a = json.load(f)
Expand Down
2 changes: 1 addition & 1 deletion detectron2/data/datasets/pascal_voc.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# -*- coding: utf-8 -*-
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.

import numpy as np
import os
Expand Down
2 changes: 1 addition & 1 deletion detectron2/data/datasets/register_coco.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
from .coco import register_coco_instances # noqa
from .coco_panoptic import register_coco_panoptic_separated # noqa
2 changes: 1 addition & 1 deletion detectron2/data/detection_utils.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# -*- coding: utf-8 -*-
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.

"""
Common data processing utilities that are used in a
Expand Down
2 changes: 1 addition & 1 deletion detectron2/data/samplers/__init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
from .distributed_sampler import InferenceSampler, RepeatFactorTrainingSampler, TrainingSampler
from .grouped_batch_sampler import GroupedBatchSampler

Expand Down
2 changes: 1 addition & 1 deletion detectron2/data/samplers/distributed_sampler.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
import itertools
import math
from collections import defaultdict
Expand Down
2 changes: 1 addition & 1 deletion detectron2/data/samplers/grouped_batch_sampler.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
import numpy as np
from torch.utils.data.sampler import BatchSampler, Sampler

Expand Down
2 changes: 1 addition & 1 deletion detectron2/data/transforms/__init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
from fvcore.transforms.transform import Transform, TransformList # order them first
from fvcore.transforms.transform import *
from .transform import *
Expand Down
2 changes: 1 addition & 1 deletion detectron2/data/transforms/augmentation.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# -*- coding: utf-8 -*-
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.

import inspect
import numpy as np
Expand Down
2 changes: 1 addition & 1 deletion detectron2/data/transforms/augmentation_impl.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# -*- coding: utf-8 -*-
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
"""
Implement many useful :class:`Augmentation`.
"""
Expand Down
2 changes: 1 addition & 1 deletion detectron2/data/transforms/transform.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# -*- coding: utf-8 -*-
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.

"""
See "Data Augmentation" tutorial for an overview of the system:
Expand Down
2 changes: 1 addition & 1 deletion detectron2/engine/__init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved.
# Copyright (c) Facebook, Inc. and its affiliates.

from .launch import *
from .train_loop import *
Expand Down
2 changes: 1 addition & 1 deletion detectron2/engine/defaults.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# -*- coding: utf-8 -*-
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.

"""
This file contains components with some default boilerplate logic user may need
Expand Down
2 changes: 1 addition & 1 deletion detectron2/engine/hooks.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# -*- coding: utf-8 -*-
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.

import datetime
import itertools
Expand Down
2 changes: 1 addition & 1 deletion detectron2/engine/launch.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
import logging
import torch
import torch.distributed as dist
Expand Down
2 changes: 1 addition & 1 deletion detectron2/engine/train_loop.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# -*- coding: utf-8 -*-
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.

import logging
import numpy as np
Expand Down
2 changes: 1 addition & 1 deletion detectron2/evaluation/__init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
from .cityscapes_evaluation import CityscapesInstanceEvaluator, CityscapesSemSegEvaluator
from .coco_evaluation import COCOEvaluator
from .rotated_coco_evaluation import RotatedCOCOEvaluator
Expand Down
2 changes: 1 addition & 1 deletion detectron2/evaluation/cityscapes_evaluation.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
import glob
import logging
import numpy as np
Expand Down
2 changes: 1 addition & 1 deletion detectron2/evaluation/coco_evaluation.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
import contextlib
import copy
import io
Expand Down
2 changes: 1 addition & 1 deletion detectron2/evaluation/evaluator.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
import datetime
import logging
import time
Expand Down
2 changes: 1 addition & 1 deletion detectron2/evaluation/fast_eval_api.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
import copy
import numpy as np
import time
Expand Down
2 changes: 1 addition & 1 deletion detectron2/evaluation/lvis_evaluation.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
import copy
import itertools
import json
Expand Down
2 changes: 1 addition & 1 deletion detectron2/evaluation/panoptic_evaluation.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
import contextlib
import io
import itertools
Expand Down
2 changes: 1 addition & 1 deletion detectron2/evaluation/pascal_voc_evaluation.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# -*- coding: utf-8 -*-
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.

import logging
import numpy as np
Expand Down
2 changes: 1 addition & 1 deletion detectron2/evaluation/rotated_coco_evaluation.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
import itertools
import json
import numpy as np
Expand Down
2 changes: 1 addition & 1 deletion detectron2/evaluation/sem_seg_evaluation.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
import itertools
import json
import logging
Expand Down
2 changes: 1 addition & 1 deletion detectron2/evaluation/testing.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
# Copyright (c) Facebook, Inc. and its affiliates.
import logging
import numpy as np
import pprint
Expand Down
Loading

0 comments on commit 60d7a1f

Please sign in to comment.