Bumped numpy from 1.13.1 to 1.14.0 to satisfy TF 1.12.2 dependency. Updated grep commands in validator to also be compatible with BSD.
This commit is contained in:
parent
68fedf765d
commit
777c42c979
|
@ -14,7 +14,7 @@
|
||||||
# ln -s ../../script/git-hooks/pre-commit ./pre-commit
|
# ln -s ../../script/git-hooks/pre-commit ./pre-commit
|
||||||
|
|
||||||
|
|
||||||
FILES=$(git diff --name-only --cached --diff-filter=d | grep -E '*\.(py|java)$')
|
FILES=$(git diff --name-only --cached --diff-filter=d | grep -E '.*\.(py|java)$')
|
||||||
|
|
||||||
WEBSITE_TESTS_RESULT=0
|
WEBSITE_TESTS_RESULT=0
|
||||||
ANALYSIS_TESTS_RESULT=0
|
ANALYSIS_TESTS_RESULT=0
|
||||||
|
|
|
@ -206,15 +206,15 @@ def validate_dir(root_dir):
|
||||||
def get_git_files(state):
|
def get_git_files(state):
|
||||||
if state == 'staged':
|
if state == 'staged':
|
||||||
# Files staged for commit
|
# Files staged for commit
|
||||||
cmd = r"git diff --name-only --cached --diff-filter=d | grep -E '*\.(py|java)$'"
|
cmd = r"git diff --name-only --cached --diff-filter=d | grep -E '.*\.(py|java)$'"
|
||||||
|
|
||||||
elif state == 'unstaged':
|
elif state == 'unstaged':
|
||||||
# Tracked files not staged for commit
|
# Tracked files not staged for commit
|
||||||
cmd = r"git diff --name-only --diff-filter=d | grep -E '*\.(py|java)$'"
|
cmd = r"git diff --name-only --diff-filter=d | grep -E '.*\.(py|java)$'"
|
||||||
|
|
||||||
elif state == 'untracked':
|
elif state == 'untracked':
|
||||||
# Untracked files not staged for commit
|
# Untracked files not staged for commit
|
||||||
cmd = r"git ls-files --other --exclude-standard | grep -E '*\.(py|java)$'"
|
cmd = r"git ls-files --other --exclude-standard | grep -E '.*\.(py|java)$'"
|
||||||
|
|
||||||
with settings(warn_only=True):
|
with settings(warn_only=True):
|
||||||
res = local(cmd, capture=True)
|
res = local(cmd, capture=True)
|
||||||
|
|
|
@ -12,7 +12,6 @@ import pickle
|
||||||
import numpy as np
|
import numpy as np
|
||||||
import tensorflow as tf
|
import tensorflow as tf
|
||||||
from tensorflow import keras
|
from tensorflow import keras
|
||||||
from tensorflow.keras import layers
|
|
||||||
|
|
||||||
from .util import get_analysis_logger
|
from .util import get_analysis_logger
|
||||||
|
|
||||||
|
@ -50,10 +49,10 @@ class NeuralNet(object):
|
||||||
self.optimizer = tf.train.AdamOptimizer(learning_rate=self.learning_rate)
|
self.optimizer = tf.train.AdamOptimizer(learning_rate=self.learning_rate)
|
||||||
# input X is placeholder, weights are variables.
|
# input X is placeholder, weights are variables.
|
||||||
self.model = keras.Sequential([
|
self.model = keras.Sequential([
|
||||||
layers.Dense(64, activation=tf.nn.relu, input_shape=[n_input]),
|
keras.layers.Dense(64, activation=tf.nn.relu, input_shape=[n_input]),
|
||||||
layers.Dropout(0.5),
|
keras.layers.Dropout(0.5),
|
||||||
layers.Dense(64, activation=tf.nn.relu),
|
keras.layers.Dense(64, activation=tf.nn.relu),
|
||||||
layers.Dense(1)
|
keras.layers.Dense(1)
|
||||||
])
|
])
|
||||||
self.model.compile(loss='mean_squared_error',
|
self.model.compile(loss='mean_squared_error',
|
||||||
optimizer=self.optimizer,
|
optimizer=self.optimizer,
|
||||||
|
|
|
@ -8,7 +8,7 @@ django-request-logging==0.4.6
|
||||||
mock==2.0.0
|
mock==2.0.0
|
||||||
Fabric3>=1.13.1.post1
|
Fabric3>=1.13.1.post1
|
||||||
hurry.filesize>=0.9
|
hurry.filesize>=0.9
|
||||||
numpy==1.13.1
|
numpy==1.14.0
|
||||||
requests==2.18.4
|
requests==2.18.4
|
||||||
pycodestyle==2.3.1
|
pycodestyle==2.3.1
|
||||||
astroid==1.5.1
|
astroid==1.5.1
|
||||||
|
|
Loading…
Reference in New Issue