tee-ar-ex / trx-python

Python implementation of the TRX file format
https://tee-ar-ex.github.io/trx-python/
BSD 2-Clause "Simplified" License
22 stars 15 forks source link

Rename the confusing object name TrxFile ? #72

Open skoudoro opened 10 months ago

skoudoro commented 10 months ago

Hi trx team

TrxFile is a disturbing object since you expect or believe to have a filename, filepath, etc...

I propose to rename this object TrxContainer, TrxHolder, etc....

I am open to any other renaming but I strongly believe that TrxFile is very confusing.

concatenate function is a nice exemple. When you see TrxFile as an input of this function, I believed that I need to put a filename, however, in reality, you need to load it before calling the function.

Please, let me know what you think @frheault and @arokem

arokem commented 10 months ago

Hello! I wonder if this is not a sign that more functionality needs to be delegated to the StatefulTractogram object instead?

skoudoro commented 10 months ago

That's a good question. Can you develop your thought ?

frheault commented 10 months ago

I initially used TrxFile because Nibabel has TrkFile and TckFile when you load a tractogram. So I kept that logic, I have no strong opinion.