cheminfo-js / nmr-predictor

NMR chemical shift predictor
MIT License
0 stars 2 forks source link

does the prediction work? #6

Closed targos closed 7 years ago

targos commented 7 years ago

@andcastillo

I tested with the Toluene and I get 7 times the same chemical shift.

Molfile:


Actelion Java MolfileCreator 1.0

  7  7  0  0  0  0  0  0  0  0999 V2000
    1.2990   -0.0000   -0.0000 C   0  0  0  0  0  0  0  0  0  0  0  0
    2.5981   -0.7500   -0.0000 C   0  0  0  0  0  0  0  0  0  0  0  0
    1.2990    1.5000   -0.0000 C   0  0  0  0  0  0  0  0  0  0  0  0
    0.0000   -0.7500   -0.0000 C   0  0  0  0  0  0  0  0  0  0  0  0
    3.8971   -0.0000   -0.0000 C   0  0  0  0  0  0  0  0  0  0  0  0
    2.5981    2.2500   -0.0000 C   0  0  0  0  0  0  0  0  0  0  0  0
    3.8971    1.5000   -0.0000 C   0  0  0  0  0  0  0  0  0  0  0  0
  1  2  2  0  0  0  0
  1  3  1  0  0  0  0
  1  4  1  0  0  0  0
  2  5  1  0  0  0  0
  3  6  2  0  0  0  0
  5  7  2  0  0  0  0
  6  7  1  0  0  0  0
