Exemple #1
0
from datetime import datetime, timedelta
sys.path.insert(0, '..')

from noveltyDetectionConfig import CONFIG
import numpy as np
import itertools
import multiprocessing
import pprint

from SAENoveltyDetectionAnalysis import SAENoveltyDetectionAnalysis

num_processes = multiprocessing.cpu_count()

from Functions.telegrambot import Bot

my_bot = Bot("lisa_thebot")

# Enviroment variables
data_path = CONFIG['OUTPUTDATAPATH']
results_path = CONFIG['PACKAGE_NAME']

training_params = {
    "Technique": "StackedAutoEncoder",
    "TechniqueParameters": {
        "allow_change_weights": False  #False
    },
    "DevelopmentMode": False,
    "DevelopmentEvents": 400,
    "NoveltyDetection": True,
    "InputDataConfig": {
        "database": "4classes",
Exemple #2
0
gpu_id = args.gpu_id

tf.get_logger().setLevel(logging.ERROR)

tf.debugging.set_log_device_placement(False)

gpus = tf.config.experimental.list_physical_devices('GPU')

print("Num GPUs Available: ", len(gpus))

if gpus:
    tf.config.experimental.set_visible_devices(gpus[gpu_id], f'GPU')

num_processes = multiprocessing.cpu_count()

my_bot = Bot("lisa_thebot")

# Enviroment variables
data_path = CONFIG['OUTPUTDATAPATH']
results_path = CONFIG['PACKAGE_NAME']


def main(training_params: dict):
    analysis = VAENoveltyDetectionAnalysis(parameters=training_params,
                                           load_hash=False,
                                           load_data=True,
                                           verbose=True)
    all_data, all_trgt, trgt_sparse = analysis.getData()

    analysis.emulate_novelties()
    analysis.build_vae_models()
Exemple #3
0
import os
import time
import multiprocessing
import pprint

from datetime import datetime, timedelta
import numpy as np
import matplotlib.pyplot as plt

from Packages.NoveltyDetection.setup.noveltyDetectionConfig import CONFIG
from Packages.NoveltyDetection.StackedAutoEncoders.SAENoveltyDetectionAnalysis import SAENoveltyDetectionAnalysis
from Functions.telegrambot import Bot

num_processes = multiprocessing.cpu_count()

my_bot = Bot("lisa_thebot")

# Enviroment variables
data_path = CONFIG['OUTPUTDATAPATH']
results_path = CONFIG['PACKAGE_NAME']

training_params = {"Technique": "StackedAutoEncoder"}
analysis = SAENoveltyDetectionAnalysis(
    parameters=training_params,
    #                                        model_hash='3aa7b6b2a784922c348292561edca3d5201d6d6567f727e6ce7e403d7f175b10',
    #                                        model_hash="048afa2017b8b40203db1ef3f94e806a4d9772fe14b032a479f96f9551853574",
    #                                        model_hash='5fee10c0e061666bbd9b5ad4544503a562deb56f25bd5f80b9f2c8ca3bf76b81', # PF linear no decoder
    model_hash=
    'f84a0f006d8a19e5c3dbe25d4907659013495f79bb8b377e88673a899d9e2a2d',  # PF tanh no decoder
    load_hash=True,
    load_data=True,