From 444bb69d7b2aeac25951b8934d606b3842644476 Mon Sep 17 00:00:00 2001 From: Amir Mardan <46511946+AmirMardan@users.noreply.github.com> Date: Thu, 20 Jul 2023 16:15:24 -0400 Subject: [PATCH] add header to all files --- LICENSE | 2 +- first_break_picking/__init__.py | 10 ++++++++++ first_break_picking/data/__init__.py | 9 +++++++++ first_break_picking/data/_data_dc_del.py | 10 ++++++++++ first_break_picking/data/_data_fb.py | 10 ++++++++++ first_break_picking/data/_datasets.py | 10 ++++++++++ first_break_picking/data/data_generator.py | 10 ++++++++++ first_break_picking/data/data_segy2npy.py | 10 ++++++++++ first_break_picking/data/data_utils.py | 10 ++++++++++ first_break_picking/data/dataset.py | 9 +++++++++ first_break_picking/data/seis_model.py | 10 ++++++++++ first_break_picking/data/signals/__init__.py | 9 +++++++++ first_break_picking/default_values.py | 10 ++++++++++ first_break_picking/saved_checkpoints/__init__.py | 9 +++++++++ first_break_picking/tools.py | 10 ++++++++++ first_break_picking/train_eval/__init__.py | 9 +++++++++ first_break_picking/train_eval/_predicting_tools.py | 10 ++++++++++ first_break_picking/train_eval/ai_tools.py | 10 ++++++++++ first_break_picking/train_eval/metrics.py | 12 ++++++++++-- first_break_picking/train_eval/parameter_tools.py | 10 ++++++++++ first_break_picking/train_eval/predict.py | 10 ++++++++++ first_break_picking/train_eval/train.py | 10 ++++++++++ first_break_picking/train_eval/unet.py | 10 ++++++++++ readme.md | 5 ++++- 24 files changed, 220 insertions(+), 4 deletions(-) diff --git a/LICENSE b/LICENSE index 275d1cd..bb9e882 100644 --- a/LICENSE +++ b/LICENSE @@ -1,6 +1,6 @@ MIT License -Copyright (c) 2023 Amir Mardan +Copyright (c) 2023 Les solutions Géostack, Inc. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/first_break_picking/__init__.py b/first_break_picking/__init__.py index c8f709d..d4ed0dd 100644 --- a/first_break_picking/__init__.py +++ b/first_break_picking/__init__.py @@ -1,3 +1,13 @@ +# -*- coding: utf-8 -*- +# ============================================================================= +# Copyright (C) Les solutions géostack, Inc. +# +# This file is part of the First-Break Picking package. +# Licensed under the terms of the MIT License. +# +# https://github.com/geo-stack/first_break_picking +# ============================================================================= + import os import sys package_path = os.path.abspath(os.path.join(__file__, "../")) diff --git a/first_break_picking/data/__init__.py b/first_break_picking/data/__init__.py index 904a353..9fe5bb4 100644 --- a/first_break_picking/data/__init__.py +++ b/first_break_picking/data/__init__.py @@ -1 +1,10 @@ +# -*- coding: utf-8 -*- +# ============================================================================= +# Copyright (C) Les solutions géostack, Inc. +# +# This file is part of the First-Break Picking package. +# Licensed under the terms of the MIT License. +# +# https://github.com/geo-stack/first_break_picking +# ============================================================================= from first_break_picking.data.data_segy2npy import save_shots_fb diff --git a/first_break_picking/data/_data_dc_del.py b/first_break_picking/data/_data_dc_del.py index f581b6b..be22598 100644 --- a/first_break_picking/data/_data_dc_del.py +++ b/first_break_picking/data/_data_dc_del.py @@ -1,3 +1,13 @@ +# -*- coding: utf-8 -*- +# ============================================================================= +# Copyright (C) Les solutions géostack, Inc. +# +# This file is part of the First-Break Picking package. +# Licensed under the terms of the MIT License. +# +# https://github.com/geo-stack/first_break_picking +# ============================================================================= + from pathlib import Path import os import numpy as np diff --git a/first_break_picking/data/_data_fb.py b/first_break_picking/data/_data_fb.py index 3f5ea1c..74e113f 100644 --- a/first_break_picking/data/_data_fb.py +++ b/first_break_picking/data/_data_fb.py @@ -1,3 +1,13 @@ +# -*- coding: utf-8 -*- +# ============================================================================= +# Copyright (C) Les solutions géostack, Inc. +# +# This file is part of the First-Break Picking package. +# Licensed under the terms of the MIT License. +# +# https://github.com/geo-stack/first_break_picking +# ============================================================================= + import os from typing import List, Tuple import pandas as pd diff --git a/first_break_picking/data/_datasets.py b/first_break_picking/data/_datasets.py index f9a64fb..a39b75f 100644 --- a/first_break_picking/data/_datasets.py +++ b/first_break_picking/data/_datasets.py @@ -1,3 +1,13 @@ +# -*- coding: utf-8 -*- +# ============================================================================= +# Copyright (C) Les solutions géostack, Inc. +# +# This file is part of the First-Break Picking package. +# Licensed under the terms of the MIT License. +# +# https://github.com/geo-stack/first_break_picking +# ============================================================================= + from torch.utils.data import Dataset, random_split, DataLoader, ConcatDataset import os from typing import Tuple, List, Union diff --git a/first_break_picking/data/data_generator.py b/first_break_picking/data/data_generator.py index f15c197..ab15263 100644 --- a/first_break_picking/data/data_generator.py +++ b/first_break_picking/data/data_generator.py @@ -1,3 +1,13 @@ +# -*- coding: utf-8 -*- +# ============================================================================= +# Copyright (C) Les solutions géostack, Inc. +# +# This file is part of the First-Break Picking package. +# Licensed under the terms of the MIT License. +# +# https://github.com/geo-stack/first_break_picking +# ============================================================================= + import numpy as np from pathlib import Path import argparse diff --git a/first_break_picking/data/data_segy2npy.py b/first_break_picking/data/data_segy2npy.py index 4d5cd9b..9f538d0 100644 --- a/first_break_picking/data/data_segy2npy.py +++ b/first_break_picking/data/data_segy2npy.py @@ -1,3 +1,13 @@ +# -*- coding: utf-8 -*- +# ============================================================================= +# Copyright (C) Les solutions géostack, Inc. +# +# This file is part of the First-Break Picking package. +# Licensed under the terms of the MIT License. +# +# https://github.com/geo-stack/first_break_picking +# ============================================================================= + import numpy as np import os from typing import List, Union, Tuple, Optional diff --git a/first_break_picking/data/data_utils.py b/first_break_picking/data/data_utils.py index 726bb55..0c59168 100644 --- a/first_break_picking/data/data_utils.py +++ b/first_break_picking/data/data_utils.py @@ -1,3 +1,13 @@ +# -*- coding: utf-8 -*- +# ============================================================================= +# Copyright (C) Les solutions géostack, Inc. +# +# This file is part of the First-Break Picking package. +# Licensed under the terms of the MIT License. +# +# https://github.com/geo-stack/first_break_picking +# ============================================================================= + import random from math import ceil from typing import Tuple, List, Any, Union, Optional diff --git a/first_break_picking/data/dataset.py b/first_break_picking/data/dataset.py index 8deae0f..847dae1 100644 --- a/first_break_picking/data/dataset.py +++ b/first_break_picking/data/dataset.py @@ -1,3 +1,12 @@ +# -*- coding: utf-8 -*- +# ============================================================================= +# Copyright (C) Les solutions géostack, Inc. +# +# This file is part of the First-Break Picking package. +# Licensed under the terms of the MIT License. +# +# https://github.com/geo-stack/first_break_picking +# ============================================================================= from torch.utils.data import Dataset, random_split, DataLoader, ConcatDataset import os from typing import Tuple, List, Union diff --git a/first_break_picking/data/seis_model.py b/first_break_picking/data/seis_model.py index 65ea96e..f9e78c0 100644 --- a/first_break_picking/data/seis_model.py +++ b/first_break_picking/data/seis_model.py @@ -1,3 +1,13 @@ +# -*- coding: utf-8 -*- +# ============================================================================= +# Copyright (C) Les solutions géostack, Inc. +# +# This file is part of the First-Break Picking package. +# Licensed under the terms of the MIT License. +# +# https://github.com/geo-stack/first_break_picking +# ============================================================================= + import os.path from typing import Optional, Union, List, Tuple diff --git a/first_break_picking/data/signals/__init__.py b/first_break_picking/data/signals/__init__.py index e69de29..d3e15cb 100644 --- a/first_break_picking/data/signals/__init__.py +++ b/first_break_picking/data/signals/__init__.py @@ -0,0 +1,9 @@ +# -*- coding: utf-8 -*- +# ============================================================================= +# Copyright (C) Les solutions géostack, Inc. +# +# This file is part of the First-Break Picking package. +# Licensed under the terms of the MIT License. +# +# https://github.com/geo-stack/first_break_picking +# ============================================================================= \ No newline at end of file diff --git a/first_break_picking/default_values.py b/first_break_picking/default_values.py index b0f76a7..0625ec9 100644 --- a/first_break_picking/default_values.py +++ b/first_break_picking/default_values.py @@ -1,3 +1,13 @@ +# -*- coding: utf-8 -*- +# ============================================================================= +# Copyright (C) Les solutions géostack, Inc. +# +# This file is part of the First-Break Picking package. +# Licensed under the terms of the MIT License. +# +# https://github.com/geo-stack/first_break_picking +# ============================================================================= + import torch import os from argparse import ArgumentParser, Namespace diff --git a/first_break_picking/saved_checkpoints/__init__.py b/first_break_picking/saved_checkpoints/__init__.py index e69de29..590b871 100644 --- a/first_break_picking/saved_checkpoints/__init__.py +++ b/first_break_picking/saved_checkpoints/__init__.py @@ -0,0 +1,9 @@ +# -*- coding: utf-8 -*- +# ============================================================================= +# Copyright (C) Les solutions géostack, Inc. +# +# This file is part of the First-Break Picking package. +# Licensed under the terms of the MIT License. +# +# https://github.com/geo-stack/first_break_picking +# ============================================================================= diff --git a/first_break_picking/tools.py b/first_break_picking/tools.py index bf9b729..46fee45 100644 --- a/first_break_picking/tools.py +++ b/first_break_picking/tools.py @@ -1,3 +1,13 @@ +# -*- coding: utf-8 -*- +# ============================================================================= +# Copyright (C) Les solutions géostack, Inc. +# +# This file is part of the First-Break Picking package. +# Licensed under the terms of the MIT License. +# +# https://github.com/geo-stack/first_break_picking +# ============================================================================= + import numpy as np import matplotlib import matplotlib.pyplot as plt diff --git a/first_break_picking/train_eval/__init__.py b/first_break_picking/train_eval/__init__.py index e69de29..590b871 100644 --- a/first_break_picking/train_eval/__init__.py +++ b/first_break_picking/train_eval/__init__.py @@ -0,0 +1,9 @@ +# -*- coding: utf-8 -*- +# ============================================================================= +# Copyright (C) Les solutions géostack, Inc. +# +# This file is part of the First-Break Picking package. +# Licensed under the terms of the MIT License. +# +# https://github.com/geo-stack/first_break_picking +# ============================================================================= diff --git a/first_break_picking/train_eval/_predicting_tools.py b/first_break_picking/train_eval/_predicting_tools.py index cd38f34..af0ab09 100644 --- a/first_break_picking/train_eval/_predicting_tools.py +++ b/first_break_picking/train_eval/_predicting_tools.py @@ -1,3 +1,13 @@ +# -*- coding: utf-8 -*- +# ============================================================================= +# Copyright (C) Les solutions géostack, Inc. +# +# This file is part of the First-Break Picking package. +# Licensed under the terms of the MIT License. +# +# https://github.com/geo-stack/first_break_picking +# ============================================================================= + from typing import Optional, Union, Tuple, List import matplotlib.pyplot as plt import pandas as pd diff --git a/first_break_picking/train_eval/ai_tools.py b/first_break_picking/train_eval/ai_tools.py index 8c15f06..01fd9f6 100644 --- a/first_break_picking/train_eval/ai_tools.py +++ b/first_break_picking/train_eval/ai_tools.py @@ -1,3 +1,13 @@ +# -*- coding: utf-8 -*- +# ============================================================================= +# Copyright (C) Les solutions géostack, Inc. +# +# This file is part of the First-Break Picking package. +# Licensed under the terms of the MIT License. +# +# https://github.com/geo-stack/first_break_picking +# ============================================================================= + import numpy as np import torch from typing import Optional, Union, Tuple, List diff --git a/first_break_picking/train_eval/metrics.py b/first_break_picking/train_eval/metrics.py index 8ce2f9b..8f74aa6 100644 --- a/first_break_picking/train_eval/metrics.py +++ b/first_break_picking/train_eval/metrics.py @@ -1,3 +1,13 @@ +# -*- coding: utf-8 -*- +# ============================================================================= +# Copyright (C) Les solutions géostack, Inc. +# +# This file is part of the First-Break Picking package. +# Licensed under the terms of the MIT License. +# +# https://github.com/geo-stack/first_break_picking +# ============================================================================= + import torch import torch.nn as nn import torch.nn.functional as F @@ -9,8 +19,6 @@ from first_break_picking.train_eval.unet import UNet import first_break_picking.train_eval.ai_tools as tools - - class BDiceLoss(nn.Module): def __init__(self, weight=None, size_average=True): super(BDiceLoss, self).__init__() diff --git a/first_break_picking/train_eval/parameter_tools.py b/first_break_picking/train_eval/parameter_tools.py index 4854ace..a752cd0 100644 --- a/first_break_picking/train_eval/parameter_tools.py +++ b/first_break_picking/train_eval/parameter_tools.py @@ -1,3 +1,13 @@ +# -*- coding: utf-8 -*- +# ============================================================================= +# Copyright (C) Les solutions géostack, Inc. +# +# This file is part of the First-Break Picking package. +# Licensed under the terms of the MIT License. +# +# https://github.com/geo-stack/first_break_picking +# ============================================================================= + import os import logging import torch diff --git a/first_break_picking/train_eval/predict.py b/first_break_picking/train_eval/predict.py index a699edb..805e615 100644 --- a/first_break_picking/train_eval/predict.py +++ b/first_break_picking/train_eval/predict.py @@ -1,3 +1,13 @@ +# -*- coding: utf-8 -*- +# ============================================================================= +# Copyright (C) Les solutions géostack, Inc. +# +# This file is part of the First-Break Picking package. +# Licensed under the terms of the MIT License. +# +# https://github.com/geo-stack/first_break_picking +# ============================================================================= + import torch from pathlib import Path import shutil diff --git a/first_break_picking/train_eval/train.py b/first_break_picking/train_eval/train.py index 5730b1a..91df27d 100644 --- a/first_break_picking/train_eval/train.py +++ b/first_break_picking/train_eval/train.py @@ -1,3 +1,13 @@ +# -*- coding: utf-8 -*- +# ============================================================================= +# Copyright (C) Les solutions géostack, Inc. +# +# This file is part of the First-Break Picking package. +# Licensed under the terms of the MIT License. +# +# https://github.com/geo-stack/first_break_picking +# ============================================================================= + import torch from first_break_picking.data.dataset import get_loaders from pathlib import Path diff --git a/first_break_picking/train_eval/unet.py b/first_break_picking/train_eval/unet.py index 270b650..1b2d190 100644 --- a/first_break_picking/train_eval/unet.py +++ b/first_break_picking/train_eval/unet.py @@ -1,3 +1,13 @@ +# -*- coding: utf-8 -*- +# ============================================================================= +# Copyright (C) Les solutions géostack, Inc. +# +# This file is part of the First-Break Picking package. +# Licensed under the terms of the MIT License. +# +# https://github.com/geo-stack/first_break_picking +# ============================================================================= + import torch.nn as nn import torch import torch.nn.functional as F diff --git a/readme.md b/readme.md index bc3dae6..e0a8675 100644 --- a/readme.md +++ b/readme.md @@ -174,8 +174,11 @@ predictor.predict(
Warning: If you define the sampling rate incorrrectly, you can't see its effects on the plot (Y-axis is time step), but the saved time in first-break folder will be wrong.
+
- + +**Ackowledgment:**
+This work, developped by [Amir Mardan](https://github.com/AmirMardan), was supported by Mitacs through the Mitacs Elevate Program. [Top](#top)