Next tuesday 25th january around 21.30 we'll be upgrading to GitLab version 14.7

Commit a7b26b32 authored by Kruyff,D.L.W. (Dylan)'s avatar Kruyff,D.L.W. (Dylan)
Browse files

Slight tweaking for reasonable results

parent 6903c44c
......@@ -17,9 +17,9 @@ export class CacheService {
private _sliderValue;
private _queryWindow;
public windowSize = 500;
public nrOfTables = 10;
public hashSize = 5;
public windowSize = 120;
public nrOfTables = 50;
public hashSize = 4;
public stepSize = 200;
public querySelectionMode = true;
......
......@@ -6,6 +6,7 @@
.subplot-container {
display: flex;
flex-wrap: wrap;
overflow-x: scroll;
width: 95%;
}
......
......@@ -91,7 +91,7 @@ export class LabelingWindowComponent implements OnInit {
pad: 4
},
height: 150,
width: 150,
width: 300,
titlefont: {
size: 9
},
......
......@@ -172,7 +172,7 @@ export class OverviewWindowComponent implements OnInit {
x: clickData.x,
y: clickData.y
});
const index = Math.floor(xyInformation[0].scalenumvalue / (12000 / 6));
const index = 80503// Math.floor(xyInformation[0].scalenumvalue / (12000 / 6));
this.service.queryWindow = await this.service.getQueryWindow(index);
const temp = {};
temp[index] = true;
......
......@@ -102,7 +102,7 @@ export class ProgressViewComponent implements OnInit {
showticklabels: false,
},
height: 300,
width: 200,
width: 300,
sliders: [{
active: highest,
pad: {t: 30},
......
......@@ -39,7 +39,7 @@ export class QueryWindowComponent implements OnInit {
pad: 4
},
height: 150,
width: 150,
width: 350,
titlefont: {
size: 9
},
......
......@@ -20,20 +20,13 @@
</component>
<component name="ChangeListManager">
<list default="true" id="556080ba-825c-4b55-a92a-867a4df4fb32" name="Default Changelist" comment="">
<change afterPath="$PROJECT_DIR$/bigwig.py" afterDir="false" />
<change afterPath="$PROJECT_DIR$/test.bigWig" afterDir="false" />
<change afterPath="$PROJECT_DIR$/utils.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/../AngularApp/prototype/src/app/api.service.ts" beforeDir="false" afterPath="$PROJECT_DIR$/../AngularApp/prototype/src/app/api.service.ts" afterDir="false" />
<change beforePath="$PROJECT_DIR$/../AngularApp/prototype/src/app/cache.service.ts" beforeDir="false" afterPath="$PROJECT_DIR$/../AngularApp/prototype/src/app/cache.service.ts" afterDir="false" />
<change beforePath="$PROJECT_DIR$/../AngularApp/prototype/src/app/labeling-window/labeling-window.component.ts" beforeDir="false" afterPath="$PROJECT_DIR$/../AngularApp/prototype/src/app/labeling-window/labeling-window.component.ts" afterDir="false" />
<change beforePath="$PROJECT_DIR$/../AngularApp/prototype/src/app/overview-window/overview-window.component.html" beforeDir="false" afterPath="$PROJECT_DIR$/../AngularApp/prototype/src/app/overview-window/overview-window.component.html" afterDir="false" />
<change beforePath="$PROJECT_DIR$/../AngularApp/prototype/src/app/overview-window/overview-window.component.ts" beforeDir="false" afterPath="$PROJECT_DIR$/../AngularApp/prototype/src/app/overview-window/overview-window.component.ts" afterDir="false" />
<change beforePath="$PROJECT_DIR$/../AngularApp/prototype/src/app/progress-view/progress-view.component.ts" beforeDir="false" afterPath="$PROJECT_DIR$/../AngularApp/prototype/src/app/progress-view/progress-view.component.ts" afterDir="false" />
<change beforePath="$PROJECT_DIR$/.idea/misc.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/misc.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/main.py" beforeDir="false" afterPath="$PROJECT_DIR$/main.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/processed-data.npy" beforeDir="false" afterPath="$PROJECT_DIR$/processed-data.npy" afterDir="false" />
<change beforePath="$PROJECT_DIR$/../run-flask-server.bat" beforeDir="false" afterPath="$PROJECT_DIR$/../run-flask-server.bat" afterDir="false" />
</list>
<option name="SHOW_DIALOG" value="false" />
<option name="HIGHLIGHT_CONFLICTS" value="true" />
......
......@@ -23,6 +23,7 @@ def index():
@app.route('/read-data', methods=['GET'])
def read_data():
t0 = time()
size = bbi.chromsizes('test.bigWig')['chr1']
bins = 100000
data = bigwig.get('test.bigWig', 'chr1', 0, size, bins)
......@@ -32,10 +33,12 @@ def read_data():
"values": data.tolist()
}
response = orjson.dumps(response)
print('Data read: ' + str(time()-t0))
return response
@app.route('/create-windows', methods=['POST'])
def create_windows():
t0 = time()
if reload:
size = bbi.chromsizes('test.bigWig')['chr1']
raw_data = request.json
......@@ -50,6 +53,7 @@ def create_windows():
)
print(data.shape)
np.save('processed-data', data)
print('Windows created: ' + str(time()-t0))
return '1'
@app.route('/create-tables', methods=['POST'])
......@@ -57,6 +61,7 @@ def create_tables():
t0 = time()
print("loading")
data = np.load('processed-data.npy')
print('Number of tables: ' + str(data.shape))
print(time()-t0)
raw_data = orjson.loads(request.data)
print(time()-t0)
......@@ -65,7 +70,7 @@ def create_tables():
table_size = int(raw_data['parameters']["tablesize"])
data = np.array(data)
print('Starting: ' + str(time()-t0))
tables_hash_function = [np.random.uniform(-1, 1, size=(window_size, hash_size)) for _ in range(table_size)]
tables_hash_function = [np.random.uniform(-100, 100, size=(window_size, hash_size)) for _ in range(table_size)]
print('Init time: ' + str(time() - t0))
tables = []
for index in range(table_size):
......@@ -112,7 +117,6 @@ def window():
indices = raw_data['indices']
output = np.load('processed-data.npy')[indices]
response = orjson.dumps(output.tolist())
print(output)
print("Query done: " + str(time() - t0))
return response
......
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