Skip to content

Commit

Permalink
feat: add support for BytesIO inputs
Browse files Browse the repository at this point in the history
  • Loading branch information
f-aguzzi committed Jun 29, 2024
1 parent e5c707b commit bab82e8
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/chemfusekit/df.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
"""Performs low-level data fusion on input arrays, outputs the results"""
from typing import Optional, List, IO
from io import BytesIO

import numpy as np
import pandas as pd
Expand All @@ -16,7 +17,7 @@
class Table:
"""Holds the path, preprocessing choice and sheet name for a single Excel table."""

def __init__(self, file_path: str | IO, sheet_name: str, preprocessing: str, feature_selection: str | None = None,
def __init__(self, file_path: str | IO | BytesIO, sheet_name: str, preprocessing: str, feature_selection: str | None = None,
class_column: str = 'Substance', index_column: str | None = None):
self.file_path = file_path
self.sheet_name = sheet_name
Expand Down

0 comments on commit bab82e8

Please sign in to comment.