Data and code contained in this folder correspond to that which is presented in the paper: 'Portable system for flexible micro-endoscopy using a multi-mode fibre' -------------------------------------------------------------------------------------------- Contents -------------------------------------------------------------------------------------------- The folder structure is as follows: -ProcessData.m |-BendImaging ||-Fibre ||-Objects ||-TM0 ||-TM1 ||-TM2 ||-TM3 ||-TM4 ||-TM5 |-BendSeries ||-Images ||-Videos |-SpeckleData We advise the user to maintain files and folders in this organisational tree as the code references the data across these folders. -------------------------------------------------------------------------------------------- Folder Descriptions -------------------------------------------------------------------------------------------- -BendImaging- contains the data used in this work as recorded by the photo detectors for the bend series taken with different static objects. The objects are recorded in the folder 'Objects' and the fibre shapes in the folder 'Fibre'. Each of the recording locations is stored within a folder corresponding to the TM used to take the data as labelled by the folder titles. This data is processed to make Figures 3 and 4 as well as Figures S2 b, c, and d of the supplementary. -BendSeries- contains the files pertaining to the videos of the chess flythroughs and handheld videos in taken in the office space. This data is processed to make Figures 5, 6, and 7 and make all supplementary videos. The images subfolder contains images of a the 'Magpie' object which are used to make Figure S3a of the supplementary. -SpeckleData- contains the images of the speckle output of the fibre as it bends for a fixed input. This was used to inform the locations at which calibration was to be performed by taking the pair-wise cross correlation between the output camera images. This data was used in making Figure S3b of the supplementary. -------------------------------------------------------------------------------------------- Running the Code -------------------------------------------------------------------------------------------- After downloading the code and data extract all folders and ensure the extracted folders are organised as above. The data, both raw and pre-processed, should already be in the required folders so each script should run directly without prerequisites. Simply running ProcessData.m at this stage should run and generate the figures and videos. These results should already be present in their respective folders. It is also possible to run the code in sections performing the processing required for just one of the figures or videos. These are not interdependent as long as the pre-processed .mat files are available. These files are available by default. Time consuming subroutines are commented out of the code initially so that running the code is more streamlined. For this reason the code relies on pre-processed data which is present in .mat files located in the necessary directories. It is possible to run these subroutines to process the raw data which comes directly from the various cameras and sensors. To do this simply uncomment the commented code. Each of these routines will have a title describing what part of the processing they are responsible for. -------------------------------------------------------------------------------------------- Versions and Benchmarking -------------------------------------------------------------------------------------------- MATLAB scripts were all written on MATLAB-2020a however the code is expected to give identical results for versions of MATLAB after 2019a and should run on versions from 2015b onwards. All code was run a Dell G5 15 with an Intel Core i7-9750H CPU at 2.60GHz and 16GB of RAM. -------------------------------------------------------------------------------------------- Correspondence -------------------------------------------------------------------------------------------- Questions and comments are welcomed by the authors and can be directed to Prof. Miles Padgett at Miles.Padgett@glasgow.ac.uk