Skip to content
Snippets Groups Projects
Commit 84931541 authored by Remi  PLANEL's avatar Remi PLANEL
Browse files

add pvc for structure data

parent 9c241d08
No related branches found
No related tags found
1 merge request!134Resolve "Table with all PDB files, to make them available to download"
Pipeline #118291 passed with stages
in 7 minutes and 12 seconds
......@@ -104,9 +104,20 @@ const selectedPaePath = computed(() => {
const paeData = ref([])
watch(selectedPaePath, async (newPaePath) => {
if (newPaePath !== null) {
const data = await d3.tsv(newPaePath);
// console.log(data)
paeData.value = data
try {
const data = await d3.tsv(newPaePath);
console.log(data.length)
if (data.length > 500) {
paeData.value = []
}
else {
paeData.value = data
}
}
catch (error) {
console.log(error)
}
} else {
paeData.value = []
}
......@@ -116,9 +127,11 @@ watch(selectedPaePath, async (newPaePath) => {
const sanitizedPaeData = computed(() => {
return paeData.value.reduce((acc, curr, index) => {
const scoredResidue = index
// let newAcc = [...acc]
for (const [alignedResidue, value] of Object.entries(curr)) {
// console.log(value)
acc.push({ alignedResidue: parseInt(alignedResidue), scoredResidue: parseInt(scoredResidue), value: parseFloat(value) })
// newAcc = [...newAcc, ...[{ alignedResidue: parseInt(alignedResidue), scoredResidue: parseInt(scoredResidue), value: parseFloat(value) }]]
}
return acc
......@@ -188,8 +201,9 @@ watch(selectedPdb, (selectedPdb, prevSelectPdb) => {
custom-data-format="cif"></pdbe-molstar>
</v-sheet>
</v-col>
<v-col v-if="sanitizedPaeData?.length > 0">
<PlotFigure defer :options="plotPaeOptions"></PlotFigure>
<v-col >
<PlotFigure v-if="sanitizedPaeData?.length > 0" defer :options="plotPaeOptions"></PlotFigure>
<v-alert type="warning">The PAE is to large</v-alert>
<v-card flat color="transparent">
<v-card-title>Model Confidence</v-card-title>
......
......@@ -43,6 +43,11 @@ function pdbNameToCif(pdbPath: string) {
return `${cifPath}.cif`
}
function toSystemName(rawName: string) {
return rawName.split(/_|-0/)[0].toLocaleLowerCase()
}
</script>
<template>
<ServerDbTable title="Predicted Structures" db="structure" :sortBy="sortBy" :facets="facets"
......@@ -58,7 +63,7 @@ function pdbNameToCif(pdbPath: string) {
<td :colspan="columns.length">
<v-card flat color="transparent">
<v-card-text>
<MolstarPdbePlugin :data-urls="[`/${item.system.toLowerCase()}/${pdbNameToCif(item.pdb)}`]">
<MolstarPdbePlugin :data-urls="[`/${toSystemName(item.system)}/${pdbNameToCif(item.pdb)}`]">
</MolstarPdbePlugin>
</v-card-text>
</v-card>
......
......@@ -54,6 +54,8 @@ spec:
name: tmp
- name: nginx-config
mountPath: /etc/nginx/conf.d/
- name: structure-data-pvc
mountPath: /structure-data
{{- with .Values.nodeSelector }}
......@@ -74,4 +76,6 @@ spec:
- name: nginx-config
configMap:
name: nginx-config
- name: structure-data-pvc
persistentVolumeClaim:
claimName: structure-data-pvc
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: structure-data-pvc
spec:
accessModes:
- ReadWriteMany
resources:
requests:
storage: 40Gi
storageClassName: isilon
volumeMode: Filesystem
\ No newline at end of file
......@@ -105,7 +105,7 @@ def structure(
for f in dir.iterdir():
console.print(f"[green] {f.name}")
# get the system name
system = re.split("_|\.", f.name)[0].lower()
system = re.split("_|\.|-0", f.name)[0].lower()
console.print(system)
systemDir = output / system
......
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