10 from ROOT
import gSystem
12 gSystem.Load(
'libtracking_trackFindingCDC')
14 from ROOT
import Belle2
17 AttributeMap = Belle2.TrackFindingCDC.PrimitivePlotter.AttributeMap
23 groupAttributes = AttributeMap()
24 groupAttributes[
'stroke'] =
'black'
25 groupAttributes[
'stroke-width'] =
'5'
28 plotter.startGroup(groupAttributes)
31 plotter.drawLine(0, 0, 100, 100)
34 lineAttributes = AttributeMap()
35 lineAttributes[
'stroke'] =
'green'
38 plotter.drawLine(0, 100, 100, 0, lineAttributes)
54 arcAttributes = AttributeMap()
55 arcAttributes[
"fill"] =
"none"
56 arcAttributes[
"stroke"] =
"violet"
57 arcAttributes[
"stroke-width"] =
"5"
59 plotter.drawCircleArc(startX, startY, endX, endY, radius, longArc, sweepFlag, arcAttributes)
62 arrowAttributes = AttributeMap()
63 arrowAttributes[
"stroke"] =
"yellow"
64 arrowAttributes[
"stroke-width"] =
"5"
66 plotter.drawArrow(50, 90, 50, 10, arrowAttributes)
78 circleAttributes = AttributeMap()
79 circleAttributes[
"stroke"] =
"green"
80 circleAttributes[
"stroke-width"] =
"5"
81 circleAttributes[
"fill"] =
"white"
82 circleAttributes[
"_showAt"] =
"0s"
87 for secs, x
in enumerate((25, 40, 55, 70)):
88 circleAttributes[
"_showAt"] = str(secs) +
"s"
89 plotter.drawCircle(x, y, r, circleAttributes)
92 testFileName =
"test.svg"
94 plotter.save(testFileName)
99 with open(testFileName)
as input_file:
100 for line
in input_file:
103 os.remove(testFileName)