Skip to content

Commit

Permalink
kii explanation + ./server to ./g2s_server
Browse files Browse the repository at this point in the history
  • Loading branch information
pauwiersma committed Jan 11, 2024
1 parent 36af191 commit e1d4aee
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 3 additions & 1 deletion algorithms/QuickSampling.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ Outputs: sim = simulation, index = index of the simulated values in the flattene
| `-dt` | Data type. 0 &rarr; continuous and 1 &rarr; categorical. <red>This is where the number of variables is defined.</red> Provide a list containing zeros or ones representing the data type of each variable. | &#x2714; |
| `-k` | Number of best candidates to consider &#x2208; [1 &infin;]. | &#x2714; |
| `-n` | N closest neighbors to consider. If multiple variables: use a single N value if identical for all variables or use an array of N values if each variable has a different N. | &#x2714; |
| `-ki` | Image of the weighting kernel. Can be used to normalize the variables. If multiple variables: use a single kernel value if identical for all variables or if each variable has a different kernel, stack all kernels along the last dimension. The number of kernels should then match the size of the array given for the parameter dt. | |
| `-ki` | Image of the weighting kernel. Can be used to normalize the variables. If multiple variables: use a single kernel value if identical for all variables or if each variable has a different kernel, stack all kernels along the last dimension. The number of kernels should then match the size of the array given for the parameter dt. Possibility to use different kernels for different parts of the simulation with the "-kii" parameter explained below. | |
| `-f` | f=1/k equivalent to f of DS with a threshold to 0. | |
| `-j` | To run in parallel (default is single core). To use as follows '-j', N1, N2, N3 (all three are optional but N3 needs N2, which in turn needs N1). Use integer values to specify a number of threads (or logical cores). Use decimal values &isin;]0,1[ to indicate fraction of the maximum number of available logical cores (e.g., 0.5=50% of all available logical cores). N1 threads used to parallelize the path (path-level) Default: the maximum number of threads available. N2 threads used to parallelize over training images (if many TIs are available, each is scanned on a different core). Default: 1. N3 threads used to parallelize FFTs (node-level). Default: 1. N1 and N2 are recommended over N3. N1 is usually more efficient than N2, but requires more memory. | |
| `-sp` | Simulation path, array of the size of the simulation grid containing values that specify the simulation path (from low to high). Default is a random path. Equal values are accepted but will always be ordered in the same way (i.e. not random). -&infin; values are not simulated. In case of multiple variables, a vector simulation is default (same path for all variables) and the simulation path should be one dimension less than the number of variables. If you prefer a full simulation, provide an array containing the path for each variable and use the "-fs" flag below. | |
Expand All @@ -35,6 +35,7 @@ Outputs: sim = simulation, index = index of the simulated values in the flattene
| Flag | Description | Mandatory |
| ---- | ----------- | --------- |
| `-ii` | Array that specifies for each pixel which training image to sample from. Default: all training images are searched for the best match. | |
| `-kii` | Array that specifies for each pixel which kernel to use. Useful if you want different weight fields when simulating different parts of the di, or if you want certain covariables to only influence parts of your di (e.g. you want a surface variable to only influence the simulation of the top subsurface layer). Usage: provide a list of full kernels in -ki, and only a single image for -kii to specify which full kernel to use at which pixel. | |
| `-ni` | Array that specifies for each pixel which the number of neighbors. | |
| `-kvi` | Array that specifies for each pixel which the number of best candidates to consider. | |
| `-far` | Fast and risky &#x1f604;, like -ii but with a random input (experimental). | |
Expand All @@ -46,6 +47,7 @@ Outputs: sim = simulation, index = index of the simulated values in the flattene
| `--forceSimulation` | Restimulate a value even if already existing. | |



## Examples
Below are several examples showcasing different applications of QS. For these examples the G2S server should be installed and running, either on your own machine or remotely. A Google Colab notebook with more examples and an automatic installation of G2S can be found [here](https://github.com/GAIA-UNIL/Short-course-MPS/blob/main/MPS_SC_with_QS_Online.ipynb).

Expand Down
2 changes: 1 addition & 1 deletion runTheServer.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ toc-depth: 2

# Run the server
Simply run `g2s server` to launch the server, optionally accompanied by any of the below settings. Alternatively, run `g2s enable` to launch the server and make sure it relaunches at start-up when you reboot your machine (and run `g2s disable` to disable this service again).
If you did not install g2s through linuxbrew but chose the manual installation from source instead, launch the server by running `./server` from within the G2S/build/c++-build (or G2S/build/intel-build for the intel version).
If you did not install g2s through linuxbrew but chose the manual installation from source instead, launch the server by running `./g2s_server` from within the G2S/build/c++-build (or G2S/build/intel-build for the intel version).

ⓘ The server generates logs- and data-files in subfolders /tmp/G2S/logs and /tmp/G2S/data that are saved for debug purposes. They are currently automatically removed at the reboot of the computer, at the launch of the server or after one day. This parameterization can be changed with -kod and -age.

Expand Down

0 comments on commit e1d4aee

Please sign in to comment.