yoshida-lab / XenonPy

XenonPy is a Python Software for Materials Informatics
http://xenonpy.readthedocs.io
BSD 3-Clause "New" or "Revised" License
131 stars 57 forks source link

BaseDescriptor does not have feature_labels #211

Closed stewu5 closed 3 years ago

stewu5 commented 3 years ago

BaseDescriptor and BaseFeaturizer are not completely compatible to each other, as BaseDescriptor does not have feature_labels to be called. Instead, it relies on simply concatenating the results of BaseFeaturizers, i.e., pre-extraction of the column names are not possible.

TsumiNa commented 3 years ago

Hi @stewu5! I think adding this feature to BaseDescriptor is simple work, but do you really need this feature? Could you give me a scene you have to use this feature?

stewu5 commented 3 years ago

This is a consistent issue, I think. There are times that we need to extract the column names of the output dataframe after transformation using BaseFeaturizer, which means that would be the same scenario for BaseDescriptor. As an example, we want to write a new BaseFeaturizer, such as the dataframe wrapper or the frozenfeaturizer wrapper, we now need to save the output in order to get the feature column names because direct extraction of the names is only possible for BaseFeaturizer but not the BaseDescriptor, while our input for those wrapper can accept both.

TsumiNa commented 3 years ago

@stewu5 Yes, the consistency. Let's add this feature.