Commit 0855e7d5 authored by Yuncong Yu's avatar Yuncong Yu
Browse files

Sort the directory structure.

parent aea9dde7
......@@ -7,8 +7,10 @@ __pycache__
*.pyd
*.pyo
*.obj
201207_IAVHeKu_212-SM-9221_WMA4ID41_DS18_TestV_10_EU5FM_800m_0C_freie_Fahrt_nrm_01.h5
201207_IAVHeKu_212-SM-9221_WMA4ID41_DS18_TestV_10_EU5FM_800m_0C_freie_Fahrt_nrm_01_compressed.h5
Angu:arApp/prototype/node_modules
clion-log.txt
Documents/
Flaskserver/venv/*
clion-log.txt
tmp.py
<?xml version="1.0" encoding="UTF-8"?>
<module type="WEB_MODULE" version="4">
<component name="NewModuleRootManager">
<content url="file://$MODULE_DIR$" />
<orderEntry type="inheritedJdk" />
<orderEntry type="sourceFolder" forTests="false" />
</component>
</module>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ProjectModuleManager">
<modules>
<module fileurl="file://$PROJECT_DIR$/.idea/AngularApp.iml" filepath="$PROJECT_DIR$/.idea/AngularApp.iml" />
</modules>
</component>
</project>
\ No newline at end of file
install:
conda env create -f ./environment.yml
server:
cd Flaskserver && export FLASK_APP=main.py && export FLASK_ENV=development && export FLASK_DEBUG=1 && flask run
cd backend && export FLASK_APP=src/main.py && export FLASK_ENV=development && export FLASK_DEBUG=1 && flask run
gui:
cd AngularApp && cd prototype && ng serve --open
ui:
cd frontend && ng serve --open
# Default ignored files
/shelf/
/workspace.xml
# Datasource local storage ignored files
/dataSources/
/dataSources.local.xml
# Editor-based HTTP Client requests
/httpRequests/
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="JavaScriptSettings">
<option name="languageLevel" value="ES6" />
</component>
</project>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="VcsDirectoryMappings">
<mapping directory="$PROJECT_DIR$/.." vcs="Git" />
</component>
</project>
\ No newline at end of file
import logging
import os
from pathlib import Path
from time import time, perf_counter
from typing import Any, Dict, List
from typing import Dict, List
import numpy as np
import orjson
from flask import Flask, request
from flask_cors import CORS
import preprocessing
import pseudo
from src import preprocessing
from src import pseudo
# Config
......
......@@ -15,17 +15,17 @@ logging.basicConfig(level=logging.INFO)
data_path = "data/processed-data.npy"
def read_data():
size = bbi.chromsizes("test.bigWig")["chr1"]
bins = 100000
data = bigwig.get("data/test.bigWig", "chr1", 0, size, bins)
print(data.shape)
response = [
{"index": list(range(0, size, int(size / (bins)))), "values": data.tolist()},
{"index": list(range(0, size, int(size / (bins)))), "values": data.tolist()},
{"index": list(range(0, size, int(size / (bins)))), "values": data.tolist()},
]
return response
# def read_data():
# size = bbi.chromsizes("test.bigWig")["chr1"]
# bins = 100000
# data = bigwig.get("data/test.bigWig", "chr1", 0, size, bins)
# print(data.shape)
# response = [
# {"index": list(range(0, size, int(size / (bins)))), "values": data.tolist()},
# {"index": list(range(0, size, int(size / (bins)))), "values": data.tolist()},
# {"index": list(range(0, size, int(size / (bins)))), "values": data.tolist()},
# ]
# return response
def create_peax_windows_12kb(window_size):
......@@ -97,7 +97,7 @@ def read_eeg_data(nr_of_channels):
def read_weather_data():
filename = "data/weather.pkl"
filename = "../data/weather.pkl"
if not os.path.isfile(filename):
print("start")
df = dd.read_csv("data/NW_Ground_Stations_2016.csv", usecols=["number_sta", "date", "t", "hu", "td", "dd", "ff", "psl", "precip"])
......@@ -152,7 +152,7 @@ def read_weather_data():
def create_weather_windows(window_size):
if not os.path.isfile("data/weather-" + str(window_size) + ".npy"):
filename = "data/weather.pkl"
filename = "../data/weather.pkl"
df = pd.read_pickle(filename)
channels = list()
channels.append(df.loc[df["number_sta"] == 14137001].loc[:, "t"].fillna(0).values.tolist())
......
......@@ -269,7 +269,7 @@ def query(data, window_indices):
def debug_test_lsh():
data = np.load('data/processed-data.npy')
data = np.load('../data/processed-data.npy')
# data = np.repeat(data, repeats=7, axis=1)
print(data.shape)
data = np.reshape(data, (len(data), len(data[0][0]), len(data[0])))
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment