parent
777c8b6106
commit
d102e6dacf
2
wut
2
wut
|
@ -9,6 +9,8 @@
|
||||||
# Example:
|
# Example:
|
||||||
# wut 1456893
|
# wut 1456893
|
||||||
|
|
||||||
|
cd /srv/satnogs
|
||||||
|
|
||||||
OBSID="$1"
|
OBSID="$1"
|
||||||
|
|
||||||
rm -rf data/test
|
rm -rf data/test
|
||||||
|
|
|
@ -29,7 +29,7 @@
|
||||||
# XXX Should check input is sane...
|
# XXX Should check input is sane...
|
||||||
|
|
||||||
APIURL="https://network.satnogs.org/api"
|
APIURL="https://network.satnogs.org/api"
|
||||||
DOWNDIR="download"
|
DOWNDIR="/srv/satnogs/download"
|
||||||
OBSIDMIN="$1"
|
OBSIDMIN="$1"
|
||||||
OBSIDMAX="$2"
|
OBSIDMAX="$2"
|
||||||
OBSID=$OBSIDMIN
|
OBSID=$OBSIDMIN
|
||||||
|
|
|
@ -22,6 +22,8 @@ OBSIDMIN="$1"
|
||||||
OBSIDMAX="$2"
|
OBSIDMAX="$2"
|
||||||
OBSID=$OBSIDMIN
|
OBSID=$OBSIDMIN
|
||||||
|
|
||||||
|
cd /srv/satnogs
|
||||||
|
|
||||||
# Enable the following if you want to download waterfalls in this range:
|
# Enable the following if you want to download waterfalls in this range:
|
||||||
#echo "Downloading Waterfalls"
|
#echo "Downloading Waterfalls"
|
||||||
#./wut-water-range $OBSIDMIN $OBSIDMAX
|
#./wut-water-range $OBSIDMIN $OBSIDMAX
|
||||||
|
|
|
@ -20,6 +20,8 @@
|
||||||
#
|
#
|
||||||
# Possible vetted_status: bad, failed, good, null, unknown.
|
# Possible vetted_status: bad, failed, good, null, unknown.
|
||||||
|
|
||||||
|
cd /srv/satnogs
|
||||||
|
|
||||||
OBSTX="$1"
|
OBSTX="$1"
|
||||||
OBSIDMIN="$2"
|
OBSIDMIN="$2"
|
||||||
OBSIDMAX="$3"
|
OBSIDMAX="$3"
|
||||||
|
|
|
@ -23,6 +23,8 @@
|
||||||
#
|
#
|
||||||
# Possible vetted_status: bad, failed, good, null, unknown.
|
# Possible vetted_status: bad, failed, good, null, unknown.
|
||||||
|
|
||||||
|
cd /srv/satnogs
|
||||||
|
|
||||||
OBSENC="$1"
|
OBSENC="$1"
|
||||||
OBSIDMIN="$2"
|
OBSIDMIN="$2"
|
||||||
OBSIDMAX="$3"
|
OBSIDMAX="$3"
|
||||||
|
|
|
@ -8,6 +8,8 @@
|
||||||
# Example:
|
# Example:
|
||||||
# wut-files
|
# wut-files
|
||||||
|
|
||||||
|
cd /srv/satnogs
|
||||||
|
|
||||||
echo
|
echo
|
||||||
DF=`df -h download/`
|
DF=`df -h download/`
|
||||||
echo "$DF"
|
echo "$DF"
|
||||||
|
|
|
@ -8,6 +8,8 @@
|
||||||
# Example:
|
# Example:
|
||||||
# wut-files
|
# wut-files
|
||||||
|
|
||||||
|
cd /srv/satnogs
|
||||||
|
|
||||||
TRAIN=`find data/train -type f | wc -l`
|
TRAIN=`find data/train -type f | wc -l`
|
||||||
echo
|
echo
|
||||||
echo "Training Files: $TRAIN"
|
echo "Training Files: $TRAIN"
|
||||||
|
|
6
wut-ml
6
wut-ml
|
@ -68,9 +68,9 @@ datagen = ImageDataGenerator(
|
||||||
dtype='float32')
|
dtype='float32')
|
||||||
|
|
||||||
print("datagen.flow")
|
print("datagen.flow")
|
||||||
train_it = datagen.flow_from_directory('data/train/', class_mode='binary')
|
train_it = datagen.flow_from_directory('/srv/satnogs/data/train/', class_mode='binary')
|
||||||
val_it = datagen.flow_from_directory('data/val/', class_mode='binary')
|
val_it = datagen.flow_from_directory('/srv/satnogs/data/val/', class_mode='binary')
|
||||||
test_it = datagen.flow_from_directory('data/test/', class_mode='binary')
|
test_it = datagen.flow_from_directory('/srv/satnogs/data/test/', class_mode='binary')
|
||||||
|
|
||||||
print("train_it.next()")
|
print("train_it.next()")
|
||||||
trainX, trainY = train_it.next()
|
trainX, trainY = train_it.next()
|
||||||
|
|
|
@ -68,9 +68,9 @@ datagen = ImageDataGenerator(
|
||||||
dtype='float32')
|
dtype='float32')
|
||||||
|
|
||||||
print("datagen.flow")
|
print("datagen.flow")
|
||||||
train_it = datagen.flow_from_directory('data/train/', class_mode='binary')
|
train_it = datagen.flow_from_directory('/srv/satnogs/data/train/', class_mode='binary')
|
||||||
val_it = datagen.flow_from_directory('data/val/', class_mode='binary')
|
val_it = datagen.flow_from_directory('/srv/satnogs/data/val/', class_mode='binary')
|
||||||
test_it = datagen.flow_from_directory('data/test/', class_mode='binary')
|
test_it = datagen.flow_from_directory('/srv/satnogs/data/test/', class_mode='binary')
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -30,7 +30,7 @@ from tensorflow.python.keras.models import load_model
|
||||||
from tensorflow.python.keras.preprocessing.image import load_img
|
from tensorflow.python.keras.preprocessing.image import load_img
|
||||||
from tensorflow.python.keras.preprocessing.image import img_to_array
|
from tensorflow.python.keras.preprocessing.image import img_to_array
|
||||||
|
|
||||||
model = load_model('data/wut.h5')
|
model = load_model('/srv/satnogs/data/wut.h5')
|
||||||
img_width=256
|
img_width=256
|
||||||
img_height=256
|
img_height=256
|
||||||
model = Sequential()
|
model = Sequential()
|
||||||
|
|
|
@ -30,9 +30,9 @@ from tensorflow.python.keras.preprocessing.image import load_img
|
||||||
from tensorflow.python.keras.preprocessing.image import img_to_array
|
from tensorflow.python.keras.preprocessing.image import img_to_array
|
||||||
|
|
||||||
datagen = ImageDataGenerator()
|
datagen = ImageDataGenerator()
|
||||||
train_it = datagen.flow_from_directory('data/train/', class_mode='binary')
|
train_it = datagen.flow_from_directory('/srv/satnogs/data/train/', class_mode='binary')
|
||||||
val_it = datagen.flow_from_directory('data/val/', class_mode='binary')
|
val_it = datagen.flow_from_directory('/srv/satnogs/data/val/', class_mode='binary')
|
||||||
test_it = datagen.flow_from_directory('data/test/', class_mode='binary')
|
test_it = datagen.flow_from_directory('/srv/satnogs/data/test/', class_mode='binary')
|
||||||
batchX, batchy = train_it.next()
|
batchX, batchy = train_it.next()
|
||||||
print('Batch shape=%s, min=%.3f, max=%.3f' % (batchX.shape, batchX.min(), batchX.max()))
|
print('Batch shape=%s, min=%.3f, max=%.3f' % (batchX.shape, batchX.min(), batchX.max()))
|
||||||
img_width=256
|
img_width=256
|
||||||
|
|
2
wut-obs
2
wut-obs
|
@ -7,7 +7,7 @@
|
||||||
# Download Observation: JSON. Not waterfall, audio, or data files.
|
# Download Observation: JSON. Not waterfall, audio, or data files.
|
||||||
|
|
||||||
APIURL="https://network.satnogs.org/api"
|
APIURL="https://network.satnogs.org/api"
|
||||||
DOWNDIR="download"
|
DOWNDIR="/srv/satnogs/download"
|
||||||
|
|
||||||
cd $DOWNDIR || exit
|
cd $DOWNDIR || exit
|
||||||
|
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# wut-review-staging
|
# wut-review-staging
|
||||||
# Go through all the images in data/staging and review them.
|
# Go through all the images in data/staging and review them.
|
||||||
cd data/staging || exit
|
cd /srv/satnogs/data/staging || exit
|
||||||
for i in *.png
|
for i in *.png
|
||||||
do echo $i
|
do echo $i
|
||||||
rm ../test/unvetted/*.png
|
rm ../test/unvetted/*.png
|
||||||
|
|
|
@ -22,7 +22,7 @@ KEEP=100
|
||||||
# this is so bad no one should ever run it again
|
# this is so bad no one should ever run it again
|
||||||
#exit 0
|
#exit 0
|
||||||
# XXX Delete data in this directory! XXX
|
# XXX Delete data in this directory! XXX
|
||||||
cd data/test/unvetted/ || exit
|
cd /srv/satnogs/data/test/unvetted/ || exit
|
||||||
|
|
||||||
TOTALFILES=`ls waterfall_*.png | wc -l`
|
TOTALFILES=`ls waterfall_*.png | wc -l`
|
||||||
for wf in waterfall_*.png
|
for wf in waterfall_*.png
|
||||||
|
|
|
@ -7,7 +7,7 @@
|
||||||
# Download Observation: JSON and waterfall. Not audio or data files.
|
# Download Observation: JSON and waterfall. Not audio or data files.
|
||||||
|
|
||||||
APIURL="https://network.satnogs.org/api"
|
APIURL="https://network.satnogs.org/api"
|
||||||
DOWNDIR="download"
|
DOWNDIR="/srv/satnogs/download"
|
||||||
|
|
||||||
cd $DOWNDIR || exit
|
cd $DOWNDIR || exit
|
||||||
|
|
||||||
|
|
|
@ -21,7 +21,7 @@
|
||||||
# XXX Should check input is sane...
|
# XXX Should check input is sane...
|
||||||
|
|
||||||
APIURL="https://network.satnogs.org/api"
|
APIURL="https://network.satnogs.org/api"
|
||||||
DOWNDIR="download"
|
DOWNDIR="/srv/satnogs/download"
|
||||||
OBSIDMIN="$1"
|
OBSIDMIN="$1"
|
||||||
OBSIDMAX="$2"
|
OBSIDMAX="$2"
|
||||||
OBSID=$OBSIDMIN
|
OBSID=$OBSIDMIN
|
||||||
|
|
|
@ -52,8 +52,8 @@ NUM_WORKERS = 6
|
||||||
GLOBAL_BATCH_SIZE = 64 * NUM_WORKERS
|
GLOBAL_BATCH_SIZE = 64 * NUM_WORKERS
|
||||||
|
|
||||||
# XXX
|
# XXX
|
||||||
POSITIVE_DIRECTORY = '/home/jebba/devel/spacecruft/satnogs-wut/data/pos'
|
POSITIVE_DIRECTORY = '/srv/satnogs/data/pos'
|
||||||
pos_dir = '/home/jebba/devel/spacecruft/satnogs-wut/data/posdir'
|
pos_dir = '/srv/satnogs/data/posdir'
|
||||||
|
|
||||||
strategy = tf.distribute.experimental.MultiWorkerMirroredStrategy(
|
strategy = tf.distribute.experimental.MultiWorkerMirroredStrategy(
|
||||||
tf.distribute.experimental.CollectiveCommunication.RING)
|
tf.distribute.experimental.CollectiveCommunication.RING)
|
||||||
|
@ -92,7 +92,7 @@ def process_image(image_bytes, label):
|
||||||
|
|
||||||
AUTOTUNE = tf.data.experimental.AUTOTUNE
|
AUTOTUNE = tf.data.experimental.AUTOTUNE
|
||||||
NUM_TOTAL_IMAGES=100
|
NUM_TOTAL_IMAGES=100
|
||||||
data_root = "/home/jebba/devel/spacecruft/satnogs-wut/data"
|
data_root = "/srv/satnogs/data"
|
||||||
profile_dir = os.path.join(data_root, "profiles")
|
profile_dir = os.path.join(data_root, "profiles")
|
||||||
dataset = tf.data.Dataset.list_files(data_root)
|
dataset = tf.data.Dataset.list_files(data_root)
|
||||||
dataset = dataset.shuffle(NUM_TOTAL_IMAGES)
|
dataset = dataset.shuffle(NUM_TOTAL_IMAGES)
|
||||||
|
@ -174,8 +174,8 @@ def handle_batching():
|
||||||
yield concat(batch)
|
yield concat(batch)
|
||||||
batch.reset()
|
batch.reset()
|
||||||
|
|
||||||
train_dir = os.path.join('data/', 'train')
|
train_dir = os.path.join('/srv/satnogs/data/', 'train')
|
||||||
val_dir = os.path.join('data/', 'val')
|
val_dir = os.path.join('/srv/satnogs/data/', 'val')
|
||||||
train_good_dir = os.path.join(train_dir, 'good')
|
train_good_dir = os.path.join(train_dir, 'good')
|
||||||
train_bad_dir = os.path.join(train_dir, 'bad')
|
train_bad_dir = os.path.join(train_dir, 'bad')
|
||||||
val_good_dir = os.path.join(val_dir, 'good')
|
val_good_dir = os.path.join(val_dir, 'good')
|
||||||
|
|
Loading…
Reference in New Issue