lingpy / lingpy3

LingPy 3.0
GNU General Public License v3.0
1 stars 2 forks source link

General Folder Structure #1

Open LinguList opened 7 years ago

LinguList commented 7 years ago

Apart from re-arranging, I think we'll still have the following structure:

The names are not really important, but the responsibilities: handling sequences, wordlists, and trees, both as an object of itself, and in comparison, seems important for me.

xrotwang commented 7 years ago

Two comments:

  1. I'd rather not put code into the data directory. E.g. the code related to initializing a sound class model from the spec files should go into a classmethod SoundClassModel.from_path.
  2. I would hope there is not that much wordlist related code. If so, I'd rather have a top-level wordlist.py module, providing one class Wordlist.
LinguList commented 7 years ago

I agree. So data/ would just be reserved for data, and sound-class handling, including those sound-class-models, would go into the sequence package (the term "model" has anyway confused many people, and it seems just that the sequence/ folder would be the right place for this).

SimonGreenhill commented 7 years ago

I worry that misc tends to become a code bloat magnet! If it's mainly for output, then why not have output for writing to things. Anything else "misc" should be kept as a plugin/addon or given its own top level.

LinguList commented 7 years ago

I agree. Given output, we will have to offer quite some things anyway, as I think it is important to, e.g., offer output to nexus, phylip, csv, etc. So having one clean output module/package is surely a good idea. What we would discard and put into a plugin are the plots, which can't be really sufficiently tested and are mostly "on your own risk". I love doing things with matplotlib, but I hate to be made responsible for insufficient output by users.