Skip to content
Snippets Groups Projects
Select Git revision
  • 5a7edcb8ac227c3f3c318b5b9df7cca27542ec03
  • master default protected
2 results

test_fsig.py

Blame
    • Daniel Brown's avatar
      4d173029
      adding in fsig command (not parsing yet). See example test_fsig.py in bin... · 4d173029
      Daniel Brown authored
      adding in fsig command (not parsing yet). See example test_fsig.py in bin folder. Also made component variable an optional argument for xaxis and x2axis which will break previous scripts. Did this as when setting the parameter to tune, the Param object contains whatever component owns that parameter so no need to pass it twice. Also stops someone passing a parameter not for the component stated.
      4d173029
      History
      adding in fsig command (not parsing yet). See example test_fsig.py in bin...
      Daniel Brown authored
      adding in fsig command (not parsing yet). See example test_fsig.py in bin folder. Also made component variable an optional argument for xaxis and x2axis which will break previous scripts. Did this as when setting the parameter to tune, the Param object contains whatever component owns that parameter so no need to pass it twice. Also stops someone passing a parameter not for the component stated.
    test_hom.py 396 B
    import pykat
    
    kat = pykat.finesse.kat()
    
    kat.parseCommands("""
    l l1 1 0 0 n1
    sq l2 0 10 0 n4
    
    bs bs1 0.5 0.5 0 0 n1 n2 n3 n4
    
    fsig noise l1 amp 1 0 1
    
    qhd qhd180 180 n2 n3
    qhd qhd0 0 n2 n3
    qhdS qhd2 0 n2 n3
    qhdN qhd2 0 n2 n3
    scale meter qhd180
    scale meter qhd0
    scale meter qhd2
    scale 2 qhd0
    
    xaxis l1 phase lin 0 360 360
    """)
    
    print "".join(kat.generateKatScript())
    
    out = kat.run()
    
    out.plot()