mirror of
https://github.com/chanzuckerberg/cellxgene.git
synced 2026-09-29 19:48:11 +08:00
Implement driver class for scanpy
This commit is contained in:
@@ -1,15 +1,23 @@
|
||||
from abc import ABC, abstractmethod
|
||||
from abc import ABCMeta, abstractmethod
|
||||
|
||||
class CXGDriver(metaclass=abc.ABCMeta):
|
||||
class CXGDriver(metaclass=ABCMeta):
|
||||
|
||||
def __init__(self, data, schema=None, graph_method=None, diffexp_method=None):
|
||||
self.data = _load_data(data)
|
||||
self.data = self._load_data(data)
|
||||
|
||||
@abstractmethod
|
||||
@staticmethod
|
||||
def _load_data(data):
|
||||
pass
|
||||
|
||||
@abstractmethod
|
||||
def _load_or_infer_schema(data):
|
||||
pass
|
||||
|
||||
@abstractmethod
|
||||
def _set_cell_ids(self):
|
||||
pass
|
||||
|
||||
@abstractmethod
|
||||
def cells(self):
|
||||
pass
|
||||
|
||||
Reference in New Issue
Block a user