M  END
[
  {
    "diaIDs": [
      "daD@`@fTfUzZ@B@A~dHBIU@"
    ],
    "hose6": "daD@`@fTfUzZ@B@A~dHBIU@",
    "hose5": "gOpHALiLkW@@@_tbADj`",
    "hose4": "gGPHALiLl@@_tbADj`",
    "hose3": "gC`HALiM@ARHDRj@",
    "hose2": "eFBBYcARPQJh",
    "atomLabel": "H",
    "level": 5,
    "delta": 7.31110001,
    "integral": 1,
    "atomIDs": [
      "14"
    ],
    "ncs": 99,
    "std": 0.19461079,
    "min": 6.7928,
    "max": 7.727,
    "j": []
  },
  {
    "diaIDs": [
      "daD@`@fTfUjZ@B@A~dHBIU@"
    ],
    "hose6": "undefined",
    "hose5": "daD@`@fTfUjZ@B@A~dHBIU@",
    "hose4": "gGPHALiLl@@_tbADj`",
    "hose3": "gC`HALiM@ARHDRj@",
    "hose2": "eFBBYcARPQJh",
    "atomLabel": "H",
    "delta": 7.31110001,
    "integral": 1,
    "atomIDs": [
      "13"
    ],
    "ncs": 99,
    "std": 0.19461079,
    "min": 6.7928,
    "max": 7.727,
    "j": []
  },
  {
    "diaIDs": [
      "daD@`@fTfUjZ@B@A~dHBIU@"
    ],
    "hose6": "undefined",
    "hose5": "daD@`@fTfUjZ@B@A~dHBIU@",
    "hose4": "gGPHALiLl@@_tbADj`",
    "hose3": "gC`HALiM@ARHDRj@",
    "hose2": "eFBBYcARPQJh",
    "atomLabel": "H",
    "delta": 7.31110001,
    "integral": 1,
    "atomIDs": [
      "12"
    ],
    "ncs": 99,
    "std": 0.19461079,
    "min": 6.7928,
    "max": 7.727,
    "j": []
  },
  {
    "diaIDs": [
      "daD@`@fTeeVz`@@A~dHBIU@"
    ],
    "hose6": "daD@`@fTeeVz`@@A~dHBIU@",
    "hose5": "gNpHALiKKP@ARHDRj@",
    "hose4": "gJPHALiKT@G}H`QJh",
    "hose3": "eMBBYRZC~d`bUP",
    "hose2": "eFBBYcARPQJh",
    "atomLabel": "H",
    "delta": 7.31110001,
    "integral": 1,
    "atomIDs": [
      "11"
    ],
    "ncs": 99,
    "std": 0.19461079,
    "min": 6.7928,
    "max": 7.727,
    "j": []
  },
  {
    "diaIDs": [
      "daD@`@fTeeVz`@@A~dHBIU@"
    ],
    "hose6": "daD@`@fTeeVz`@@A~dHBIU@",
    "hose5": "gNpHALiKKP@ARHDRj@",
    "hose4": "gJPHALiKT@G}H`QJh",
    "hose3": "eMBBYRZC~d`bUP",
    "hose2": "eFBBYcARPQJh",
    "atomLabel": "H",
    "delta": 7.31110001,
    "integral": 1,
    "atomIDs": [
      "10"
    ],
    "ncs": 99,
    "std": 0.19461079,
    "min": 6.7928,
    "max": 7.727,
    "j": []
  },
  {
    "diaIDs": [
      "daD@`@fTeeVz`@@A~dHBIU@"
    ],
    "hose6": "daD@`@fTeeVz`@@A~dHBIU@",
    "hose5": "gNpHALiKKP@ARHDRj@",
    "hose4": "gJPHALiKT@G}H`QJh",
    "hose3": "eMBBYRZC~d`bUP",
    "hose2": "eFBBYcARPQJh",
    "atomLabel": "H",
    "delta": 7.31110001,
    "integral": 1,
    "atomIDs": [
      "9"
    ],
    "ncs": 99,
    "std": 0.19461079,
    "min": 6.7928,
    "max": 7.727,
    "j": []
  },
  {
    "diaIDs": [
      "daD@`@fTfYVz@`@A~dHBIU@"
    ],
    "hose6": "undefined",
    "hose5": "daD@`@fTfYVz@`@A~dHBIU@",
    "hose4": "gNpHALiLs@PARHDRj@",
    "hose3": "gC`HALiM@ARHDRj@",
    "hose2": "eFBBYcARPQJh",
    "atomLabel": "H",
    "delta": 7.31110001,
    "integral": 1,
    "atomIDs": [
      "8"
    ],
    "ncs": 99,
    "std": 0.19461079,
    "min": 6.7928,
    "max": 7.727,
    "j": []
  },
  {
    "diaIDs": [
      "daD@`@fTfYVz@`@A~dHBIU@"
    ],
    "hose6": "undefined",
    "hose5": "daD@`@fTfYVz@`@A~dHBIU@",
    "hose4": "gNpHALiLs@PARHDRj@",
    "hose3": "gC`HALiM@ARHDRj@",
    "hose2": "eFBBYcARPQJh",
    "atomLabel": "H",
    "delta": 7.31110001,
    "integral": 1,
    "atomIDs": [
      "7"
    ],
    "ncs": 99,
    "std": 0.19461079,
    "min": 6.7928,
    "max": 7.727,
    "j": []
  }
]
andcastillo commented 7 years ago

Possibly not. But it is normal. I guess you were using the in-house db, which could give very bad mistakes in some cases. This is one example. As long as we use more molecules for the training we will improve the result. You better use, for now, spinus for 1H. For 13C you can trust in the result. It has the nmrshiftdb2 database.

targos commented 7 years ago

OK thanks for the answer, I will change to spinus. For the 13C I don't know if I'm missing something but I never get anything. Here is the result for the same molecule:

