Fix cython declarations and some optimizations in molecule.py#2960
Conversation
I asked Codex (GPT 5.5) to find similar fixes to the ones I just implemented. Then checked them manually.
JacksonBurns
left a comment
There was a problem hiding this comment.
Looks broadly good. Will leave this as a comment rather than an approval in case you want to add more to it, but please consider this my approval of the current changes.
| required parameters. The available actions can be found | ||
| :ref:`here <reaction-recipe-actions>`. | ||
| """ | ||
| cython.declare(act=str, i=cython.Py_ssize_t, n=cython.Py_ssize_t) |
There was a problem hiding this comment.
I don't really know what Py_ssize_t is but I assume it is a special type for generators (like the outputs from range here... so I will just trust you on it.
| elif act == 'GAIN_RADICAL': | ||
| for i in range(action[2]): self.increment_radical() | ||
| n = action[2] | ||
| for i in range(n): self.increment_radical() | ||
| elif act == 'LOSE_RADICAL': | ||
| for i in range(abs(action[2])): self.decrement_radical() | ||
| n = action[2] | ||
| for i in range(n): self.decrement_radical() | ||
| elif act == 'GAIN_CHARGE': | ||
| for i in range(action[2]): self.increment_charge() | ||
| n = action[2] | ||
| for i in range(n): self.increment_charge() | ||
| elif act == 'LOSE_CHARGE': | ||
| for i in range(abs(action[2])): self.decrement_charge() | ||
| elif action[0].upper() == 'GAIN_PAIR': | ||
| for i in range(action[2]): self.increment_lone_pairs() | ||
| elif action[0].upper() == 'LOSE_PAIR': | ||
| for i in range(abs(action[2])): self.decrement_lone_pairs() | ||
| n = action[2] | ||
| for i in range(n): self.decrement_charge() | ||
| elif act == 'GAIN_PAIR': | ||
| n = action[2] | ||
| for i in range(n): self.increment_lone_pairs() | ||
| elif act == 'LOSE_PAIR': | ||
| n = action[2] | ||
| for i in range(n): self.decrement_lone_pairs() |
There was a problem hiding this comment.
Can we just consolidate n = action[2] to before the first if statement?
There was a problem hiding this comment.
I thought of that. Yes, it would be less code to read, but actually more code to execute, so I left it the ugly way.
Regression Testing Results
Detailed regression test results.Regression test aromatics:Reference: Execution time (DD:HH:MM:SS): 00:00:00:41 aromatics Passed Core Comparison ✅Original model has 15 species. aromatics Failed Edge Comparison ❌Original model has 106 species. Non-identical thermo! ❌
thermo: Thermo group additivity estimation: group(Cs-(Cds-Cds)CsCsH) + group(Cs-(Cds-Cds)CsCsH) + group(Cs-(Cds-Cds)(Cds-Cds)CsH) + group(Cs-(Cds-Cds)CsHH) + group(Cds-CdsCsCs) + group(Cds-CdsCsH) + group(Cds-CdsCsH) + group(Cds-CdsCsH) + polycyclic(s2_4_5_diene_1_5) + polycyclic(s3_4_5_ene_3) + polycyclic(s3_5_5_ene_1) - ring(Cyclobutene) - ring(Cyclopentene) - ring(Cyclopentane) + radical(cyclopentene-allyl) Non-identical thermo! ❌
thermo: Thermo group additivity estimation: group(Cs-(Cds-Cds)CsCsH) + group(Cs-(Cds-Cds)(Cds-Cds)CsH) + group(Cs-(Cds-Cds)(Cds-Cds)CsH) + group(Cs-CsCsHH) + group(Cds-CdsCsCs) + group(Cds-CdsCsH) + group(Cds-CdsCsH) + group(Cds-CdsCsH) + Estimated bicyclic component: polycyclic(s2_3_5_ane) - ring(Cyclopentane) - ring(Cyclopropane) + ring(Cyclopentene) + ring(Cyclopropane) + polycyclic(s2_3_6_ene_1) + polycyclic(s3_5_6_diene_1_5) - ring(Cyclopropane) - ring(Cyclopentene) - ring(Cyclohexene) + radical(cyclopentene-4) Non-identical thermo! ❌
thermo: Thermo group additivity estimation: group(Cs-(Cds-Cds)(Cds-Cds)CsCs) + group(Cs-(Cds-Cds)CsCsH) + group(Cs-(Cds-Cds)CsCsH) + group(Cs-CsCsHH) + group(Cds-CdsCsH) + group(Cds-CdsCsH) + group(Cds-CdsCsH) + group(Cds-CdsCsH) + polycyclic(s2_4_4_ene_1) + polycyclic(s2_4_5_diene_1_5) + polycyclic(s3_4_5_ene_1) - ring(Cyclobutene) - ring(Cyclobutane) - ring(Cyclopentene) + radical(bicyclo[2.1.1]hex-2-ene-C5) Non-identical thermo! ❌
thermo: Thermo group additivity estimation: group(Cs-CsCsCsH) + group(Cs-(Cds-Cds)CsCsH) + group(Cs-(Cds-Cds)CsCsH) + group(Cs-(Cds-Cds)CsHH) + group(Cds- Cds(Cds-Cds)Cs) + group(Cds-CdsCsH) + group(Cds-CdsCsH) + group(Cds-Cds(Cds-Cds)H) + polycyclic(s2_3_5_ene_1) + polycyclic(s2_3_6_diene_1_3) + Estimated bicyclic component: polycyclic(s3_5_6_ane) - ring(Cyclohexane) - ring(Cyclopentane) + ring(1,3-Cyclohexadiene) + ring(Cyclopentene) - ring(Cyclopropane) - ring(Cyclopentene) - ring(1,3-Cyclohexadiene) + radical(cyclopentene-allyl) Non-identical thermo! ❌
thermo: Thermo group additivity estimation: group(Cs-(Cds-Cds)(Cds-Cds)(Cds-Cds)H) + group(Cds-Cds(Cds-Cds)(Cds-Cds)) + group(Cds-CdsCsH) + group(Cds-CdsCsH) + group(Cds-Cds(Cds-Cds)H) + group(Cds-Cds(Cds-Cds)H) + group(Cds-CdsCsH) + group(Cdd-CdsCds) + Estimated bicyclic component: polycyclic(s4_6_6_ane) - ring(Cyclohexane) - ring(Cyclohexane) + ring(1,4-Cyclohexadiene) + ring(124cyclohexatriene) Non-identical thermo! ❌
thermo: Thermo group additivity estimation: group(Cs-(Cds-Cds)CsCsH) + group(Cs-(Cds-Cds)CsCsH) + group(Cs-(Cds-Cds)CsCsH) + group(Cs-CsCsHH) + group(Cds- Cds(Cds-Cds)Cs) + group(Cds-CdsCsH) + group(Cds-CdsCsH) + group(Cds-Cds(Cds-Cds)H) + polycyclic(s2_4_4_ene_1) + polycyclic(s3_4_6_diene_1_5) + polycyclic(s3_4_6_ene_1) - ring(Cyclobutene) - ring(Cyclobutane) - ring(Cyclohexene) + radical(cyclobutane) Non-identical kinetics! ❌
kinetics: Non-identical kinetics! ❌
kinetics: Non-identical kinetics! ❌
kinetics: Non-identical kinetics! ❌
kinetics: Non-identical kinetics! ❌
kinetics: Non-identical kinetics! ❌
kinetics: Non-identical kinetics! ❌
kinetics: Non-identical kinetics! ❌
kinetics: Non-identical kinetics! ❌
kinetics: Non-identical kinetics! ❌
kinetics: Non-identical kinetics! ❌
kinetics: Non-identical kinetics! ❌
kinetics: Non-identical kinetics! ❌
kinetics: Non-identical kinetics! ❌
kinetics: Non-identical kinetics! ❌
kinetics: Non-identical kinetics! ❌
kinetics: Non-identical kinetics! ❌
kinetics: Non-identical kinetics! ❌
kinetics: Non-identical kinetics! ❌
kinetics: Errors occurred during edge comparison
ERROR conda.cli.main_run:execute(148): `conda run python scripts/checkModels.py aromatics-edge stable_regression_results/aromatics/chemkin/chem_edge_annotated.inp stable_regression_results/aromatics/chemkin/species_edge_dictionary.txt test/regression/aromatics/chemkin/chem_edge_annotated.inp test/regression/aromatics/chemkin/species_edge_dictionary.txt` failed. (See above for error)
|
| k(1bar) | 300K | 400K | 500K | 600K | 800K | 1000K | 1500K | 2000K |
|---|---|---|---|---|---|---|---|---|
| k(T): | 3.54 | 4.28 | 4.73 | 5.02 | 5.39 | 5.62 | 5.91 | 6.06 |
| k(T): | 8.02 | 7.64 | 7.35 | 7.11 | 6.75 | 6.48 | 5.99 | 5.64 |
kinetics: Arrhenius(A=(3.2e+12,'cm^3/(mol*s)'), n=0, Ea=(4.064,'kcal/mol'), T0=(1,'K'), comment="""Estimated from node Root_Ext-5R-R_7R!H->C_N-7C-inRing_Ext-5R-R in family Peroxyl_Disproportionation.""")
kinetics: Arrhenius(A=(3.18266e+20,'cm^3/(mol*s)'), n=-2.694, Ea=(-0.265,'kcal/mol'), T0=(1,'K'), comment="""Estimated from node Root_Ext-5R-R_7R!H->C_N-7C-inRing in family Peroxyl_Disproportionation.""")
kinetics: Estimated from node Root_Ext-5R-R_7R!H->C_N-7C-inRing_Ext-5R-R in family Peroxyl_Disproportionation.
kinetics: Estimated from node Root_Ext-5R-R_7R!H->C_N-7C-inRing in family Peroxyl_Disproportionation.
Errors occurred during edge comparison ⚠️
ERROR conda.cli.main_run:execute(148): `conda run python scripts/checkModels.py liquid_oxidation-edge stable_regression_results/liquid_oxidation/chemkin/chem_edge_annotated.inp stable_regression_results/liquid_oxidation/chemkin/species_edge_dictionary.txt test/regression/liquid_oxidation/chemkin/chem_edge_annotated.inp test/regression/liquid_oxidation/chemkin/species_edge_dictionary.txt` failed. (See above for error)
Details
Observables Test Case: liquid_oxidation Comparison✅ All Observables varied by less than 0.100 on average between old model and new model in all conditions!
liquid_oxidation Passed Observable Testing ✅
Errors occurred during observable testing ⚠️
INFO:root:Reading input file "/home/runner/work/RMG-Py/RMG-Py/test/regression/liquid_oxidation/regression_input.py"...
INFO:root:options(
title='liquid_oxidation',
tolerance=0.1
)
observable(
label='pentane',
structure=SMILES('CCCCC')
)
species(
label='oxygen',
structure=SMILES('[O][O]'),
)
reactorSetups(
reactorTypes=['IdealGasReactor'],
terminationTimes=([1e3], 's'),
initialMoleFractionsList=[{
'pentane': 0.9,
'oxygen': 0.1,
}],
temperatures=([600], 'K'),
pressures=([1.0], 'bar'),
)
INFO:root:Thermo file has default temperature range 300.0 to 1000.0 and 1000.0 to 5000.0
INFO:root:Thermo file has default temperature range 300.0 to 1000.0 and 1000.0 to 5000.0
Regression test nitrogen:
Reference: Execution time (DD:HH:MM:SS): 00:00:00:45
Current: Execution time (DD:HH:MM:SS): 00:00:00:55
Reference: Memory used: 911.28 MB
Current: Memory used: 909.17 MB
nitrogen Passed Core Comparison ✅
Original model has 41 species.
Test model has 41 species. ✅
Original model has 359 reactions.
Test model has 359 reactions. ✅
nitrogen Passed Edge Comparison ✅
Original model has 133 species.
Test model has 133 species. ✅
Original model has 981 reactions.
Test model has 981 reactions. ✅
Details
Observables Test Case: NC Comparison✅ All Observables varied by less than 0.200 on average between old model and new model in all conditions!
nitrogen Passed Observable Testing ✅
Errors occurred during observable testing ⚠️
INFO:root:Reading input file "/home/runner/work/RMG-Py/RMG-Py/test/regression/nitrogen/regression_input.py"...
INFO:root:
options(
title='NC',
tolerance=0.2
)
observable(
label='NC',
structure=SMILES("NC"),
)
observable(
label='OH',
structure=SMILES("[OH]"),
)
species(
label='O2',
structure=SMILES("[O][O]"),
)
species(
label='Ar',
structure=adjacencyList('1 Ar u0 p4 c0'),
)
reactorSetups(
reactorTypes=['IdealGasReactor'],
terminationTimes=([0.002],'s'),
initialMoleFractionsList=[{
"NC": 0.0005,
"O2": 0.002,
"Ar": 0.9975,
}],
temperatures=([1500],'K'),
pressures=([1.],'atm'),
)
INFO:root:Thermo file has default temperature range 300.0 to 1000.0 and 1000.0 to 5000.0
INFO:root:Thermo file has default temperature range 300.0 to 1000.0 and 1000.0 to 5000.0
Regression test oxidation:
Reference: Execution time (DD:HH:MM:SS): 00:00:01:11
Current: Execution time (DD:HH:MM:SS): 00:00:01:31
Reference: Memory used: 790.72 MB
Current: Memory used: 791.05 MB
oxidation Passed Core Comparison ✅
Original model has 59 species.
Test model has 59 species. ✅
Original model has 694 reactions.
Test model has 694 reactions. ✅
oxidation Passed Edge Comparison ✅
Original model has 230 species.
Test model has 230 species. ✅
Original model has 1524 reactions.
Test model has 1524 reactions. ✅
Details
Observables Test Case: Oxidation Comparison✅ All Observables varied by less than 0.500 on average between old model and new model in all conditions!
oxidation Passed Observable Testing ✅
Errors occurred during observable testing ⚠️
INFO:root:Reading input file "/home/runner/work/RMG-Py/RMG-Py/test/regression/oxidation/regression_input.py"...
INFO:root:options(
title = 'Oxidation',
tolerance = 0.5,
)
observables
observable(
label = 'OH',
structure=SMILES('[OH]'),
)
species definition used in the reactor setup specification
species(
label = 'OH',
structure=SMILES('[OH]'),
)
species(
label = 'N2',
structure=SMILES("N#N"),
)
species(
label = 'O2',
structure=SMILES('[O][O]'),
)
species(
label = 'propane',
structure=SMILES('CCC'),
)
reactor setups
reactorSetups(
reactorTypes=['IdealGasReactor'],
terminationTimes=([100.0],'s'),
initialMoleFractionsList=[{
"propane": 2.0/7.0,
"O2": 1.0,
"N2":4.0,
}],
temperatures=([725.0],'K'),
pressures=([10.0],'bar'),
)
INFO:root:Thermo file has default temperature range 300.0 to 1000.0 and 1000.0 to 5000.0
INFO:root:Thermo file has default temperature range 300.0 to 1000.0 and 1000.0 to 5000.0
WARNING:root:Initial mole fractions do not sum to one; normalizing.
INFO:root:
INFO:root:Original composition:
INFO:root:propane = 0.2857142857142857
INFO:root:O2 = 1.0
INFO:root:N2 = 4.0
INFO:root:
INFO:root:Normalized mole fractions:
INFO:root:propane = 0.05405405405405405
INFO:root:O2 = 0.1891891891891892
INFO:root:N2 = 0.7567567567567568
INFO:root:
Regression test sulfur:
Reference: Execution time (DD:HH:MM:SS): 00:00:00:31
Current: Execution time (DD:HH:MM:SS): 00:00:00:36
Reference: Memory used: 908.11 MB
Current: Memory used: 906.38 MB
sulfur Passed Core Comparison ✅
Original model has 27 species.
Test model has 27 species. ✅
Original model has 74 reactions.
Test model has 74 reactions. ✅
sulfur Failed Edge Comparison ❌
Original model has 89 species.
Test model has 89 species. ✅
Original model has 227 reactions.
Test model has 227 reactions. ✅
The original model has 1 reactions that the tested model does not have. ❌
rxn: O(4) + SO2(15) (+N2) <=> SO3(16) (+N2) origin: primarySulfurLibrary
The tested model has 1 reactions that the original model does not have. ❌
rxn: O(4) + SO2(15) (+N2) <=> SO3(16) (+N2) origin: primarySulfurLibrary
Errors occurred during edge comparison ⚠️
ERROR conda.cli.main_run:execute(148): `conda run python scripts/checkModels.py sulfur-edge stable_regression_results/sulfur/chemkin/chem_edge_annotated.inp stable_regression_results/sulfur/chemkin/species_edge_dictionary.txt test/regression/sulfur/chemkin/chem_edge_annotated.inp test/regression/sulfur/chemkin/species_edge_dictionary.txt` failed. (See above for error)
Details
Observables Test Case: SO2 Comparison✅ All Observables varied by less than 0.100 on average between old model and new model in all conditions!
sulfur Passed Observable Testing ✅
Errors occurred during observable testing ⚠️
INFO:root:Reading input file "/home/runner/work/RMG-Py/RMG-Py/test/regression/sulfur/regression_input.py"...
INFO:root:
options(
title='SO2',
tolerance=0.1
)
observable(
label='SO2',
structure=SMILES("O=S=O"),
)
species(
label='H2S',
structure=SMILES("S"),
)
species(
label='O2',
structure=SMILES("[O][O]"),
)
species(
label='N2',
structure=SMILES("N#N"),
)
reactorSetups(
reactorTypes=['IdealGasReactor'],
terminationTimes=([0.01],'s'),
initialMoleFractionsList=[{
"H2S": 0.000756,
"O2": 0.001290,
"N2": 0.997954}],
temperatures=([900],'K'),
pressures=([30.],'bar'),
)
INFO:root:Thermo file has default temperature range 300.0 to 1000.0 and 1000.0 to 5000.0
INFO:root:Thermo file has default temperature range 300.0 to 1000.0 and 1000.0 to 5000.0
Regression test superminimal:
Reference: Execution time (DD:HH:MM:SS): 00:00:00:17
Current: Execution time (DD:HH:MM:SS): 00:00:00:22
Reference: Memory used: 974.49 MB
Current: Memory used: 967.25 MB
superminimal Passed Core Comparison ✅
Original model has 13 species.
Test model has 13 species. ✅
Original model has 21 reactions.
Test model has 21 reactions. ✅
superminimal Passed Edge Comparison ✅
Original model has 18 species.
Test model has 18 species. ✅
Original model has 28 reactions.
Test model has 28 reactions. ✅
Regression test RMS_constantVIdealGasReactor_superminimal:
Reference: Execution time (DD:HH:MM:SS): 00:00:02:19
Current: Execution time (DD:HH:MM:SS): 00:00:02:01
Reference: Memory used: 2437.50 MB
Current: Memory used: 2379.94 MB
RMS_constantVIdealGasReactor_superminimal Passed Core Comparison ✅
Original model has 13 species.
Test model has 13 species. ✅
Original model has 19 reactions.
Test model has 19 reactions. ✅
RMS_constantVIdealGasReactor_superminimal Passed Edge Comparison ✅
Original model has 13 species.
Test model has 13 species. ✅
Original model has 19 reactions.
Test model has 19 reactions. ✅
Details
Observables Test Case: RMS_constantVIdealGasReactor_superminimal Comparison✅ All Observables varied by less than 0.100 on average between old model and new model in all conditions!
RMS_constantVIdealGasReactor_superminimal Passed Observable Testing ✅
Errors occurred during observable testing ⚠️
INFO:root:Reading input file "/home/runner/work/RMG-Py/RMG-Py/test/regression/RMS_constantVIdealGasReactor_superminimal/regression_input.py"...
INFO:root:
options(
title='RMS_constantVIdealGasReactor_superminimal',
tolerance=0.1
)
observable(
label='H2',
structure=SMILES("[H][H]"),
)
observable(
label='O2',
structure=SMILES("[O][O]"),
)
reactorSetups(
reactorTypes=['IdealGasReactor'],
terminationTimes=([0.01],'s'),
initialMoleFractionsList=[{
'H2':.67,
'O2':.33,
}],
temperatures=([1000],'K'),
pressures=([1.0],'bar'),
)
INFO:root:Thermo file has default temperature range 300.0 to 1000.0 and 1000.0 to 5000.0
INFO:root:Thermo file has default temperature range 300.0 to 1000.0 and 1000.0 to 5000.0
Regression test RMS_CSTR_liquid_oxidation:
Reference: Execution time (DD:HH:MM:SS): 00:00:10:38
Current: Execution time (DD:HH:MM:SS): 00:00:08:06
Reference: Memory used: 2597.80 MB
Current: Memory used: 3340.02 MB
RMS_CSTR_liquid_oxidation Failed Core Comparison ❌
Original model has 35 species.
Test model has 35 species. ✅
Original model has 128 reactions.
Test model has 119 reactions. ❌
The original model has 5 species that the tested model does not have. ❌
spc: CH3
spc: C=CC(18)
spc: CC[CH]C(C)OO(32)
spc: [CH2]C(CCC)OO(33)
spc: C[CH]C(CC)OO(37)
The tested model has 5 species that the original model does not have. ❌
spc: CCCCCO
spc: CC1CC(C)O1(87)
spc: CC=CC(C)OO(88)
spc: C=CCC(C)OO(89)
spc: CC(CC(C)OO)OO
The original model has 32 reactions that the tested model does not have. ❌
rxn: C[CH]C(CC)OO(37) <=> CCC(CC)O[O](22) origin: intra_H_migration
rxn: [O]O(13) + C[CH]C(CC)OO(37) <=> oxygen(1) + CCC(CC)OO(27) origin: H_Abstraction
rxn: OO(23) + C[CH]C(CC)OO(37) <=> [O]O(13) + CCC(CC)OO(27) origin: H_Abstraction
rxn: C[CH]C(CC)OO(37) + pentane(2) <=> C[CH]CCC(11) + CCC(CC)OO(27) origin: H_Abstraction
rxn: C[CH]C(CC)OO(37) + pentane(2) <=> CC[CH]CC(7) + CCC(CC)OO(27) origin: H_Abstraction
rxn: C[CH]C(CC)OO(37) + CCCC(C)OO(26) <=> CCCC(C)O[O](21) + CCC(CC)OO(27) origin: H_Abstraction
rxn: C[CH]C(CC)OO(37) + CCC(CC)OO(27) <=> CCC(CC)O[O](22) + CCC(CC)OO(27) origin: H_Abstraction
rxn: [CH2]CCCC(12) + CCC(CC)OO(27) <=> C[CH]C(CC)OO(37) + pentane(2) origin: H_Abstraction
rxn: [CH2]CCCC(12) + C[CH]C(CC)OO(37) <=> C=CCCC(17) + CCC(CC)OO(27) origin: Disproportionation
rxn: C[CH]CCC(11) + C[CH]C(CC)OO(37) <=> C=CCCC(17) + CCC(CC)OO(27) origin: Disproportionation
rxn: CC[CH]C(C)OO(32) <=> CCCC(C)O[O](21) origin: intra_H_migration
rxn: [O]O(13) + CC[CH]C(C)OO(32) <=> oxygen(1) + CCCC(C)OO(26) origin: H_Abstraction
rxn: OO(23) + CC[CH]C(C)OO(32) <=> [O]O(13) + CCCC(C)OO(26) origin: H_Abstraction
rxn: CC[CH]C(C)OO(32) + pentane(2) <=> C[CH]CCC(11) + CCCC(C)OO(26) origin: H_Abstraction
rxn: CC[CH]C(C)OO(32) + pentane(2) <=> CC[CH]CC(7) + CCCC(C)OO(26) origin: H_Abstraction
rxn: CC[CH]C(C)OO(32) + CCCC(C)OO(26) <=> CCCC(C)O[O](21) + CCCC(C)OO(26) origin: H_Abstraction
rxn: CC[CH]C(C)OO(32) + CCC(CC)OO(27) <=> CCC(CC)O[O](22) + CCCC(C)OO(26) origin: H_Abstraction
rxn: [CH2]CCCC(12) + CCCC(C)OO(26) <=> CC[CH]C(C)OO(32) + pentane(2) origin: H_Abstraction
rxn: [CH2]CCCC(12) + CC[CH]C(C)OO(32) <=> C=CCCC(17) + CCCC(C)OO(26) origin: Disproportionation
rxn: C[CH]CCC(11) + CC[CH]C(C)OO(32) <=> C=CCCC(17) + CCCC(C)OO(26) origin: Disproportionation
rxn: C[CH]CCC(11) <=> C[CH2](6) + C=CC(18) origin: R_Addition_MultipleBond
rxn: CCCC(C)O[O](21) <=> [CH2]C(CCC)OO(33) origin: intra_H_migration
rxn: [O]O(13) + [CH2]C(CCC)OO(33) <=> oxygen(1) + CCCC(C)OO(26) origin: H_Abstraction
rxn: OO(23) + [CH2]C(CCC)OO(33) <=> [O]O(13) + CCCC(C)OO(26) origin: H_Abstraction
rxn: [CH2]C(CCC)OO(33) + pentane(2) <=> C[CH]CCC(11) + CCCC(C)OO(26) origin: H_Abstraction
rxn: [CH2]C(CCC)OO(33) + pentane(2) <=> CC[CH]CC(7) + CCCC(C)OO(26) origin: H_Abstraction
rxn: [CH2]C(CCC)OO(33) + CCCC(C)OO(26) <=> CCCC(C)O[O](21) + CCCC(C)OO(26) origin: H_Abstraction
rxn: [CH2]C(CCC)OO(33) + CCC(CC)OO(27) <=> CCC(CC)O[O](22) + CCCC(C)OO(26) origin: H_Abstraction
rxn: [CH2]C(CCC)OO(33) + pentane(2) <=> [CH2]CCCC(12) + CCCC(C)OO(26) origin: H_Abstraction
rxn: [O]O(13) + C=CCCC(17) <=> [CH2]C(CCC)OO(33) origin: R_Addition_MultipleBond
rxn: [CH2]CCCC(12) + [CH2]C(CCC)OO(33) <=> C=CCCC(17) + CCCC(C)OO(26) origin: Disproportionation
rxn: C[CH]CCC(11) + [CH2]C(CCC)OO(33) <=> C=CCCC(17) + CCCC(C)OO(26) origin: Disproportionation
The tested model has 23 reactions that the original model does not have. ❌
rxn: CCCC(C)O[O](21) + CCCCCOO(78) <=> CCCCCO[O](61) + CCCC(C)OO(25) origin: H_Abstraction
rxn: CCC(CC)O[O](20) + CCCCCOO(78) <=> CCCCCO[O](61) + CCC(CC)OO(24) origin: H_Abstraction
rxn: C[CH]CC(C)OO(37) + CCCCCOO(78) <=> CCCCCO[O](61) + CCCC(C)OO(25) origin: H_Abstraction
rxn: [O]O(13) + [CH2]CCCC(12) <=> CCCCCOO(78) origin: R_Recombination
rxn: [OH](26) + [OH](26) <=> OO(23) origin: R_Recombination
rxn: [O]O(13) + CCCCCO[O](61) <=> oxygen(1) + CCCCCOO(78) origin: H_Abstraction
rxn: oxygen(1) + H2O(42) <=> [OH](26) + [O]O(13) origin: H_Abstraction
rxn: OO(23) + CCCC(C)OO(25) <=> [OH](26) + H2O(42) + CCCC(C)O[O](21) origin: Bimolec_Hydroperoxide_Decomposition
rxn: oxygen(1) + C[CH]CC(C)OO(37) <=> CC(CC(C)OO)O[O](91) origin: R_Recombination
rxn: CCCC(C)OO(25) + CCCCCOO(78) <=> H2O(42) + CCCC(C)[O](44) + CCCCCO[O](61) origin: Bimolec_Hydroperoxide_Decomposition
rxn: OO(23) + CCCC(C)OO(25) <=> [O]O(13) + H2O(42) + CCCC(C)[O](44) origin: Bimolec_Hydroperoxide_Decomposition
rxn: [CH2]CC(CC)OO(32) + CCCCCOO(78) <=> CCCCCO[O](61) + CCC(CC)OO(24) origin: H_Abstraction
rxn: oxygen(1) + C[CH]CC(C)OO(37) <=> [O]O(13) + CC=CC(C)OO(88) origin: Disproportionation
rxn: [O]O(13) + C[CH]CCCOO(75) <=> oxygen(1) + CCCCCOO(78) origin: H_Abstraction
rxn: [OH](26) + CCCCC[O](79) <=> CCCCCOO(78) origin: R_Recombination
rxn: CCCC(C)OO(25) + CCCCCOO(78) <=> H2O(42) + CCCCC[O](79) + CCCC(C)O[O](21) origin: Bimolec_Hydroperoxide_Decomposition
rxn: CCC(CC)OO(24) + CCCCCOO(78) <=> H2O(42) + CCCCC[O](79) + CCC(CC)O[O](20) origin: Bimolec_Hydroperoxide_Decomposition
rxn: CCCCCOO(78) + CCCCCOO(78) <=> H2O(42) + CCCCC[O](79) + CCCCCO[O](61) origin: Bimolec_Hydroperoxide_Decomposition
rxn: CCC(CC)OO(24) + CCCCCOO(78) <=> H2O(42) + CCC([O])CC(41) + CCCCCO[O](61) origin: Bimolec_Hydroperoxide_Decomposition
rxn: C[CH]CC(C)OO(37) <=> [OH](26) + CC1CC(C)O1(87) origin: Cyclic_Ether_Formation
rxn: oxygen(1) + C[CH]CC(C)OO(37) <=> [O]O(13) + C=CCC(C)OO(89) origin: Disproportionation
rxn: [O]O(13) + [CH2]CCCCOO(76) <=> oxygen(1) + CCCCCOO(78) origin: H_Abstraction
rxn: [O]O(13) + CC[CH]CCOO(74) <=> oxygen(1) + CCCCCOO(78) origin: H_Abstraction
Errors occurred during core comparison ⚠️
ERROR conda.cli.main_run:execute(148): `conda run python scripts/checkModels.py RMS_CSTR_liquid_oxidation-core stable_regression_results/RMS_CSTR_liquid_oxidation/chemkin/chem_annotated.inp stable_regression_results/RMS_CSTR_liquid_oxidation/chemkin/species_dictionary.txt test/regression/RMS_CSTR_liquid_oxidation/chemkin/chem_annotated.inp test/regression/RMS_CSTR_liquid_oxidation/chemkin/species_dictionary.txt` failed. (See above for error)
RMS_CSTR_liquid_oxidation Failed Edge Comparison ❌
Original model has 77 species.
Test model has 90 species. ❌
Original model has 244 reactions.
Test model has 309 reactions. ❌
The tested model has 13 species that the original model does not have. ❌
spc: CCCCCO
spc: [CH2]COO(80)
spc: [CH2]CCOO(81)
spc: [CH2]OO(82)
spc: [CH2]CCCOO(83)
spc: CCCC[CH]OO(84)
spc: C[CH]CCOO(85)
spc: [CH2]C(C)C(C)OO(86)
spc: CC1CC(C)O1(87)
spc: CC=CC(C)OO(88)
spc: C=CCC(C)OO(89)
spc: CC([O])CC(C)O(90)
spc: CC(CC(C)OO)OO
The tested model has 65 reactions that the original model does not have. ❌
rxn: CCCC(C)O[O](21) + CCCCCOO(78) <=> CCCCCO[O](61) + CCCC(C)OO(25) origin: H_Abstraction
rxn: CCC(CC)O[O](20) + CCCCCOO(78) <=> CCCCCO[O](61) + CCC(CC)OO(24) origin: H_Abstraction
rxn: C[CH]CC(C)OO(37) + CCCCCOO(78) <=> CCCCCO[O](61) + CCCC(C)OO(25) origin: H_Abstraction
rxn: [O]O(13) + [CH2]CCCC(12) <=> CCCCCOO(78) origin: R_Recombination
rxn: [OH](26) + [OH](26) <=> OO(23) origin: R_Recombination
rxn: [O]O(13) + CCCCCO[O](61) <=> oxygen(1) + CCCCCOO(78) origin: H_Abstraction
rxn: oxygen(1) + H2O(42) <=> [OH](26) + [O]O(13) origin: H_Abstraction
rxn: OO(23) + CCCC(C)OO(25) <=> [OH](26) + H2O(42) + CCCC(C)O[O](21) origin: Bimolec_Hydroperoxide_Decomposition
rxn: oxygen(1) + C[CH]CC(C)OO(37) <=> CC(CC(C)OO)O[O](91) origin: R_Recombination
rxn: CCCC(C)OO(25) + CCCCCOO(78) <=> H2O(42) + CCCC(C)[O](44) + CCCCCO[O](61) origin: Bimolec_Hydroperoxide_Decomposition
rxn: OO(23) + CCCC(C)OO(25) <=> [O]O(13) + H2O(42) + CCCC(C)[O](44) origin: Bimolec_Hydroperoxide_Decomposition
rxn: [CH2]CC(CC)OO(32) + CCCCCOO(78) <=> CCCCCO[O](61) + CCC(CC)OO(24) origin: H_Abstraction
rxn: oxygen(1) + C[CH]CC(C)OO(37) <=> [O]O(13) + CC=CC(C)OO(88) origin: Disproportionation
rxn: [O]O(13) + C[CH]CCCOO(75) <=> oxygen(1) + CCCCCOO(78) origin: H_Abstraction
rxn: [OH](26) + CCCCC[O](79) <=> CCCCCOO(78) origin: R_Recombination
rxn: CCCC(C)OO(25) + CCCCCOO(78) <=> H2O(42) + CCCCC[O](79) + CCCC(C)O[O](21) origin: Bimolec_Hydroperoxide_Decomposition
rxn: CCC(CC)OO(24) + CCCCCOO(78) <=> H2O(42) + CCCCC[O](79) + CCC(CC)O[O](20) origin: Bimolec_Hydroperoxide_Decomposition
rxn: CCCCCOO(78) + CCCCCOO(78) <=> H2O(42) + CCCCC[O](79) + CCCCCO[O](61) origin: Bimolec_Hydroperoxide_Decomposition
rxn: CCC(CC)OO(24) + CCCCCOO(78) <=> H2O(42) + CCC([O])CC(41) + CCCCCO[O](61) origin: Bimolec_Hydroperoxide_Decomposition
rxn: C[CH]CC(C)OO(37) <=> [OH](26) + CC1CC(C)O1(87) origin: Cyclic_Ether_Formation
rxn: oxygen(1) + C[CH]CC(C)OO(37) <=> [O]O(13) + C=CCC(C)OO(89) origin: Disproportionation
rxn: [O]O(13) + [CH2]CCCCOO(76) <=> oxygen(1) + CCCCCOO(78) origin: H_Abstraction
rxn: [O]O(13) + CC[CH]CCOO(74) <=> oxygen(1) + CCCCCOO(78) origin: H_Abstraction
rxn: CCC[C](C)OO(54) + CCCCCOO(78) <=> CCCCCO[O](61) + CCCC(C)OO(25) origin: H_Abstraction
rxn: CC[CH]C(C)OO(35) + CCCCCOO(78) <=> CCCCCO[O](61) + CCCC(C)OO(25) origin: H_Abstraction
rxn: [CH2]C(CCC)OO(36) + CCCCCOO(78) <=> CCCCCO[O](61) + CCCC(C)OO(25) origin: H_Abstraction
rxn: [CH2]CCC(C)OO(38) + CCCCCOO(78) <=> CCCCCO[O](61) + CCCC(C)OO(25) origin: H_Abstraction
rxn: CC[C](CC)OO(59) + CCCCCOO(78) <=> CCCCCO[O](61) + CCC(CC)OO(24) origin: H_Abstraction
rxn: C[CH]C(CC)OO(31) + CCCCCOO(78) <=> CCCCCO[O](61) + CCC(CC)OO(24) origin: H_Abstraction
rxn: C=CC[CH]C(64) + [CH2]CCCC(12) <=> C=CCCC(18) + C=CCCC(18) origin: Disproportionation
rxn: C=CC[CH]C(64) + C[CH]CCC(11) <=> C=CCCC(18) + C=CCCC(18) origin: Disproportionation
rxn: [CH2]C=CCC(66) + [CH2]CCCC(12) <=> C=CCCC(18) + C=CCCC(18) origin: Disproportionation
rxn: [CH2]C=CCC(66) + C[CH]CCC(11) <=> C=CCCC(18) + C=CCCC(18) origin: Disproportionation
rxn: [CH2]CCC=C(67) + [CH2]CCCC(12) <=> C=CCCC(18) + C=CCCC(18) origin: Disproportionation
rxn: [CH2]CCC=C(67) + C[CH]CCC(11) <=> C=CCCC(18) + C=CCCC(18) origin: Disproportionation
rxn: C=[C]CCC(68) + [CH2]CCCC(12) <=> C=CCCC(18) + C=CCCC(18) origin: Disproportionation
rxn: C=[C]CCC(68) + C[CH]CCC(11) <=> C=CCCC(18) + C=CCCC(18) origin: Disproportionation
rxn: [CH]=CCCC(69) + [CH2]CCCC(12) <=> C=CCCC(18) + C=CCCC(18) origin: Disproportionation
rxn: [CH]=CCCC(69) + C[CH]CCC(11) <=> C=CCCC(18) + C=CCCC(18) origin: Disproportionation
rxn: CH2(S)(3) + CCCCOO(50) <=> CCCCCOO(78) origin: 1,2_Insertion_carbene
rxn: CH2(S)(3) + CCCCOO(50) <=> CCCCCOO(78) origin: 1,2_Insertion_carbene
rxn: H(8) + CCCCCO[O](61) <=> CCCCCOO(78) origin: R_Recombination
rxn: [CH2]COO(80) + [CH2]CC(5) <=> CCCCCOO(78) origin: R_Recombination
rxn: C[CH2](6) + [CH2]CCOO(81) <=> CCCCCOO(78) origin: R_Recombination
rxn: H(8) + CC[CH]CCOO(74) <=> CCCCCOO(78) origin: R_Recombination
rxn: [CH2]OO(82) + [CH2]CCC(9) <=> CCCCCOO(78) origin: R_Recombination
rxn: H(8) + CCC[CH]COO(73) <=> CCCCCOO(78) origin: R_Recombination
rxn: [CH3](10) + [CH2]CCCOO(83) <=> CCCCCOO(78) origin: R_Recombination
rxn: H(8) + C[CH]CCCOO(75) <=> CCCCCOO(78) origin: R_Recombination
rxn: H(8) + CCCC[CH]OO(84) <=> CCCCCOO(78) origin: R_Recombination
rxn: H(8) + [CH2]CCCCOO(76) <=> CCCCCOO(78) origin: R_Recombination
rxn: H(8) + [O]O(13) <=> OO(23) origin: R_Recombination
rxn: CH2(S)(3) + C[CH]CCOO(85) <=> C[CH]CC(C)OO(37) origin: 1,2_Insertion_carbene
rxn: [CH2]C(C)C(C)OO(86) <=> C[CH]CC(C)OO(37) origin: 1,2_shiftC
rxn: H(8) + CC=CC(C)OO(88) <=> C[CH]CC(C)OO(37) origin: R_Addition_MultipleBond
rxn: H(8) + C=CCC(C)OO(89) <=> C[CH]CC(C)OO(37) origin: R_Addition_MultipleBond
rxn: C[CH]OO(52) + C=CC(19) <=> C[CH]CC(C)OO(37) origin: R_Addition_MultipleBond
rxn: CC[CH]C(C)OO(35) <=> C[CH]CC(C)OO(37) origin: intra_H_migration
rxn: [CH2]CCC(C)OO(38) <=> C[CH]CC(C)OO(37) origin: intra_H_migration
rxn: C[CH]CC(C)OO(37) <=> CCC[C](C)OO(54) origin: intra_H_migration
rxn: C[CH]CC(C)OO(37) <=> [CH2]C(CCC)OO(36) origin: intra_H_migration
rxn: C[CH]CC(C)OO(37) <=> CC([O])CC(C)O(90) origin: intra_OH_migration
rxn: H(8) + [OH](26) <=> H2O(42) origin: R_Recombination
rxn: [O]O(13) + CCC[CH]COO(73) <=> oxygen(1) + CCCCCOO(78) origin: H_Abstraction
rxn: [O]O(13) + CCCC[CH]OO(84) <=> oxygen(1) + CCCCCOO(78) origin: H_Abstraction
Errors occurred during edge comparison ⚠️
ERROR conda.cli.main_run:execute(148): `conda run python scripts/checkModels.py RMS_CSTR_liquid_oxidation-edge stable_regression_results/RMS_CSTR_liquid_oxidation/chemkin/chem_edge_annotated.inp stable_regression_results/RMS_CSTR_liquid_oxidation/chemkin/species_edge_dictionary.txt test/regression/RMS_CSTR_liquid_oxidation/chemkin/chem_edge_annotated.inp test/regression/RMS_CSTR_liquid_oxidation/chemkin/species_edge_dictionary.txt` failed. (See above for error)
Details
Observables Test Case: RMS_CSTR_liquid_oxidation Comparison✅ All Observables varied by less than 0.100 on average between old model and new model in all conditions!
RMS_CSTR_liquid_oxidation Passed Observable Testing ✅
Errors occurred during observable testing ⚠️
INFO:root:Reading input file "/home/runner/work/RMG-Py/RMG-Py/test/regression/RMS_CSTR_liquid_oxidation/regression_input.py"...
INFO:root:options(
title='RMS_CSTR_liquid_oxidation',
tolerance=0.1
)
observable(
label='pentane',
structure=SMILES('CCCCC')
)
species(
label='oxygen',
structure=SMILES('[O][O]'),
)
reactorSetups(
reactorTypes=['IdealGasReactor'],
terminationTimes=([1e3], 's'),
initialMoleFractionsList=[{
'pentane': 0.9,
'oxygen': 0.1,
}],
temperatures=([600], 'K'),
pressures=([1.0], 'bar'),
)
INFO:root:Thermo file has default temperature range 300.0 to 1000.0 and 1000.0 to 5000.0
INFO:root:Thermo file has default temperature range 300.0 to 1000.0 and 1000.0 to 5000.0
Regression test fragment:
Reference: Execution time (DD:HH:MM:SS): 00:00:00:26
Current: Execution time (DD:HH:MM:SS): 00:00:00:30
Reference: Memory used: 753.48 MB
Current: Memory used: 752.77 MB
fragment Passed Core Comparison ✅
Original model has 10 species.
Test model has 10 species. ✅
Original model has 2 reactions.
Test model has 2 reactions. ✅
fragment Passed Edge Comparison ✅
Original model has 33 species.
Test model has 33 species. ✅
Original model has 47 reactions.
Test model has 47 reactions. ✅
Details
Observables Test Case: fragment Comparison✅ All Observables varied by less than 0.100 on average between old model and new model in all conditions!
fragment Passed Observable Testing ✅
Errors occurred during observable testing ⚠️
INFO:root:Reading input file "/home/runner/work/RMG-Py/RMG-Py/test/regression/fragment/regression_input.py"...
INFO:root:
options(
title='fragment',
tolerance=0.1
)
observable(
label="LCCCC",
structure=fragment_adj(
"""1 C u0 p0 c0 {2,S} {3,S} {5,S} {6,S}
2 C u0 p0 c0 {1,S} {4,S} {7,S} {8,S}
3 C u0 p0 c0 {1,S} {9,S} {10,S} {11,S}
4 C u0 p0 c0 {2,S} {12,S} {13,S} {14,S}
5 H u0 p0 c0 {1,S}
6 H u0 p0 c0 {1,S}
7 H u0 p0 c0 {2,S}
8 H u0 p0 c0 {2,S}
9 L u0 p0 c0 {3,S}
10 H u0 p0 c0 {3,S}
11 H u0 p0 c0 {3,S}
12 H u0 p0 c0 {4,S}
13 H u0 p0 c0 {4,S}
14 H u0 p0 c0 {4,S}
"""
),
)
species(
label="LCCCC",
structure=fragment_adj(
"""1 C u0 p0 c0 {2,S} {3,S} {5,S} {6,S}
2 C u0 p0 c0 {1,S} {4,S} {7,S} {8,S}
3 C u0 p0 c0 {1,S} {9,S} {10,S} {11,S}
4 C u0 p0 c0 {2,S} {12,S} {13,S} {14,S}
5 H u0 p0 c0 {1,S}
6 H u0 p0 c0 {1,S}
7 H u0 p0 c0 {2,S}
8 H u0 p0 c0 {2,S}
9 L u0 p0 c0 {3,S}
10 H u0 p0 c0 {3,S}
11 H u0 p0 c0 {3,S}
12 H u0 p0 c0 {4,S}
13 H u0 p0 c0 {4,S}
14 H u0 p0 c0 {4,S}
"""
),
)
species(
label="RCCCC",
structure=fragment_adj(
"""1 C u0 p0 c0 {2,S} {3,S} {5,S} {6,S}
2 C u0 p0 c0 {1,S} {4,S} {7,S} {8,S}
3 C u0 p0 c0 {1,S} {9,S} {10,S} {11,S}
4 C u0 p0 c0 {2,S} {12,S} {13,S} {14,S}
5 H u0 p0 c0 {1,S}
6 H u0 p0 c0 {1,S}
7 H u0 p0 c0 {2,S}
8 H u0 p0 c0 {2,S}
9 R u0 p0 c0 {3,S}
10 H u0 p0 c0 {3,S}
11 H u0 p0 c0 {3,S}
12 H u0 p0 c0 {4,S}
13 H u0 p0 c0 {4,S}
14 H u0 p0 c0 {4,S}
"""
),
)
reactorSetups(
reactorTypes=['IdealGasReactor'],
terminationTimes=([0.01],'s'),
initialMoleFractionsList=[{
"LCCCC": 1,
"RCCCC": 1,
}],
temperatures=([1600],'K'),
pressures=([40.0],'bar'),
)
INFO:root:Thermo file has default temperature range 300.0 to 1000.0 and 1000.0 to 5000.0
INFO:root:Thermo file has default temperature range 300.0 to 1000.0 and 1000.0 to 5000.0
WARNING:root:Initial mole fractions do not sum to one; normalizing.
INFO:root:
INFO:root:Original composition:
INFO:root:LCCCC = 1
INFO:root:RCCCC = 1
INFO:root:
INFO:root:Normalized mole fractions:
INFO:root:LCCCC = 0.5
INFO:root:RCCCC = 0.5
INFO:root:
Regression test RMS_constantVIdealGasReactor_fragment:
Reference: Execution time (DD:HH:MM:SS): 00:00:02:40
Current: Execution time (DD:HH:MM:SS): 00:00:02:24
Reference: Memory used: 2545.91 MB
Current: Memory used: 2555.15 MB
RMS_constantVIdealGasReactor_fragment Passed Core Comparison ✅
Original model has 10 species.
Test model has 10 species. ✅
Original model has 2 reactions.
Test model has 2 reactions. ✅
RMS_constantVIdealGasReactor_fragment Passed Edge Comparison ✅
Original model has 27 species.
Test model has 27 species. ✅
Original model has 24 reactions.
Test model has 24 reactions. ✅
Details
Observables Test Case: RMS_constantVIdealGasReactor_fragment Comparison✅ All Observables varied by less than 0.100 on average between old model and new model in all conditions!
RMS_constantVIdealGasReactor_fragment Passed Observable Testing ✅
Errors occurred during observable testing ⚠️
INFO:root:Reading input file "/home/runner/work/RMG-Py/RMG-Py/test/regression/RMS_constantVIdealGasReactor_fragment/regression_input.py"...
INFO:root:
options(
title='RMS_constantVIdealGasReactor_fragment',
tolerance=0.1
)
observable(
label="LCCCC",
structure=fragment_adj(
"""1 C u0 p0 c0 {2,S} {3,S} {5,S} {6,S}
2 C u0 p0 c0 {1,S} {4,S} {7,S} {8,S}
3 C u0 p0 c0 {1,S} {9,S} {10,S} {11,S}
4 C u0 p0 c0 {2,S} {12,S} {13,S} {14,S}
5 H u0 p0 c0 {1,S}
6 H u0 p0 c0 {1,S}
7 H u0 p0 c0 {2,S}
8 H u0 p0 c0 {2,S}
9 L u0 p0 c0 {3,S}
10 H u0 p0 c0 {3,S}
11 H u0 p0 c0 {3,S}
12 H u0 p0 c0 {4,S}
13 H u0 p0 c0 {4,S}
14 H u0 p0 c0 {4,S}
"""
),
)
species(
label="LCCCC",
structure=fragment_adj(
"""1 C u0 p0 c0 {2,S} {3,S} {5,S} {6,S}
2 C u0 p0 c0 {1,S} {4,S} {7,S} {8,S}
3 C u0 p0 c0 {1,S} {9,S} {10,S} {11,S}
4 C u0 p0 c0 {2,S} {12,S} {13,S} {14,S}
5 H u0 p0 c0 {1,S}
6 H u0 p0 c0 {1,S}
7 H u0 p0 c0 {2,S}
8 H u0 p0 c0 {2,S}
9 L u0 p0 c0 {3,S}
10 H u0 p0 c0 {3,S}
11 H u0 p0 c0 {3,S}
12 H u0 p0 c0 {4,S}
13 H u0 p0 c0 {4,S}
14 H u0 p0 c0 {4,S}
"""
),
)
species(
label="RCCCC",
structure=fragment_adj(
"""1 C u0 p0 c0 {2,S} {3,S} {5,S} {6,S}
2 C u0 p0 c0 {1,S} {4,S} {7,S} {8,S}
3 C u0 p0 c0 {1,S} {9,S} {10,S} {11,S}
4 C u0 p0 c0 {2,S} {12,S} {13,S} {14,S}
5 H u0 p0 c0 {1,S}
6 H u0 p0 c0 {1,S}
7 H u0 p0 c0 {2,S}
8 H u0 p0 c0 {2,S}
9 R u0 p0 c0 {3,S}
10 H u0 p0 c0 {3,S}
11 H u0 p0 c0 {3,S}
12 H u0 p0 c0 {4,S}
13 H u0 p0 c0 {4,S}
14 H u0 p0 c0 {4,S}
"""
),
)
reactorSetups(
reactorTypes=['IdealGasReactor'],
terminationTimes=([0.01],'s'),
initialMoleFractionsList=[{
"LCCCC": 1,
"RCCCC": 1,
}],
temperatures=([1600],'K'),
pressures=([40.0],'bar'),
)
INFO:root:Thermo file has default temperature range 300.0 to 1000.0 and 1000.0 to 5000.0
INFO:root:Thermo file has default temperature range 300.0 to 1000.0 and 1000.0 to 5000.0
WARNING:root:Initial mole fractions do not sum to one; normalizing.
INFO:root:
INFO:root:Original composition:
INFO:root:LCCCC = 1
INFO:root:RCCCC = 1
INFO:root:
INFO:root:Normalized mole fractions:
INFO:root:LCCCC = 0.5
INFO:root:RCCCC = 0.5
INFO:root:
Regression test minimal_surface:
Reference: Execution time (DD:HH:MM:SS): 00:00:00:24
Current: Execution time (DD:HH:MM:SS): 00:00:00:29
Reference: Memory used: 915.50 MB
Current: Memory used: 907.48 MB
minimal_surface Passed Core Comparison ✅
Original model has 11 species.
Test model has 11 species. ✅
Original model has 3 reactions.
Test model has 3 reactions. ✅
minimal_surface Passed Edge Comparison ✅
Original model has 38 species.
Test model has 38 species. ✅
Original model has 38 reactions.
Test model has 38 reactions. ✅
Details
Observables Test Case: minimal_surface Comparison✅ All Observables varied by less than 0.500 on average between old model and new model in all conditions!
minimal_surface Passed Observable Testing ✅
Errors occurred during observable testing ⚠️
INFO:root:Reading input file "/home/runner/work/RMG-Py/RMG-Py/test/regression/minimal_surface/regression_input.py"...
INFO:root:options(
title = 'minimal_surface',
tolerance = 0.5,
)
observables
observable(
label = 'CH4',
structure=SMILES('C'),
)
observable(
label = 'O2',
structure=SMILES('[O][O]'),
)
observable(
label = 'X',
structure=adjacencyList(
"""
1 X u0 p0 c0
"""),
)
List of species
species(
label='CH4',
structure=SMILES("[CH4]"),
)
species(
label='O2',
structure=adjacencyList(
"""
1 O u1 p2 c0 {2,S}
2 O u1 p2 c0 {1,S}
"""),
)
species(
label='N2',
structure=SMILES("N#N"),
)
species(
label='X',
structure=adjacencyList(
"""
1 X u0 p0 c0
"""),
)
reactor setups
reactorSetups(
reactorTypes=['IdealGasReactor'],
terminationTimes=([1.0], 's'),
initialMoleFractionsList=[{
'CH4': 0.15,
'O2': 0.15,
'N2': 0.7,
}],
initialSurfaceMoleFractionsList=[{
'X': 1.0,
}],
temperatures=([1000.0], 'K'),
pressures=([1.0], 'bar'),
)
INFO:root:Thermo file has default temperature range 300.0 to 1000.0 and 1000.0 to 5000.0
INFO:root:Thermo file has default temperature range 300.0 to 1000.0 and 1000.0 to 5000.0
INFO:root:Thermo file has no default temperature ranges
INFO:root:(The line it would be on is ' 300.000 1000.000 5000.000\n' but that is not formatted as such)
INFO:root:(It should have Tmin in columns 1-10, Tmid in columns 11-20, and Tmax in columns 21-30)
INFO:root:Ignoring short but non-empty line: ' 300.000 1000.000 5000.000\n'
INFO:root:Thermo file has no default temperature ranges
INFO:root:(The line it would be on is ' 300.000 1000.000 5000.000\n' but that is not formatted as such)
INFO:root:(It should have Tmin in columns 1-10, Tmid in columns 11-20, and Tmax in columns 21-30)
INFO:root:Ignoring short but non-empty line: ' 300.000 1000.000 5000.000\n'
/home/runner/work/RMG-Py/RMG-Py/rmgpy/tools/canteramodel.py:550: UserWarning: ReactorSurface::syncState: Behavior changed in Cantera 3.2 for consistency with ReactorBase. To set SurfPhase state from ReactorSurface object, use restoreState().
species_data.append(np.concatenate((cantera_reactor.thermo[species_names_list].X, rsurf.kinetics.coverages)))
beep boop this comment was written by a bot 🤖
Motivation or Problem
I noticed more Cython inefficiencies in molecule.py. Once I started fixing, I got carried away.
I thought I'd just add these commits to #2958, but I was just too late and it's already been merged.
So here's a new PR.
Description of Changes
Mostly just adding or correcting Cython declarations.
Some of this guided by the annotated HTML files that you can make Cython generate, that show how the code is being translated into C.
For a couple of methods that I think we call a lot, I expanded into explicit loops and tried to do a little more optimization.
Testing
Looked it over. Ran unit tests locally (the ones I guessed to be relevant). Will wait for CI