summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Luevano <55825613+luevano@users.noreply.github.com>2019-12-18 07:21:35 -0700
committerDavid Luevano <55825613+luevano@users.noreply.github.com>2019-12-18 07:21:35 -0700
commit487bf8840846b5d4d694b38985268c308aadb36e (patch)
treeba3a3a742a503f925a5a7792e1bd16ee518066c9
parent96a3f2b2950451a478c951e642a4aa188219682b (diff)
Refactor files
-rw-r--r--lj_matrix/__init__.py22
-rw-r--r--lj_matrix/__main__.py (renamed from main.py)10
-rw-r--r--lj_matrix/c_matrix.py (renamed from c_matrix.py)2
-rw-r--r--lj_matrix/cholesky_solve.py (renamed from cholesky_solve.py)0
-rw-r--r--lj_matrix/do_ml.py (renamed from do_ml.py)4
-rw-r--r--lj_matrix/frob_norm.py (renamed from frob_norm.py)0
-rw-r--r--lj_matrix/gauss_kernel.py (renamed from gauss_kernel.py)2
-rw-r--r--lj_matrix/lj_matrix.py (renamed from lj_matrix.py)2
-rw-r--r--lj_matrix/misc.py (renamed from misc.py)0
-rw-r--r--lj_matrix/read_qm7_data.py (renamed from read_qm7_data.py)2
10 files changed, 33 insertions, 11 deletions
diff --git a/lj_matrix/__init__.py b/lj_matrix/__init__.py
new file mode 100644
index 000000000..48cd14913
--- /dev/null
+++ b/lj_matrix/__init__.py
@@ -0,0 +1,22 @@
+"""MIT License
+
+Copyright (c) 2019 David Luevano Alvarado
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+SOFTWARE.
+"""
diff --git a/main.py b/lj_matrix/__main__.py
index 3bf86572e..4e13f4995 100644
--- a/main.py
+++ b/lj_matrix/__main__.py
@@ -24,11 +24,11 @@ import time
from multiprocessing import Process, Pipe
# import matplotlib.pyplot as plt
import pandas as pd
-from misc import printc
-from read_qm7_data import read_qm7_data
-from c_matrix import c_matrix_multiple
-from lj_matrix import lj_matrix_multiple
-from do_ml import do_ml
+from lj_matrix.misc import printc
+from lj_matrix.read_qm7_data import read_qm7_data
+from lj_matrix.c_matrix import c_matrix_multiple
+from lj_matrix.lj_matrix import lj_matrix_multiple
+from lj_matrix.do_ml import do_ml
# Test
diff --git a/c_matrix.py b/lj_matrix/c_matrix.py
index 4de711a1b..f40a18c68 100644
--- a/c_matrix.py
+++ b/lj_matrix/c_matrix.py
@@ -21,7 +21,7 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
"""
import time
-from misc import printc
+from lj_matrix.misc import printc
import math
import numpy as np
from numpy.linalg import eig
diff --git a/cholesky_solve.py b/lj_matrix/cholesky_solve.py
index bc6a572a3..bc6a572a3 100644
--- a/cholesky_solve.py
+++ b/lj_matrix/cholesky_solve.py
diff --git a/do_ml.py b/lj_matrix/do_ml.py
index c88533e68..acf5455f4 100644
--- a/do_ml.py
+++ b/lj_matrix/do_ml.py
@@ -23,8 +23,8 @@ SOFTWARE.
import time
from misc import printc
import numpy as np
-from gauss_kernel import gauss_kernel
-from cholesky_solve import cholesky_solve
+from lj_matrix.gauss_kernel import gauss_kernel
+from lj_matrix.cholesky_solve import cholesky_solve
def do_ml(desc_data,
diff --git a/frob_norm.py b/lj_matrix/frob_norm.py
index 4c3a2945d..4c3a2945d 100644
--- a/frob_norm.py
+++ b/lj_matrix/frob_norm.py
diff --git a/gauss_kernel.py b/lj_matrix/gauss_kernel.py
index 0dfc65d59..5dd8e6406 100644
--- a/gauss_kernel.py
+++ b/lj_matrix/gauss_kernel.py
@@ -22,7 +22,7 @@ SOFTWARE.
"""
import math
import numpy as np
-from frob_norm import frob_norm
+from lj_matrix.frob_norm import frob_norm
def gauss_kernel(X_1, X_2, sigma):
diff --git a/lj_matrix.py b/lj_matrix/lj_matrix.py
index 2a8e0d956..4f63e95ca 100644
--- a/lj_matrix.py
+++ b/lj_matrix/lj_matrix.py
@@ -21,7 +21,7 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
"""
import time
-from misc import printc
+from lj_matrix.misc import printc
import math
import numpy as np
from numpy.linalg import eig
diff --git a/misc.py b/lj_matrix/misc.py
index c50653a5c..c50653a5c 100644
--- a/misc.py
+++ b/lj_matrix/misc.py
diff --git a/read_qm7_data.py b/lj_matrix/read_qm7_data.py
index 068ea1a42..b54691fb0 100644
--- a/read_qm7_data.py
+++ b/lj_matrix/read_qm7_data.py
@@ -24,7 +24,7 @@ import os
import time
import numpy as np
import random
-from misc import printc
+from lj_matrix.misc import printc
# 'periodic_table_of_elements.txt' retrieved from