[
  {
    "diaIDs": [
      "gOpHALiRnZ@D@Ox`JdPNET"
    ],
    "hose6": "undefined",
    "hose5": "gOpHALiRnZ@D@Ox`JdPNET",
    "hose4": "gFpHALiRih@@G~HBiDCaU@",
    "hose3": "gJPHALiR`@G~HBiDCaU@",
    "hose2": "eMBBYc@O|PUIApj`",
    "atomLabel": "C",
    "level": 2,
    "delta": null,
    "integral": 1,
    "atomIDs": [
      "6"
    ],
    "ncs": 0,
    "std": 0,
    "min": 0,
    "max": 0,
    "j": []
  },
  {
    "diaIDs": [
      "gOpHALiRlZ@D@Ox`JdPNET"
    ],
    "hose6": "undefined",
    "hose5": "undefined",
    "hose4": "gOpHALiRlZ@D@Ox`JdPNET",
    "hose3": "gJPHALiR`@G~HBiDCaU@",
    "hose2": "eMBBYc@O|PUIApj`",
    "atomLabel": "C",
    "delta": null,
    "integral": 1,
    "atomIDs": [
      "5"
    ],
    "ncs": 0,
    "std": 0,
    "min": 0,
    "max": 0,
    "j": []
  },
  {
    "diaIDs": [
      "gOpHALiRlZ@D@Ox`JdPNET"
    ],
    "hose6": "undefined",
    "hose5": "undefined",
    "hose4": "gOpHALiRlZ@D@Ox`JdPNET",
    "hose3": "gJPHALiR`@G~HBiDCaU@",
    "hose2": "eMBBYc@O|PUIApj`",
    "atomLabel": "C",
    "delta": null,
    "integral": 1,
    "atomIDs": [
      "4"
    ],
    "ncs": 0,
    "std": 0,
    "min": 0,
    "max": 0,
    "j": []
  },
  {
    "diaIDs": [
      "gOpHALiLkW@@@Ox`JdPNET"
    ],
    "hose6": "undefined",
    "hose5": "gOpHALiLkW@@@Ox`JdPNET",
    "hose4": "gGPHALiLl@@_x`JdPNET",
    "hose3": "gC`HALiM@Ab@jQ@xUP",
    "hose2": "eFBBYcAbBiHNET",
    "atomLabel": "C",
    "delta": null,
    "integral": 1,
    "atomIDs": [
      "3"
    ],
    "ncs": 0,
    "std": 0,
    "min": 0,
    "max": 0,
    "j": []
  },
  {
    "diaIDs": [
      "gOpHALiSKVA@@Ox`JdPNET"
    ],
    "hose6": "undefined",
    "hose5": "undefined",
    "hose4": "gOpHALiSKVA@@Ox`JdPNET",
    "hose3": "gGPHALiSHD@_x`JdPNET",
    "hose2": "eMBBYc@O|PUIApj`",
    "atomLabel": "C",
    "delta": null,
    "integral": 1,
    "atomIDs": [
      "2"
    ],
    "ncs": 0,
    "std": 0,
    "min": 0,
    "max": 0,
    "j": []
  },
  {
    "diaIDs": [
      "gOpHALiSKVA@@Ox`JdPNET"
    ],
    "hose6": "undefined",
    "hose5": "undefined",
    "hose4": "gOpHALiSKVA@@Ox`JdPNET",
    "hose3": "gGPHALiSHD@_x`JdPNET",
    "hose2": "eMBBYc@O|PUIApj`",
    "atomLabel": "C",
    "delta": null,
    "integral": 1,
    "atomIDs": [
      "1"
    ],
    "ncs": 0,
    "std": 0,
    "min": 0,
    "max": 0,
    "j": []
  },
  {
    "diaIDs": [
      "gOpHALiToVD@@OtbApj`"
    ],
    "hose6": "undefined",
    "hose5": "undefined",
    "hose4": "gOpHALiToVD@@OtbApj`",
    "hose3": "gGPHALiThP@_tbApj`",
    "hose2": "gC`HALqp`OzQ@xUP",
    "atomLabel": "C",
    "delta": null,
    "integral": 1,
    "atomIDs": [
      "0"
    ],
    "ncs": 0,
    "std": 0,
    "min": 0,
    "max": 0,
    "j": []
  }
]
targos commented 7 years ago

As you can see, delta is "null". It may be a bug because of my refactoring.

andcastillo commented 7 years ago

There is a problem in my code. I'm solving it. Now the problem is that I did not expand the hydrogens during the nmrshiftdb2 generation. And then I need molecules with H expanded for 1H prediction and H collapsed for 13C.

andcastillo commented 7 years ago

I finally solve the problem. It is predicting heteronuclear patterns

andcastillo commented 7 years ago

I

andcastillo commented 7 years ago

It is not really solved. It is a workaround. To solve the problem requires to solve the java code that generates the HOSE codes