informatics-isi-edu / deriva-ml

modules and tools to streamline the use of derive catalogs with standard ML libraries.
Apache License 2.0
0 stars 0 forks source link

Separate schema for ML and domain tables #1

Open Zhiweiii opened 2 months ago

Zhiweiii commented 2 months ago

Enable three schemas in DerivaML:

  1. domain_schema
  2. ml_schema
  3. vocab_schema

To initiate DerivaML:

class DerivaML:
    def __init__(self, hostname: str, catalog_id: str, domain_schema: str, ml_schema: str, vocab_schema: str, data_dir: str):

In Catalog ML, hard coded the three schemas for the catalog. E.g. EyeAI project

class EyeAI(DerivaML):
    def __init__(self, hostname: str = 'www.eye-ai.org', data_dir: str = './'):
        super().__init__(hostname, 'eye-ai, 'eye-ai', 'eye-ai', data_dir)

FaceBase ML project

class FaceBaseML(DerivaML):
    def __init__(self, hostname: str = 'ml.facebase.org', data_dir: str = './'):
        super().__init__(hostname, 'isa', 'ml', 'vocab', data_dir)
Zhiweiii commented 2 months ago

Changes: Initiate the Deriva-ML with the ML catalog schema name. For all the rest of the tables, search for the schema it belongs to.