Creating order via sub-directories: os.makedirs: Revision history

From Master of Neuroscience Wiki

Diff selection: Mark the radio buttons of the revisions to compare and hit enter or the button at the bottom.
Legend: (cur) = difference with latest revision, (prev) = difference with preceding revision, m = minor edit.

17 October 2025

15 October 2025

  • curprev 13:2813:28, 15 October 2025 Davrot talk contribs 2,022 bytes +2,022 Created page with " == The goal == How can I make sure that the directory for my output data is always there? We just create it automatically every time via [https://docs.python.org/3/library/os.html#os.makedirs os.makedirs]! Questions to [mailto:davrot@uni-bremen.de David Rotermund] == Creating a directory == <syntaxhighlight lang="python">import os some_path: str = "a_home_for_my_data" os.makedirs(some_path, exist_ok=True)</syntaxhighlight> == Creating a sub-sub-sub-directory == Firs..." Tag: Visual edit