Skip to main content

self-bootstrapping-model-service (SBMS)

A parallelizable framework designed for the execution of complex geographical model services on a single backend machine. SBMS leverages implicit and self-organizing relationships, avoiding the need for a pre-defined global DAG, by dynamically coordinating model execution through local node dependencies and state-driven control.

To bridge the model using requests,the model scheduling and the calculated resource, a core class named Model Case Reference (MCR) is designed and applied. The instance of this class can transfer a model using request and its related runtime-dependent parameters (usually found in the request body) from the web-server layer to a specific model case folder. Consequently, any requests using the same model with the same parameters can be directed to the same model running case.

graph LR

        subgraph BMSAPIS[<b>APIS</b>]
            API0>API 0]
            API1>API 1]
            APIN>API...]
        end

        subgraph Models[<b>Models</b>]
            Model0[Model 0]
            Model1[Model 1]
            ModelN[Model...]
        end

        subgraph ModelRequests[<b>Model Using Requests</b>]
            Request0([Model Request 0])
            Request1([Model Request 1])
            Request2([Model Request 2])
            RequestN([Model Request...])
        end

        CaseID0(((<b>Case ID</b>)))

        subgraph ModelCaseReferences[<b>Model Case References</b>]
            MCR0((MCR 0))
            MCR1((MCR 1))
            MCRN((MCR...))
        end
        
        subgraph CaseContent[<b>Model Case Content In Disk</b>]
            Identity[identity.json]
            Response[response.json]
            subgraph Result[<b>Result</b>]
                File0[File 0]
                File1[File 1]
                FileN[File...]
            end
            subgraph Status[<b>Status</b>]
                StatusFile[StatusFile]
            end
        end

        subgraph Resource[<b>Resource</b>]
            subgraph DEMFiles[e.g. DEM Resource]
                DEM0[DEM Resource 0]
                DEM1[DEM Resource 1]
                DEMN[DEM Resource...]
            end
            
        end

    API0-->Request0
    Request0-.-|SAME API and REQUEST BODY|Request2
    API0-->Request2


    MCR0--o|PARSE REQUEST and USE|Model0

    MCR0--o|PARSE REQUEST and INPUT|DEM0
    MCR0--o|PARSE REQUEST and INPUT|DEM1
    MCR0-->|OUTPUT|Result
    MCR0-->|SERIALIZE|Identity
    MCR0-->|GENERATE after MODEL RUNNING COMPLETE|Response

    Request0-->|GENERATE from URL and REQUEST BODY|CaseID0
    Request2-->|GENERATE from URL and REQUEST BODY|CaseID0
    CaseID0-->MCR0
    MCR0==x|POINT TO|CaseContent
    MCR0-->|REFLECT MODEL RUNNING STATUS|Status

    style BMSAPIS fill:none
    style Models fill:none
    style ModelRequests fill:none
    style ModelCaseReferences fill:none
    style CaseContent fill:none
    style Resource fill:none
    style Result fill:none
    style Status fill:none
    style DEMFiles fill:none

NOTE

The basic condition for MCR to be EFFECTIVE is that when the model and parameters have not changed, the results of multiple runs are COMPLETELY CONSISTENT.

Launch server

  • Dependencies:
    FastAPI
    Portalocker
  • Run:
    python "run.py"

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

sbms-0.1.0.tar.gz (15.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

sbms-0.1.0-py3-none-any.whl (19.9 kB view details)

Uploaded Python 3

File details

Details for the file sbms-0.1.0.tar.gz.

File metadata

  • Download URL: sbms-0.1.0.tar.gz
  • Upload date:
  • Size: 15.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.0.1 CPython/3.13.2 Darwin/24.3.0

File hashes

Hashes for sbms-0.1.0.tar.gz
Algorithm Hash digest
SHA256 c08a34a0b57f9d97e98f2c19bc8e642fc26d59016a7bf579fbfa0f8af53478a2
MD5 90046d7a611ff50d20285293605e07e2
BLAKE2b-256 c41cb9d96c428b7c97a45a0b2fdb781f8949309e912f7a467e74203fb2d3fe2b

See more details on using hashes here.

File details

Details for the file sbms-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: sbms-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 19.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.0.1 CPython/3.13.2 Darwin/24.3.0

File hashes

Hashes for sbms-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 27c66aec3d86b8d50695fc96f540234b0703777df96d27dcf73ed58b6838055f
MD5 2b1be42f6e4f4b3bd84b27569f8578ec
BLAKE2b-256 7644ee959687aa8f1a8d4c3f4e7ac8996086b2c3ddc5b625722d3a11ded47095

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 files

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page