মূল বিষয়বস্তুতে যান

JupyterLab in Ilum

সংক্ষিপ্ত বিবরণ

JupyterLab is the next-generation, web-based interactive development environment for notebooks, code, and data.
Within Ilum, JupyterLab serves as the main user interface for all interactive notebook workflows—whether launched in standalone/shared mode (with a single shared workspace) or provisioned automatically as a private workspace inside JupyterHub .

JupyterLab provides a flexible, modern IDE for working with Python, R, Scala, SQL, and more. It lets you edit, run, and visualize code in notebooks, scripts, or terminals, with access to Ilum’s Spark clusters and data storage.


মূল বৈশিষ্ট্য

  • Modern Notebook IDE
    Work in a powerful web-based UI with file browser, tabbed editing, terminals, and drag-and-drop support.
  • Language Support
    Run code in Python, Scala, R, Bash, SQL, and more—using kernels or magic commands.
  • Multi-document Editing
    Edit and execute multiple notebooks, scripts, and terminals side by side.
  • Spark Integration
    Seamless connection to Ilum’s Spark clusters via Sparkmagic and Livy Proxy—run big data workloads from notebooks using %manage_spark , %%sস্পার্ক and related magics.
  • Git Version Control
    • In standalone/shared JupyterLab: A single, shared Git repository managed by the Gitea admin account.
    • In JupyterHub: Individual, private Git repositories per user managed in Gitea.
  • Rich Visualization
    Built-in support for charts, tables, matplotlib, plotly, and other libraries.
  • Extensibility
    Install additional JupyterLab extensions as needed (if permitted by admin).

JupyterLab: Shared vs. JupyterHub (Per User)

AspectJupyterLab (Standalone/Shared)JupyterLab in JupyterHub
User ModelSingle user or shared among manyMulti-user, orchestrated by JupyterHub
প্রমাণীকরণ None/local only or simple loginLDAP/SSO (Ilum-integrated)
Workspace IsolationLocal or shared for all usersPer-user, isolated Kubernetes pod
Resource ManagementLocal server or shared deploymentCentral, managed by JupyterHub on K8s
সংস্করণ নিয়ন্ত্রণ Single shared Git repo (Gitea admin)Per-user private Git repo (Gitea user)
Spark IntegrationPreconfigured, via Livy Proxy & SparkmagicPreconfigured, via Livy Proxy & Sparkmagic
Data AccessIlum volumes, S3, project storageIlum volumes, S3, project storage
নিরাপত্তা ন্যূনতম Enterprise-grade (RBAC, secrets, group-based access)

Version Control Model:

  • In the standalone/shared JupyterLab module, all users work with a single shared Git repository managed by the Gitea admin account.
  • In JupyterHub, each user gets an individual private repository in Gitea, automatically managed per user.
  • For the orchestrated, secure, and version-controlled experience, we recommend using JupyterHub.

Logging In & Access

  • JupyterLab (Shared):
    Access via Modules > JupyterLab in the Ilum UI.
    Users share a common workspace and a single Git repository.
    Authentication may be simple or disabled (depends on deployment).

  • JupyterHub (Recommended):
    Access via Modules > JupyterLab in the Ilum UI.
    You will be directed through Ilum SSO/LDAP authentication (handled by JupyterHub).
    Your own JupyterLab workspace will open, with persistent files, data, Spark integration, and a personal Git repo.


Your Workspace

In JupyterLab (Shared Version)

  • Shared Workspace & Repository:
    All users share the same file space and a single Git repository managed by the Gitea admin account.
    Changes made by any user are visible to all and must be coordinated.

    Note on Multi-User Workflows:
    If you need to work with multiple users in a shared JupyterLab instance (standalone or non-JupyterHub mode), you can create a separate folder for each user inside the main কাজ directory. Each user can then work in their own subfolder.

    However, this approach is neither recommended nor secure.

    • There is no user authentication or isolation at the JupyterLab level in this mode.
      • Any user can overwrite, delete, or modify files belonging to another user.
      • You risk losing your work if another user accidentally (or intentionally) edits or deletes files in your folder.

    Always prefer using JupyterHub for true multi-user, isolated, and secure notebook environments.

  • Starter Notebooks & Structure:
    Pre-populated with example notebooks, sample data, and directory structure for quick onboarding.

  • Git-Backed Storage:
    All changes should be committed and pushed to the shared repository.
    Use the Git sidebar or terminal (git add/commit/push).

In JupyterHub (Per-User Version)

  • Private Workspace & Repository:
    Each user gets an isolated workspace connected to a private Git repository in Gitea, created automatically at first login.

  • Starter Notebooks & Structure:
    Each private repo is initialized with starter files, templates, and recommended structure for onboarding.

  • Git-Backed Storage:
    All changes can be committed and pushed to your personal repository, available only to you (and optionally admins).

  • স্থায়ী স্টোরেজ:
    Files are stored on cluster volumes, accessible only to you, and synced with your personal Git repo for backup/versioning.


Working with Spark

JupyterLab in Ilum is pre-integrated with Apache Spark via Sparkmagic and the Ilum-Livy-Proxy service.
Workflow:

  1. ব্যবহার %manage_spark to configure and start Spark sessions.
  2. ব্যবহার %%sস্পার্ক magic to run Spark (Python/Scala/SQL) code blocks on the cluster, not locally.
  3. View/manage your Spark jobs via the Ilum UI Workloads module.
  4. Sessions are isolated per user, mapped to your permissions and storage.

For complete Spark notebook usage, see Guide for Jupyter Notebooks


Using Git in JupyterLab

  • Git Extension:
    Use the Git tab in the JupyterLab sidebar to stage, commit, and push code/notebooks.
  • Terminal Access:
    You may also use git commands in the terminal.
  • Repository Model:
    All changes are made in a shared repository managed under the Gitea admin account.
  • Credentials:
    Authenticated with credentials configured for the shared admin repository.
  • Collaboration:
    All users work in the same repo, so coordinate commits to avoid conflicts. You can also export notebooks as .ipynb or PDF for sharing externally.

সর্বোত্তম অনুশীলন

  • Commit Often:
    Save your work regularly to Git to ensure versioning and backup.
  • Coordinate Edits (Shared Version):
    If you use the shared JupyterLab deployment, coordinate with your team to avoid conflicts in the shared repo.
  • Leverage Sparkmagic:
    Always use Spark magics to run distributed jobs; do not run heavy workloads on the notebook server itself.
  • Shut Down Idle Kernels:
    Free resources by stopping unused kernels or sessions.

More Resources