Open-Assistant
Open-Assistant copied to clipboard
Fix a bitwise operator
I got the following error at model/supervised_finetuning/custom_datasets/summarization.py#L60
:
TypeError: unsupported operand type(s) for &: 'list' and 'str'
@tomohideshibata not sure what's the difference between the two, can you extrapolate?
@theblackcat102 Thanks for your response.
First, the current code does not work due to the operator precedence.
The following code would work, but I think it is normal to use and
instead of &
.
if (summarization_config_mapping[dataset][0] in ["billsum", "tldr_news"]) & (split == "validation"):
...
This is fixed via https://github.com/LAION-AI/Open-Assistant/pull/1455.