ATLAS Offline Software
Trigger
TrigT1
Global
GlobalSimulation
src
dot.cxx
Go to the documentation of this file.
1
// Copyright (C) 2002-2023 CERN for the benefit of the ATLAS collaboration
2
3
#include "
dot.h
"
4
#include "
Digraph.h
"
5
#include <fstream>
6
7
using namespace
GlobalSim
;
8
9
namespace
GlobalSim
{
10
void
dot
(
const
Digraph
&
G
,
const
std::string&
fn
) {
11
std::ofstream ofs (
fn
,
std::ofstream::out
);
12
std::size_t V =
G
.V();
13
14
ofs <<
"digraph G{\n"
;
15
ofs <<
"layout=twopi ranksep=3 ratio=auto\n"
;
16
17
for
(std::size_t
v
= 0;
v
!= V; ++
v
) {
18
for
(
const
auto
&
w
:
G
.adj(
v
)) {
19
ofs <<
v
<<
"->"
<<
w
<<
'\n'
;
20
}
21
}
22
ofs <<
"}\n"
;
23
}
24
25
void
dot
(
const
std::unique_ptr<Digraph>&
G
,
const
std::string&
fn
) {
26
dot
(*
G
,
fn
);
27
}
28
}
29
dot.h
GlobalSim
Definition:
AlgData.h:17
python.getCurrentFolderTag.fn
fn
Definition:
getCurrentFolderTag.py:65
GlobalSim::Digraph
Definition:
Digraph.h:16
G
#define G(x, y, z)
Definition:
MD5.cxx:113
test_pythinning.out
out
Definition:
test_pythinning.py:94
python.PyAthena.v
v
Definition:
PyAthena.py:157
Digraph.h
python.IoTestsLib.w
def w
Definition:
IoTestsLib.py:200
GlobalSim::dot
void dot(const Digraph &G, const std::string &fn)
Definition:
dot.cxx:10
Generated on Fri May 17 2024 21:14:07 for ATLAS Offline Software by
1.8.18