# Folder Structure for DICOM data

**URL:** https://discourse.orthanc-server.org/t/folder-structure-for-dicom-data/1802
**Category:** Google Groups archive
**Created:** [February 21, 2020, 8:44pm UTC](https://discourse.orthanc-server.org/t/folder-structure-for-dicom-data/1802 "2020-02-21T20:44:19Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![Vincent\_Borgese](https://discourse.orthanc-server.org/letter_avatar_proxy/v4/letter/v/9de0a6/32.png) [@Vincent\_Borgese](https://discourse.orthanc-server.org/u/Vincent_Borgese)
#### Post date: [February 21, 2020, 8:44pm UTC](https://discourse.orthanc-server.org/t/folder-structure-for-dicom-data/1802/1 "2020-02-21T20:44:19Z")

</div>

Can the folder structure be changed so that the entire DICOM data set be available in one folder?

---

<div class="post-metadata">

### Author: ![jodogne](https://discourse.orthanc-server.org/user_avatar/discourse.orthanc-server.org/jodogne/32/1511_2.png) [@jodogne](https://discourse.orthanc-server.org/u/jodogne)
#### Post date: [February 22, 2020, 3:01pm UTC](https://discourse.orthanc-server.org/t/folder-structure-for-dicom-data/1802/2 "2020-02-22T15:01:45Z")

</div>

You are most probably looking for the “AutoClassify” Python sample that is part of the Orthanc source distribution, and that takes advantage of the REST API of Orthanc:  
[https://bitbucket.org/sjodogne/orthanc/src/Orthanc-1.5.8/Resources/Samples/Python/AutoClassify.py](https://bitbucket.org/sjodogne/orthanc/src/Orthanc-1.5.8/Resources/Samples/Python/AutoClassify.py)

---

<div class="post-metadata">

### Author: ![ADARSH\_ANAND](https://discourse.orthanc-server.org/letter_avatar_proxy/v4/letter/a/6f9a4e/32.png) [@ADARSH\_ANAND](https://discourse.orthanc-server.org/u/ADARSH_ANAND)
#### Post date: [January 22, 2021, 4:34am UTC](https://discourse.orthanc-server.org/t/folder-structure-for-dicom-data/1802/3 "2021-01-22T04:34:56Z")

</div>

This link is not working right now. Can you share the updated link?

---

<div class="post-metadata">

### Author: ![jodogne](https://discourse.orthanc-server.org/user_avatar/discourse.orthanc-server.org/jodogne/32/1511_2.png) [@jodogne](https://discourse.orthanc-server.org/u/jodogne)
#### Post date: [January 22, 2021, 6:09am UTC](https://discourse.orthanc-server.org/t/folder-structure-for-dicom-data/1802/4 "2021-01-22T06:09:15Z")

</div>

Here it is:  
[https://hg.orthanc-server.com/orthanc/file/Orthanc-1.8.2/OrthancServer/Resources/Samples/Python/AutoClassify.py](https://hg.orthanc-server.com/orthanc/file/Orthanc-1.8.2/OrthancServer/Resources/Samples/Python/AutoClassify.py)

In the meantime, Orthanc 1.8.0 introduced support for WebDAV, which provides an easier solution for a non-technical audience:  
[https://book.orthanc-server.com/users/webdav.html](https://book.orthanc-server.com/users/webdav.html)

---

<div class="post-metadata">

### Author: ![Bartosz\_Kaczynski](https://discourse.orthanc-server.org/letter_avatar_proxy/v4/letter/b/c0e974/32.png) [@Bartosz\_Kaczynski](https://discourse.orthanc-server.org/u/Bartosz_Kaczynski)
#### Post date: [April 8, 2021, 12:49pm UTC](https://discourse.orthanc-server.org/t/folder-structure-for-dicom-data/1802/5 "2021-04-08T12:49:34Z")

</div>

Should I install this plugin using this documentation?  
[https://book.orthanc-server.com/plugins/python.html](https://book.orthanc-server.com/plugins/python.html)

If yes, I receive error from orthanc.log:  
E0408 14:26:41.997398 PluginsManager.cpp:164] Error during the installation of the Python script, traceback:  
\<class ‘AttributeError’\>  
module ‘sys’ has no attribute ‘argv’

File “/etc/orthanc/AutoClassify.py”, line 47, in   
import RestToolbox

File “/etc/orthanc/RestToolbox.py”, line 32, in   
formatter\_class = argparse.ArgumentDefaultsHelpFormatter)

File “/usr/lib64/python3.6/argparse.py”, line 1626, in **init**  
prog = \_os.path.basename(\_sys.argv[0])

E0408 14:26:41.997461 PluginsManager.cpp:102] Error while initializing plugin /usr/share/orthanc/plugins/libOrthancPython.so (code -1)

---

<div class="post-metadata">

### Author: ![jodogne](https://discourse.orthanc-server.org/user_avatar/discourse.orthanc-server.org/jodogne/32/1511_2.png) [@jodogne](https://discourse.orthanc-server.org/u/jodogne)
#### Post date: [April 9, 2021, 7:30am UTC](https://discourse.orthanc-server.org/t/folder-structure-for-dicom-data/1802/6 "2021-04-09T07:30:20Z")

</div>

The two links I provided above are _not_ related to Python plugins.

1- The “AutoClassify.py” script is an external Python script (_not_ a plugin) that uses the REST API of Orthanc:  
[https://book.orthanc-server.com/users/rest.html](https://book.orthanc-server.com/users/rest.html)

2- The WebDAV support is built in the Orthanc core.

In both cases, you don’t have to install any plugin.
