Trials in German criminal cases are generally open to the public (subject to exceptions similar to those in the U.S.) and there is a presumption of innocence until proof beyond a reasonable doubt establishes otherwise in its criminal justice system. The authority for this and the history of this are explored below.
In a criminal case in Germany, according to the German Code of Criminal Procedure, Section 261, a judge is supposed to make a decision upon guilt or innocence based upon the following standard:
Section 261.
[Free Evaluation of Evidence]
The court shall decide on the result of the evidence taken according
to its free conviction gained from the hearing as a whole.
Section 263 provides that decisions regarding guilt against a defendant must be made by a two-thirds majority of the judges (typically a panel of three in felony cases).
Neither the German Penal Code, nor the German Code of Criminal Procedure contain a clear articulation of a presumption of innocence or of a presumption of guilt. An arrest and certain other pre-trial remedies are allowed when someone is "seriously suspected" of a crime, and a judge may dismiss charged if they are without sufficient legal basis on their face.
As explained here:
If there are indications of a crime, the district attorney or the
police department must initiate an official investigation. If the
matter comes to a trial, it is the court's duty to pursue further
official investigations. The court is obliged to look for evidence,
whether or not defence counsel or the district attorney ask that
evidence is heard. . . .
In criminal proceedings, all evidence must be presented during the
trial. Only the results of the main (oral) hearing may serve as a
basis for the sentence (sections 261 and 264, Code of Criminal
Procedure). Written evidence, such as documents, must be read out and
witnesses must be interrogated in the presence of the court and the
public. . . .
Hearings and other court dates in criminal matters are . . . open to
the public (section 169, Court Constitution Act). In some cases,
confidentiality is deemed to outweigh the basic rule of public access
to court proceedings, for example in matters of national security, or,
more commonly, in proceedings concerning young people. . . .
Juries are not used in criminal proceedings. Minor cases are tried by
one career judge, and other matters are tried by a court consisting of
one career judge and two lay judges (section 29, Court Constitution
Act). In certain very serious matters (for example, cases involving
the death of the victim), the court consists of three career judges
and two lay judges (section 74, Court Constitution Act), Lay judges in
criminal proceedings are meant to ensure the approval of a criminal
verdict by the public. . . .
In civil law cases, the burden of proof generally lies with the party
asserting the claim. They must prove their case beyond reasonable
doubt.
The burden of proof can be shifted, for example in claims for damages
due to breach of contractual obligations. The defendant's
responsibility for the contractual breach is presumed by the law, and
the defendant bears the burden of proving otherwise (section 280
subsection 1 second sentence, German Code of Civil Law (Bürgerliches
Gesetzbuch)).
As there are no disclosure-like proceedings, the party with the burden
of proof may need to demonstrate a fact that they have had no chance
to obtain knowledge of, while the other party can present this
information easily (for example, information regarding the opposing
party's assets or tax burden). In this case, the burden of proof does
not shift, but the other party has a duty to provide sufficient
information for the first party to substantiate their submission. This
is known as the "secondary burden of proof". . . .
As criminal proceedings in Germany are not adversarial, but apply the
principle of official investigation (see Question 18), it is the court
and the prosecutor that have to provide evidence both against and in
favour of the accused.
In a criminal trial the standard of proof is similar to the one in
civil matters: the court must be convinced beyond reasonable doubt.
The benefit of any doubt goes to the accused.
The legal source this standard of proof is an international treaty, as articulated below, and this provides a legal gloss on the interpretation given to Section 261 quoted above. This is basically the same standard of proof in civil and criminal cases. The probabilistic "preponderance of the evidence" standard used in civil cases in common law systems is not used.
The presumption of innocence in the German criminal justice system and its practical effects are discussed in this 2014 law review article. It explains the history of that provision in German law as well:
Comparatists of criminal law and procedure like the presumption of
innocence. It seems to provide a focus on which all can agree. The
presumption of innocence has a rich historical heritage (see Hruschka
2000) and enjoys international acceptance, as exemplified by its
recognition as a basic right in Article 14 (2) of the International
Covenant on Civil and Political Rights.1 But the presumption’s aura
and its effectiveness as a rhetorical device contrast with the
difficulty of determining its precise meaning, especially in
international discourse. The presumption of innocence, it seems,
resembles a wonderfully carved and polished gem which reflects the
light in various sparkling tones—but at closer inspection is nothing
but a piece of glass.
In what follows, I will not even begin to discuss the various meanings
that the presumption of innocence has acquired in different legal
systems. I will rather concentrate on the German system and will try
to demonstrate the (useful but) limited reach of the presumption of
innocence in the German context.
In a legal system such as the German system that is solidly built on
codes and statutes, one would expect that a principle as important as
the presumption of innocence is enshrined in the Constitution, or at
least in one of the first paragraphs of the Code of Criminal
Procedure. But the presumption of innocence has not been given a
prominent place in the cathedral of German law; in fact, the
presumption does not appear anywhere in indigenous German legislation.
It has become part of German statutory law only by the wholesale
transformation, in 1952, of the European Convention on Human Rights
into domestic German law.2
In spite of that less than spectacular genealogy, the presumption of
innocence enjoys as high a status in German legal discourse as in any
other legal system. In a 1987 decision, the Federal Constitutional
Court, Germany’s highest judicial authority, declared that ‘‘the
presumption of innocence is a special feature of the principle of
Rechtsstaat (a state built on the rule of law) and thus has the rank of a constitutional norm.’’3 The Constitutional Court linked the
presumption of innocence to other high-ranking Constitutional
concepts, such as the principle of culpability as a requirement for
punishment, and human dignity, which is the supreme value protected by
Article 1 of the German Constitution.4
1 Article 14 (2) of the International Covenant on Civil and Political
Rights of 19 December 1966 reads:
‘‘Everyone charged with a criminal offence shall have the right to be
presumed innocent until proved guilty according to law.’’
2 See Gesetz u¨ber die Konvention zum Schutz der Menschenrechte und
Grundfreiheiten, II Bundesgesetzblatt p. 685 (1952).
3 Bundesverfassungsgericht, Judgment of 26 March 1987, 74
Entscheidungen des Bundesverfassungsgerichts (hereinafter: BVerfGE)
358 at 370.
4 id. at 371.
The presumption of innocence was in a section numbers 6(2) in the original 1952 treaty (which contained equally authoritative English, French and German provisions) that Germany adopted, but has been renumbered in the meantime.
Footnote on some assumptions in the question.
Germany never followed the Napoleonic Code. It drafted its own civil and criminal codes from scratch based upon the Napoleonic Code model. Most civil codes in the world follow either the German model or the French model (e.g. South Korea's civil code is based upon Germany's while Vietnam's was based upon the French civil code). Superficially, the German model is easily distinguished by having more major subparts than the French one does. All civil and criminal codes in civil law countries have been amended many times.
All countries in Continental Europe, in the pre-Napoleonic Code era, did something that is now called the "reception" of Roman law, which basically meant treating Roman legal treatises as binding legal authorities, in the "early modern" period before which personal feudal rule by aristocrats rather than the "rule of law" was the norm. But the available Roman legal treatises offered more insight to officials making judicial decisions based upon received Roman law, and were taken as more authoritative in the area of non-criminal private law, than they were in the areas of public and criminal law.
In most of continental Europe (and for that matter in the U.K. as well), human rights flow mostly from international treaties (associated with the formation of the "Council of Europe" not to be confused with the E.U. organ known as the European Council), rather than from domestic constitutional rights, although some of these countries have also incorporated their treaty obligations into separate constitutional provisions or domestic statutes as a means of implementing those treaties.