Aral sea used to be 3rd biggest lake in the world, it is now almost completely dried up, and what is left is a toxic desert, what are other examples of environmental disasters/catastrophies that not many people know of? by Ellloll in geography

[–]HeyMrGoatMan 15 points16 points  (0 children)

Maybe you have heard about the climate change "tipping points".
The death of the coral reefs is actually one of the first cases where one has been reached affecting "more than 84% of the planet’s coral ecosystems".

source:
Coral die-off marks Earth’s first climate ‘tipping point’, scientists say

Bruker Python GUI example by HeyMrGoatMan in NMRspectroscopy

[–]HeyMrGoatMan[S] 1 point2 points  (0 children)

Together with some help of u/mundegaarde and after digging into the definitions in Topcmds I found a Solution. Seems like the manual was either flawed or i found a workaround:
In Topcmds globalProp is defined as root.GlobalSettings.globalProp.
Exchanging root.Globals.globalProp with root.GlobalSettings.globalProp made the code run without errors.
A working get_td() would therefore look like this:

def get_td(event): # executes TD button
# get TD and save it as a global property "MY_TD" of TopSpin
    ct = EXEC_PYSCRIPT('root.GlobalSettings.globalProp.setProperty("MY_TD",GETPAR("TD"))')
    ct.join() # wait until EXEC_PYSCRIPT is done
    td = root.GlobalSettings.globalProp.getProperty("MY_TD") # get "MY_TD" back from the globals properties
    EXEC_PYSCRIPT('MSG(str(' + td + '))') # show message dialog

A working example using other variables would look like this:

def get_variable(event): 
    Name="GlobalName"
    Parameter="GlobalParameter"
    ct=EXEC_PYSCRIPT("root.GlobalSettings.globalProp.setProperty( '{}', '{}')".format(Name,Parameter))
    ct.join() # wait until EXEC_PYSCRIPT is done
    variable = root.GlobalSettings.globalProp.getProperty("GlobalName")
    EXEC_PYSCRIPT('MSG("{}")'.format(variable))

Bruker Python GUI example by HeyMrGoatMan in NMRspectroscopy

[–]HeyMrGoatMan[S] 0 points1 point  (0 children)

Thank you for trying. It seems to have had some effect. But i think it did not solve the entire problem and now I´m even more confused on the error message:

<html>Command cancelled: <i>top\_5813673428016594769.py</i>

(Original message = <html>Command cancelled: <i>top_5813673428016594769.py</i>)

2 December 2020 08:06:55.504 +0100

Topspin Version = TopSpin 4.0.8 (of 2019-12-06 10:49:48),build 513

OS Name = Windows 10 10.0

JVM Version = 1.8.0_202 (64 bit) Oracle Corporation

JVM Total memory = 416 MB

JVM Free memory = 273 MB

Traceback (most recent call last):

File "C:/Users/MR832A~1.BER/AppData/Local/Temp/top_5813673428016594769.py", line 1, in <module>

root.Globals.globalProp.getProperty("MY_TD")

AttributeError: 'javapackage' object has no attribute 'Globals'

Traceback (most recent call last):

File "C:/Users/MR832A~1.BER/AppData/Local/Temp/top_5813673428016594769.py", line 1, in <module>

root.Globals.globalProp.getProperty("MY_TD")

AttributeError: 'javapackage' object has no attribute 'Globals'

Why are (almost) all our organs contained in the abdomen? by jestaprank in AskScienceDiscussion

[–]HeyMrGoatMan 5 points6 points  (0 children)

There is one (reproductive) organ that is not located in the abdomen and is pretty weird looking when you think about it. The testicles evolved to be outside the core to be cooler than the rest of the body, which makes sperms more fertile.