Skip to content

Commit 8fe6b8a

Browse files
committed
added julia support and tagged julia code blocks
1 parent 7c42301 commit 8fe6b8a

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

docs/hpc/08_ood/singularity_with_conda.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ For Singularity image available on nyu HPC greene, please check the singularity
7373
For the most recent supported versions of PyTorch, please check the [PyTorch website](https://pytorch.org/get-started/locally/).
7474

7575
Launch the appropriate Singularity container in read/write mode (with the :rw flag)
76-
```
76+
```sh
7777
singularity exec --overlay overlay-15GB-500K.ext3:rw /scratch/work/public/singularity/cuda12.1.1-cudnn8.9.0-devel-ubuntu22.04.2.sif /bin/bash
7878
```
7979

@@ -336,7 +336,7 @@ Pkg.add("JuMP")
336336
```
337337

338338
Now exit from the container to launch a read only version to test (example below)
339-
```
339+
```julia
340340
~/julia/my-julia
341341
_
342342
_ _ _(_)_ | Documentation: https://docs.julialang.org
@@ -374,7 +374,7 @@ julia> optimize!(m)
374374
```
375375

376376
You can make the above code into a julia script to test batch jobs. Save the following as test-knitro.jl
377-
```
377+
```julia
378378
using Pkg
379379
using JuMP, KNITRO
380380
m = Model(with_optimizer(KNITRO.Optimizer))
@@ -389,7 +389,7 @@ You can add additional packages with commands like the one below.
389389
:::note
390390
Please do not install new packages when you have Julia jobs running, this may create issues with your Julia installation)
391391
:::
392-
```
392+
```julia
393393
~/julia/my-julia-writable -e 'using Pkg; Pkg.add(["Calculus", "LinearAlgebra"])'
394394
```
395395

@@ -463,7 +463,7 @@ Knitro using the Interior-Point/Barrier Direct algorithm.
463463
464464
WARNING: The initial point is a stationary point and only the first order
465465
optimality conditions have been verified.
466-
466+
467467
EXIT: Locally optimal solution found.
468468
469469
Final Statistics
@@ -538,15 +538,15 @@ julia --version
538538
```
539539

540540
Run julia to install packages
541-
```
541+
```julia
542542
julia
543543
> using Pkg
544544
> Pkg.add("KNITRO")
545545
> Pkg.add("JuMP")
546546
```
547547

548548
Set up a similar test script like the test-knitro.jl script above. Name it test.jl:
549-
```
549+
```julia
550550
using Pkg
551551
using JuMP, KNITRO
552552
m = Model(with_optimizer(KNITRO.Optimizer))

docusaurus.config.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@ const config: Config = {
146146
prism: {
147147
theme: prismThemes.oneLight,
148148
darkTheme: prismThemes.palenight,
149-
additionalLanguages: ['bash', 'shell-session', 'lua'],
149+
additionalLanguages: ['bash', 'shell-session', 'lua', 'julia'],
150150
},
151151
} satisfies Preset.ThemeConfig,
152152
};

0 commit comments

Comments
 (0)