Sign inSign up

danielzt12/dude

By danielzt12

•Updated about 1 year ago

diffraction user data explorer

Image
Data science
1

1.3K

danielzt12/dude repository overview

GUI data explorer for the APS 26-ID-C beamline

This is a relatively clean version of the dude that does not have all the beamline related features.

The new instruction does not require installing Docker Desktop which is not free for commercial use and is banned in most national labs.

The new instruction has only been updated for OS X thus far.

To run it on OS X: [updated 2025/03/19]

Step 1

Get homebrew⁠.

brew install socat

brew install xquartz (this can also be installed from here⁠ )

brew install docker (this only installs the docker cli which is free)

brew install colima

Step 2

Open xquartz preferences, go to security and turn on allow connections from network clients

find out your IP. You can try typing in a terminal window

ifconfig en0

Step 3

Open a terminal window, and type

socat TCP-LISTEN:6000,reuseaddr,fork UNIX-CLIENT:\"$DISPLAY\"

In a separate terminal window, type

colima start --network-address

In the same terminal window (as colima), type

docker run -v path_to_data:/data:ro --rm -e DISPLAY=YOUR_IP_HERE:0 danielzt12/dude:VERSION_NUMBER

VERSION_NUMBER is something like 3.0.0

path_to_data is the path to data on your Mac, for instance /Users/your_name/Documents

You will find your data under /data in dude

To run it on Linux:

Follow instructions here⁠ and here⁠ first after docker installation.

docker run --net=host --env="DISPLAY" --volume="$HOME/.Xauthority:/root/.Xauthority:rw" danielzt12/dude:VERSION_NUMBER

VERSION_NUMBER is something like 3.0.1

To run it on Windows:

Step 0:

1 Install VcXsrv from https://sourceforge.net/projects/vcxsrv/⁠⁠

2 Run Xlaunch from the start menu, select multiple windows, start no client, and click on disable access control

Save the configuration to %userprofile%\Desktop

Step 1:

Pressing the Windows log key, typing “Turn Windows features on and off” and open it. Scroll to the bottom and make sure "Windows Subsystem for Linux" is enabled.

In a powershell, type

Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Windows-Subsystem-Linux

Step 2:

Open a powershell with admin privileges (right click, run as admin)

type

wsl --set-default-version 2

wsl --install -d Ubuntu

Step 3:

In Windows search button, click on Ubuntu on Windows, and follow the instructions here under section "Install using the apt repository"

https://docs.docker.com/engine/install/ubuntu/⁠

pause after step 2, type sudo service docker start, then run the hello-world example in step 3

Step 4:

Open a powershell and type wsl

Create a mount point under /mnt/z

sudo mkdir -p /mnt/z

Mount your data folder to /mnt/z

sudo mount -t drvfs D:/data /mnt/z

Here we assume your data is under D:/data

Type ls /mnt/z to check if you can see your data file

Step 5: (in the future you should only need to repeat this step)

Open a powershell, type ipconfig to find out your IP

In the same powershell terminal, set the environmental variables with

set-variable -name DISPLAY -value YOUR_IP_HERE:0.0

In the same powershell terminal,type

wsl docker run -v /mnt/z:/data --rm -e DISPLAY=$DISPLAY danielzt12/dude:VERSION_NUMBER

VERSION_NUMBER is something like 3.0.1

Once you have dude open, you will find the same data mounted under /data

To find this folder, click any folder and go up in the folder tree.

If you have permission issue, try adding sudo between wsl and docker in the above command.

3.0.4

Added saving to .vti with the RSM3D widget.

Added azimuthal / detector for show angles.

3.0.3

Added RSM3D widget.

3.0.1

Resumed docker uploads after switching to docker-cli.

This one should work with the gen-2 nanoprobe instrument after APS-U.

2.7.4

XRF mode now shows calibrated energy.

2.7.3

Minor bug fix.

2.7.2

Minor bug fix.

2.7.1

Added support for reading flyscan spectra (netCDF4).

2.7.0

Added xrf_mode, supporting per pixel view of XRF spectra.

2.6.1

Fixing bugs in stretching, added hist in 2D, avg x in 2D, avg y in 2D.

Added support to automated logbook (only available at beamlines)

2.6.0

Added support for pump probe mode of Eiger detector.

Added support for Analyze5D on motors other than the hybrids.

Fixed an issue with RoI integration on interrupted scans.

2.5.5

Fixed an error in 5D analysis when calibration file is unavailable.

2.5.4

Added SIFT to ShiftCorrection. Fixed a bug in Shortcuts.

2.5.2

Renamed PilatusHelper to PowderHelper, added support for 1D scans.

2.5.1

bug fix for ShowMetadata.

2.5.0

Adding flip, stretch to Shortcuts, overview map now also works with coarse motor scans.

2.4.4

minor updates on Analyze5D

2.4.3

Added 5D analysis result saving to .svg

2.4.0

ShiftCorrection and Analyze5D are now available!

2.3.4

fixed an issue where the sparse matrices data are truncated

2.3.3

reduce memory usage when generating sparse matrices

2.3.2

roi_to_mat now saves the mat file under the h5 folder

2.3.1

minor bug fix

2.3.0

added show metadata

2.2.1

added export to matlab files

2.2.0

added scale bar

added dirty fix for the first point bug with the eiger data

2.1.0

comX, comY (in Shortcuts) now work with sparse matrices

reworked how plot 2d maps react to left and right mouse clicks

2.0.0

added compatibility with eiger and sparse matrices

Tag summary

Content type

Image

Digest

sha256:863bdf05d…

Size

614.2 MB

Last updated

about 1 year ago

docker pull danielzt12/dude