Skip to content

Commit

Permalink
file arrangement 2
Browse files Browse the repository at this point in the history
  • Loading branch information
Snailpong committed Dec 14, 2020
1 parent f995a11 commit dc686d8
Show file tree
Hide file tree
Showing 8 changed files with 18 additions and 399 deletions.
66 changes: 0 additions & 66 deletions crop_black.py

This file was deleted.

6 changes: 6 additions & 0 deletions feature_model.py
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,12 @@ def make_point_space(im_LR, im_GX, im_GY, im_GZ, patchNumber, w, point_space, MA
return point_space, patchNumber


def init_buckets(Q_TOTAL):
patchS = [[] for j in range(C.Q_TOTAL)]
xS = [[] for j in range(C.Q_TOTAL)]
return patchS, xS


def k_means_modeling(quantization):

with open('./arrays/qua', 'rb') as p:
Expand Down
10 changes: 0 additions & 10 deletions filter_func.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,16 +34,6 @@ def dog_sharpener(input, sigma=0.85, alpha=1.414, r=15, ksize=(3,3,3)):
return output


def add_weight(im1, w1, im2, w2, b):
return im1 * w1 + im2 * w2 + b


def clip_image(im):
clip_value = np.sort(im.ravel())[int(np.prod(im.shape) * 0.999)]
im = np.clip(im, 0, clip_value)
return im


@njit(parallel=True)
def ct_descriptor(im):
H, W, D = im.shape
Expand Down
61 changes: 0 additions & 61 deletions get_lr.py

This file was deleted.

163 changes: 0 additions & 163 deletions hashtable.py

This file was deleted.

18 changes: 7 additions & 11 deletions test.py
Original file line number Diff line number Diff line change
@@ -1,26 +1,22 @@
import os
import glob
import time

import numpy as np
import cupy as cp
from numba import jit, njit, prange

import nibabel as nib
import numpy as np

from numba import jit, njit, prange
from skimage.metrics import peak_signal_noise_ratio, structural_similarity

import filter_constant as C

from crop_black import *
from filter_constant import *
from feature_model import *
from filter_func import *
from get_lr import *
from kmeans_vector import KMeans_Vector
from matrix_compute import *
from train import load_kmeans_model, get_features
from preprocessing import *
from util import *
from kmeans_vector import KMeans_Vector
from feature_model import *

from skimage.metrics import peak_signal_noise_ratio, structural_similarity


def make_image(im_LR, im_GX, im_GY, im_GZ, w, kmeans, h):
Expand Down
Loading

0 comments on commit dc686d8

Please sign in to comment.