mirror of
https://github.com/macaodha/batdetect2.git
synced 2025-06-29 22:51:58 +02:00
Made explicit imports in detector/models.py
This commit is contained in:
parent
251d87c690
commit
d7ddf72c73
@ -1,11 +1,17 @@
|
|||||||
import math
|
|
||||||
|
|
||||||
import numpy as np
|
|
||||||
import torch
|
import torch
|
||||||
import torch.nn as nn
|
from torch import nn
|
||||||
import torch.nn.functional as F
|
import torch.nn.functional as F
|
||||||
|
|
||||||
|
|
||||||
|
__all__ = [
|
||||||
|
"SelfAttention",
|
||||||
|
"ConvBlockDownCoordF",
|
||||||
|
"ConvBlockDownStandard",
|
||||||
|
"ConvBlockUpF",
|
||||||
|
"ConvBlockUpStandard",
|
||||||
|
]
|
||||||
|
|
||||||
|
|
||||||
class SelfAttention(nn.Module):
|
class SelfAttention(nn.Module):
|
||||||
def __init__(self, ip_dim, att_dim):
|
def __init__(self, ip_dim, att_dim):
|
||||||
super(SelfAttention, self).__init__()
|
super(SelfAttention, self).__init__()
|
||||||
|
@ -1,12 +1,22 @@
|
|||||||
import numpy as np
|
|
||||||
import torch
|
import torch
|
||||||
import torch.fft
|
import torch.fft
|
||||||
import torch.nn as nn
|
|
||||||
import torch.nn.functional as F
|
import torch.nn.functional as F
|
||||||
import torchvision
|
|
||||||
from torch import nn
|
from torch import nn
|
||||||
|
|
||||||
from .model_helpers import *
|
from .model_helpers import (
|
||||||
|
SelfAttention,
|
||||||
|
ConvBlockDownCoordF,
|
||||||
|
ConvBlockDownStandard,
|
||||||
|
ConvBlockUpF,
|
||||||
|
ConvBlockUpStandard,
|
||||||
|
)
|
||||||
|
|
||||||
|
|
||||||
|
__all__ = [
|
||||||
|
"Net2DFast",
|
||||||
|
"Net2DFastNoAttn",
|
||||||
|
"Net2DFastNoCoordConv",
|
||||||
|
]
|
||||||
|
|
||||||
|
|
||||||
class Net2DFast(nn.Module):
|
class Net2DFast(nn.Module):
|
||||||
|
Loading…
Reference in New Issue
Block a user