Skip to content

Commit

Permalink
bump deps, add a few function headers
Browse files Browse the repository at this point in the history
  • Loading branch information
exaexa committed Jan 16, 2024
1 parent 27aa282 commit 277455a
Show file tree
Hide file tree
Showing 12 changed files with 187 additions and 6 deletions.
2 changes: 1 addition & 1 deletion Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ StableRNGs = "860ef19b-820b-49d6-a774-d7a799459cd3"
AbstractFBCModels = "0.2.2"
Aqua = "0.7"
Clarabel = "0.6"
ConstraintTrees = "0.9.1"
ConstraintTrees = "0.9.2"
DistributedData = "0.2"
DocStringExtensions = "0.8, 0.9"
Downloads = "1"
Expand Down
17 changes: 14 additions & 3 deletions src/COBREXA.jl
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ using DocStringExtensions

import AbstractFBCModels as A
import ConstraintTrees as C
import Distributed as D
import JuMP as J
import LinearAlgebra
import SparseArrays
Expand All @@ -50,6 +51,12 @@ include("config.jl")
include("io.jl")
include("solver.jl")

# generic analysis functions
include("analysis/envelope.jl")
include("analysis/sample.jl")
include("analysis/screen.jl")
include("analysis/variability.jl")

# conversion of various stuff to constraint trees
include("builders/communities.jl")
include("builders/enzymes.jl")
Expand All @@ -63,11 +70,15 @@ include("builders/unsigned.jl")

# simplified front-ends for the above
include("frontend/balance.jl")
include("frontend/parsimonious.jl")
include("frontend/envelope.jl")
include("frontend/enzymes.jl")
include("frontend/knockout.jl")
include("frontend/loopless.jl")
include("frontend/mmdf.jl")
include("frontend/moma.jl")
include("frontend/loopless.jl")
include("frontend/enzyme_constrained.jl")
include("frontend/parsimonious.jl")
include("frontend/sample.jl")
include("frontend/variability.jl")

# utilities
include("misc/bounds.jl")
Expand Down
19 changes: 19 additions & 0 deletions src/analysis/envelope.jl
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@

# Copyright (c) 2021-2024, University of Luxembourg
# Copyright (c) 2021-2024, Heinrich-Heine University Duesseldorf
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

function constraints_objective_envelope(constraints::C.ConstraintTree, grid::Array{C.ConstraintTreeElem}, objective::C.Value; workers = D.workers())
#TODO
end
21 changes: 21 additions & 0 deletions src/analysis/sample.jl
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@

# Copyright (c) 2021-2024, University of Luxembourg
# Copyright (c) 2021-2024, Heinrich-Heine University Duesseldorf
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

function sample_achr(constraints::C.ConstraintTree, points::Matrix{Float64}; seed, chains, collect_iterations, epsilon, filter_constraints::C.ConstraintTree, workers=D.workers())
end

function sample_affine_hr(constraints::C.ConstraintTree, points::Matrix{Float64}; seed, chains, collect_iterations, epsilon, mix_points, filter_constraints::C.ConstraintTree, workers=D.workers())
end
27 changes: 27 additions & 0 deletions src/analysis/screen.jl
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@

# Copyright (c) 2021-2024, University of Luxembourg
# Copyright (c) 2021-2024, Heinrich-Heine University Duesseldorf
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

function screen(f, model::A.AbstractFBCModel; args::Array{Tuple} = [()], workers=D.workers(), kwargs...)
# TODO might belong to the frontend
end

function screen(f, constraints::C.ConstraintTree; args::Array{Tuple} = [()], workers=D.workers())
# TODO
end

function screen_optimization_model(f, constraints::C.ConstraintTree, args::Maybe{Array}, workers=D.workers())
# TODO
end
19 changes: 19 additions & 0 deletions src/analysis/variability.jl
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@

# Copyright (c) 2021-2024, University of Luxembourg
# Copyright (c) 2021-2024, Heinrich-Heine University Duesseldorf
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

function constraints_variability(constraints::C.ConstraintTree, targets::C.ConstraintTree; workers = D.workers()) :: C.Tree{Tuple{Maybe{Float64}, Maybe{Float64}}}
#TODO
end
5 changes: 4 additions & 1 deletion src/builders/communities.jl
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,10 @@ as `:module_name => (module, module.interface)`; the second tuple member may
also be specified just by name as e.g. `:interface`, or omitted while relying
on `default_interface`).
Compatible modules with interfaces may be created e.g. by
Interface parts get merged and constrained to create a new interface; networks
are intact with disjoint variable sets.
Compatible modules with ready-made interfaces may be created e.g. by
[`flux_balance_constraints`](@ref).
"""
function join_module_constraints(
Expand Down
19 changes: 19 additions & 0 deletions src/frontend/envelope.jl
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@

# Copyright (c) 2021-2024, University of Luxembourg
# Copyright (c) 2021-2024, Heinrich-Heine University Duesseldorf
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

function objective_production_envelope(model::A.AbstractFBCModel, dimensions; optimizer, kwargs...)
#TODO
end
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
$(TYPEDEF)
A simple struct storing information about the isozyme composition, including
subunit stoichiometry and turnover numbers.
subunit stoichiometry and turnover numbers. Use with
[`enzyme_constrained_flux_balance_analysis`](@ref).
# Fields
$(TYPEDFIELDS)
Expand Down
19 changes: 19 additions & 0 deletions src/frontend/knockout.jl
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@

# Copyright (c) 2021-2024, University of Luxembourg
# Copyright (c) 2021-2024, Heinrich-Heine University Duesseldorf
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

function gene_knockouts(model::A.AbstractFBCModel, genes, n; kwargs...)
# TODO just use screen to do this right
end
23 changes: 23 additions & 0 deletions src/frontend/sample.jl
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@

# Copyright (c) 2021-2024, University of Luxembourg
# Copyright (c) 2021-2024, Heinrich-Heine University Duesseldorf
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

function flux_sampling_achr(model::A.AbstractFBCModel; optimizer, kwargs...)
#TODO
end

function flux_sampling_affine_hr(model::A.AbstractFBCModel; optimizer, kwargs...)
#TODO probably share a lot of the frontend with the above thing
end
19 changes: 19 additions & 0 deletions src/frontend/variability.jl
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@

# Copyright (c) 2021-2024, University of Luxembourg
# Copyright (c) 2021-2024, Heinrich-Heine University Duesseldorf
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

function flux_variability_analysis(model::A.AbstractFBCModel; optimizer, kwargs...)
#TODO
end

0 comments on commit 277455a

Please sign in to comment.