MCPcopy Create free account
hub / github.com/activeloopai/deeplake / init_deeplake

Function init_deeplake

cpp/deeplake_pg/pg_deeplake.cpp:356–374  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

354}
355
356void init_deeplake()
357{
358 static bool initialized = false;
359 if (initialized) {
360 return;
361 }
362 initialized = true;
363
364 // Register exit handler first (runs last due to LIFO order) to use _exit()
365 // and avoid C++ static destructor crashes in background workers.
366 on_proc_exit(deeplake_quick_exit, 0);
367
368 constexpr int THREAD_POOL_MULTIPLIER = 8; // Threads per CPU core for async operations
369 deeplake_api::initialize(std::make_shared<pg::logger_adapter>(), THREAD_POOL_MULTIPLIER * base::system_report::cpu_cores());
370
371 pg::table_storage::instance(); /// initialize table storage
372
373 RegisterXactCallback(deeplake_xact_callback, nullptr);
374}
375
376} // namespace pg

Callers 9

deeplake_relation_vacuumFunction · 0.85
scan_beginMethod · 0.85
process_utilityFunction · 0.85
deeplake_plannerFunction · 0.85
executor_startFunction · 0.85
handle_index_creationFunction · 0.85
deeplake_index_handlerFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected