Skip to content

Commit 2ea03e2

Browse files
committed
Changes to @antgonza comments
1 parent 2cb3f37 commit 2ea03e2

File tree

5 files changed

+18
-18
lines changed

5 files changed

+18
-18
lines changed

qiita_db/support_files/patches/93.sql

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -62,11 +62,3 @@ CREATE INDEX IF NOT EXISTS processing_job_command_parameters_payload ON qiita.pr
6262
-- Addding contraints for the slurm_reservation column
6363
ALTER TABLE qiita.analysis DROP CONSTRAINT IF EXISTS analysis_slurm_reservation_valid_chars;
6464
ALTER TABLE qiita.analysis ADD CONSTRAINT analysis_slurm_reservation_valid_chars CHECK ( slurm_reservation ~ '^[a-zA-Z0-9_]*$' );
65-
66-
-- Jan 7, 2025
67-
-- Adding a table for formulas for resource allocations
68-
CREATE TABLE qiita.allocation_equations (
69-
equation_id SERIAL PRIMARY KEY,
70-
equation_name TEXT NOT NULL,
71-
expression TEXT NOT NULL
72-
);

qiita_db/support_files/patches/94.sql

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
-- Jan 13, 2025
2+
-- Adding a table for formulas for resource allocations
3+
CREATE TABLE qiita.allocation_equations (
4+
equation_id SERIAL PRIMARY KEY,
5+
equation_name TEXT NOT NULL,
6+
expression TEXT NOT NULL
7+
);

qiita_db/support_files/patches/test_db_sql/93.sql

Lines changed: 0 additions & 10 deletions
This file was deleted.
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
INSERT INTO qiita.allocation_equations(equation_name, expression)
2+
VALUES
3+
('mem_model1', '(k * (log(x))) + (x * a) + b'),
4+
('mem_model2', '(k * (log(x))) + (b * ((log(x))**2)) + a'),
5+
('mem_model3', '(k * (log(x))) + (b * ((log(x))**2)) + (a * ((log(x))**3))'),
6+
('mem_model4', '(k * (log(x))) + (b * ((log(x))**2)) + (a * ((log(x))**2.5))'),
7+
('time_model1', 'a + b + ((log(x)) * k)'),
8+
('time_model2', 'a + (b * x) + ((log(x)) * k)'),
9+
('time_model3', 'a + (b * ((log(x))**2)) + ((log(x)) * k)'),
10+
('time_model4', '(a * ((log(x))**3)) + (b * ((log(x))**2)) + ((log(x)) * k)');

qiita_db/util.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,7 @@
7676
import matplotlib.pyplot as plt
7777
from matplotlib import colormaps
7878
import numpy as np
79+
from numpy import log
7980
import pandas as pd
8081
from io import StringIO
8182
from json import loads

0 commit comments

Comments
 (0)