Closed ksunden closed 7 years ago
I have been thinking of getting rid of from_text
. I much rather have each from method be entirely separate. I know that this will mean more lines of code, but I think that portability is more important here.
Anyway, there are great tools like np.genfromtext
that do most of what we want anyway.
I can agree to that, regardless, from_text
which expects specifically rRaman files is confusing
@neffmallon has mentioned that from_text is used for files from the raman instrument downstairs
This should likely have its own from
method, but should be done concurrently with removing from_text
*from the IR instrument downstairs.
Yeah, sorry, I mistyped that, read it back a little bit ago, and thought that sounded incorrect
which IR instrument? we have from_Tensor27
I actually think maybe we want to keep from_text
in some form, but maybe rename it to something like from_ascii_xy
and put some specificity into what we expect
Maybe with support for headers which specify channel/axis names, though I think it would be limited to single axis, potentially with multiple channels though
There is a helpful list provided by Essential FTIR of many common spectroscopy formats: http://www.essentialftir.com/filetypes.html
Here, they do list ascii (x,y) pairs, which seems to be a generic enough format, which we could pretty easily support, but need to be clear that is what it means
Keeping it around with some flexible options (perhaps kwargs for channel names, etc) would also make it a powerful way to create many of the common formats with minimal effort
I guess that sounds reasonable, but it does worry me. I really don't trust users to remember the details of specific file types, which I why I much prefer dedicated from methods whenever possible. I worry that everyone would just start using from_ascii
, never remembering to use the dedicated methods.
I guess I'm OK with such a method existing, as long as it doesn't get advertised for general use.
from_text
has been removed (see #233)
Currently this seems to be a rather specific text format reader for Brunold rRaman files
I feel like this could be made more general to any tab separated file, but think that it needs to be considered exactly what specifications should be there.
If we expand, it should not check for expected filetypes, as any plaintext file will do.
There is also a portion in the verbose output that references
datas
a variable that does not exist