Andrés M Cardozo Gizzi

Sergio M Espinola

Julian Gurgo

Christophe Houbron

Jean-Bernard Fiche

Diego I Cattoni

Marcelo Nollmann
email: marcelo.nollmann@cbs.cnrs.fr

Direct and simultaneous observation of transcription and chromosome architecture in single

Keywords: fluorescence microscopy, fluorescent in situ hybridization, 3D genome architecture, topologically associating domains, transcription, Drosophila development, genome organization, chromosome conformation, chromatin

ou non, émanant des établissements d'enseignement et de recherche français ou étrangers, des laboratoires publics ou privés.

Introduction

Genomes are folded in a hierarchical organization that reflects and contribute to regulating transcription and other processes [START_REF] Bonev | Organization and function of the 3D genome[END_REF] . However, our current understanding of chromatin architecture and how it is related to transcriptional regulation remains limited. In the last decade, two strategies became mainstream to study chromatin folding: chromosome conformation capture (3C and derivatives) and microscopy-based methods. 3C-like methods are powerful as they provide genome-wide information with kilobase (kb) resolution, but have several limitations: (1) most often they rely on population averaging, (2) they retrieve relative frequencies of pairwise interactions, (3) they have relatively low detection efficiency in single cells (<10% of the total contacts), (4) they are unable to provide spatial information (within the cell or the organism/ tissue), and (5) they do not permit simultaneous measurement of transcription and chromosome structure [START_REF] Giorgetti | Closing the loop: 3C versus DNA FISH[END_REF] . Microscopy-based strategies on the other hand, employ fluorescence in situ hybridization (FISH) to target specific loci and can access their 3D position inside the nucleus, but until very recently were limited to the detection of a small number of genomic locations (typically 3-4). We and others have recently overcame several of these limitations to reconstruct chromatin architecture and detect transcriptional status at the same time in single-cells while retaining spatial information. This new technology, that we termed Hi-M (high-throughput, high-resolution, high-coverage microscopy-based technology, see below), addresses these shortcomings by employing high-throughput synthesis of short oligonucleotide (oligo) probes combined with RNA labeling and multiple rounds of hybridization in a sequential imaging scheme enabling the measurement of transcriptional state and the localization of tens of different genomic loci within intact Drosophila embryos [START_REF] Cardozo Gizzi | Microscopy-Based Chromosome Conformation Capture Enables Simultaneous Visualization of Genome Organization and Transcription in Intact Organisms[END_REF] . Similar approaches have also been employed in concurrent work [START_REF] Bintu | Super-resolution chromatin tracing reveals domains and cooperative interactions in single cells[END_REF][START_REF] Nir | Walking along chromosomes with super-resolution imaging, contact maps, and integrative modeling[END_REF][START_REF] Mateo | Visualizing DNA folding and RNA in embryos at single-cell resolution[END_REF] .

Principle of the method

Hi-M builds on recent innovations in FISH probe design based on high-throughput microarray oligos synthesis, namely Oligopaints [START_REF] Beliveau | Versatile design and synthesis platform for visualizing genomes with Oligopaint FISH probes[END_REF][START_REF] Beliveau | Single-molecule super-resolution imaging of chromosomes and in situ haplotype visualization using Oligopaint FISH probes[END_REF] and on the pioneering design of multiplexing schemes for detecting hundreds of RNA species by imaging [START_REF] Lubeck | Single-cell in situ RNA profiling by sequential hybridization[END_REF][START_REF] Chen | RNA imaging. Spatially resolved, highly multiplexed RNA profiling in single cells[END_REF] . A microarray library with thousands of oligonucleotides (oligopool) is bioinformatically designed and commercially synthesized to target tens of different genomic locations. Each genomic locus (typically spanning 2-10 kb) is targeted by a unique set of 20-70 tiled oligos. We will refer to the genomic regions covered by these unique set of oligos as 'barcodes'. Each oligo in a barcode contains three parts, a region of genomic homology, a barcode-specific readout sequence; and a priming region for PCR amplification (see Experimental design section). Labeling involves four steps. First, the oligopool library is enzymatically amplified and purified. Second, embryos are collected and fixed. Third, embryos are labeled by an RNA hybridization and signal amplification step. Fourth, the oligopool is hybridized to genomic DNA. After labeling, samples are mounted onto a microfluidic chamber connected to a microfluidics pump system and mounted into an automated widefield fluorescence microscope. In an initial round, DAPI and RNA signals are acquired in multiple regions of interest (ROIs). Then, the imaging of each barcode requires: (1) labeling of the sample with barcode-specific, fluorescently-labeled readout oligonucleotides (readout probes); (2) removal of unbound readout oligos by washing; (3) acquisition of 3D, two-color images for all ROIs and (4) photobleaching. This process is repeated sequentially for each barcode. In all sequential rounds, a second, spectrally different, fluorescent oligo is present and used as the fiducial barcode for drift correction. Next, images are processed to: segment DNA masks, determine the transcriptional status of each cell, retrieve the 3D position of each barcode in every ROI with sub-pixel accuracy, and correct drift during acquisition and between cycles of hybridization. Finally, the 3D coordinates of each barcode detected in each cell are used to reconstruct Hi-M matrices containing mean pairwise distances and absolute contact probabilities.

Applications of the method

We have developed Hi-M to explore genome architecture and transcription in intact Drosophila embryos. However, Hi-M can be used in a large variety of model systems. For instance, adaptation to cultured cells should be straightforward. Cultured cells can be readily attached to the coverslip by standard procedures (e.g. by growing them in treated coverslips conductive of cell adhesion). In fact, cultured cells exhibit lower auto-fluorescence than organisms, thus the application of Hi-M should result in an increased barcode detection and localization precision. Hi-M could also be adapted to thick tissues and organoids by relying on cryo-sectioning [START_REF] Moffitt | Molecular, spatial, and functional single-cell profiling of the hypothalamic preoptic region[END_REF] or on optical-sectioning.

The RNA/DNA staining procedures described in this protocol are fully compatible with other imaging modalities, such as 3D Structured Imaging Microscopy (3D-SIM) or Stochastic optical reconstruction microscopy (STORM) [START_REF] Bintu | Super-resolution chromatin tracing reveals domains and cooperative interactions in single cells[END_REF][START_REF] Nir | Walking along chromosomes with super-resolution imaging, contact maps, and integrative modeling[END_REF] . The acquisition of super-resolution images is typically slower than for wide-field microscopy images, therefore limiting the throughput of a Hi-M acquisition. Thus, a compromise between resolution and throughput will have to be found depending on the problem under study. In addition, most super-resolution microscopies are not well adapted to thick specimens, thus their use in Hi-M will be mainly limited to thin samples.

The flexibility afforded by Oligopaints in the design of probes would enable the adaptation of Hi-M to explore chromosome conformation at different length scales (e.g. chromosomal [START_REF] Rosin | Condensin II drives large-scale folding and spatial partitioning of interphase chromosomes in Drosophila nuclei[END_REF] , compartment [START_REF] Nir | Walking along chromosomes with super-resolution imaging, contact maps, and integrative modeling[END_REF] or TAD levels [START_REF] Cardozo Gizzi | Microscopy-Based Chromosome Conformation Capture Enables Simultaneous Visualization of Genome Organization and Transcription in Intact Organisms[END_REF][START_REF] Mateo | Visualizing DNA folding and RNA in embryos at single-cell resolution[END_REF] ). In the present protocol, barcodes contain ~20-90 primary oligos and cover 2-10 kb to produce diffraction-limited spots and ensure excellent signal-to-noise ratios (SNR, defined as the maximum intensity of a spot divided by the standard deviation of the background). Labeling of smaller genomic regions is possible but at the expense of reduced SNR levels (i.e. reduced localization precision).

Limitations

A current limitation of Hi-M is the time required for the acquisition of an entire dataset: typically 2-3 days to image 50-70 barcodes in 30 fields of view (representing ~50000 cells for Drosophila embryos). Thus, typically a balance between experimental time and the number of barcodes imaged needs to be found. For instance, 70 barcodes could be used to image an extended genomic region (e.g. 3.5 Mb) at low resolution (50 kb between barcodes), or to image a single genomic locus (e.g. 150kb) at high resolution (~2kb).

A second limitation is the minimal number of primary probes per barcode. The values provided in this protocol (see Experimental Design section) ensure robust detection with high localization precision. A reduction in the number of primary probes could lead to decreased levels of detection and degraded localization precision. A possible future solution to this limitation may be to increase the number of imaging probes by encoding more readout probes per barcode (e.g. using SABER-FISH [START_REF] Kishi | SABER enables highly multiplexed and amplified detection of DNA and RNA in cells and tissues[END_REF] ), but ultimately this approach may limit the specificity of labeling.

A third limitation is the reduced efficiency of barcode detection, currently close to 60-70%. Thus, a barcode is observed in only ~6-7 out of 10 nuclei. This entails a reduced number of cells containing all barcodes.

A fourth limitation arises from the high cost of fluorescently-labeled oligos (~500$ each). As each barcode is detected by a specific fluorescently-labeled readout probe, the price of an experiment increases linearly with the number of barcodes. A new strategy that can considerably reduce the experimental cost has been recently described in two publications [START_REF] Mateo | Visualizing DNA folding and RNA in embryos at single-cell resolution[END_REF][START_REF] Fields | A multiplexed DNA FISH strategy for assessing genome architecture in Caenorhabditis elegans[END_REF] . Instead of using a fluorescently labeled oligo for each barcode, a combination of two oligos is used: a non-fluorescent oligo specific for each barcode (bridge oligo) and a single fluorescent oligo common to all barcodes (imaging oligo). The bridge oligo contains 20 nucleotides (-nt) complementary to the barcode sequence, followed by a 10-nt "toehold" spacer sequence and a 20-nt sequence complementary to the imaging oligo [START_REF] Lidke | Sequential Super-Resolution Imaging using DNA Strand Displacement[END_REF] . With this design, the same fluorescently-labeled imaging oligo can be used to read all barcodes, with barcode specificity provided by the bridge oligo. Furthermore, this strategy can also be exploited to remove the fluorescence after each imaging cycle by the use of displacement oligos. Displacement oligos are complementary to the "toehold" and bridge probe sequences, therefore they displace the bridge probe from the barcode and in doing so they also remove the imaging probe.

A final limitation relies on the ability of Hi-M to detect several RNA species at once. The Hi-M protocol described here enables the simultaneous detection of chromosome conformation together with a single RNA species. In future, additional RNA species could be labeled by using a sequential TSA reaction with alternative conjugation molecules (e.g. biotin) or by relying on oligonucleotide-derivatized antibodies. It is worth noting that TSA amplification is non-linear, therefore quantification of RNA levels requires proper calibration.

Comparison with other methods

Compared to traditional FISH, Hi-M has two main advantages: (1) it uses oligo probes, that provide design flexibility and higher efficiency of labeling compared to double stranded BAC or amplicon-based probes [START_REF] Roohi | An improved method for generating BAC DNA suitable for FISH[END_REF][START_REF] Bienko | A versatile genome-scale PCR-based pipeline for high-definition DNA FISH[END_REF] , and (2) it employs a multiplexed approach that does not rely on the use of spectrally different fluorophores (limited to 2-4 in most applications). The overall strategy of Hi-M is conceptually similar to recent work employing sequential imaging schemes and oligopaint labeling [START_REF] Bintu | Super-resolution chromatin tracing reveals domains and cooperative interactions in single cells[END_REF][START_REF] Nir | Walking along chromosomes with super-resolution imaging, contact maps, and integrative modeling[END_REF][START_REF] Mateo | Visualizing DNA folding and RNA in embryos at single-cell resolution[END_REF][START_REF] Wang | Spatial organization of chromatin domains and compartments in single chromosomes[END_REF] . The main differences with these studies are: (1) Hi-M enables simultaneous detection of RNA status and chromosome organization without sample unmounting and probe re-hybridization. Other approaches also enable RNA/DNA detection, but require the hybridization and imaging of RNA probes, unmounting of the sample followed by degradation of RNA, hybridization of DNA probes, and then remounting and imaging of the same cryo-sectioned samples 6 ; (2) Hi-M allows, in contrast with other studies [START_REF] Bintu | Super-resolution chromatin tracing reveals domains and cooperative interactions in single cells[END_REF][START_REF] Nir | Walking along chromosomes with super-resolution imaging, contact maps, and integrative modeling[END_REF][START_REF] Mateo | Visualizing DNA folding and RNA in embryos at single-cell resolution[END_REF] , for the imaging of entire, intact organisms.

Multiplexing has also been recently achieved in the single-cell imaging of multiple RNA species [START_REF] Chen | RNA imaging. Spatially resolved, highly multiplexed RNA profiling in single cells[END_REF][START_REF] Moffitt | Molecular, spatial, and functional single-cell profiling of the hypothalamic preoptic region[END_REF][START_REF] Shah | Dynamics and Spatial Genomics of the Nascent Transcriptome by Intron seqFISH[END_REF][START_REF] Eng | Profiling the transcriptome with RNA SPOTs[END_REF] . These studies used combinatorial schemes to target ~140 [START_REF] Chen | RNA imaging. Spatially resolved, highly multiplexed RNA profiling in single cells[END_REF][START_REF] Moffitt | Molecular, spatial, and functional single-cell profiling of the hypothalamic preoptic region[END_REF] to ~10,000 genes [START_REF] Shah | Dynamics and Spatial Genomics of the Nascent Transcriptome by Intron seqFISH[END_REF][START_REF] Eng | Profiling the transcriptome with RNA SPOTs[END_REF] using only ~20 hybridization cycles. RNA is typically present in many copies per cell and these copies are spatially well separated, making it possible to decode species using combinatorial approaches. Currently, the use of combinatorial approaches to label DNA are limited by the spatial overlap of barcodes, the small number of DNA molecules detected (typically 1-4 depending on ploidy), and by the reduced efficiency of detection (~60%, see above). Excitingly, combinatorial approaches based on other principles 14 may be usable in the near future to considerably increase the number of detected barcodes without a linear increase in the number of hybridization cycles.

Hi-M and similar approaches based on FISH are carried out in fixed samples, thus they cannot provide dynamic information. Live imaging of single genomic loci has been achieved using a catalytically inactive Cas nuclease that is targeted to a loci by a small guide RNA (sgRNA) (for a review see [START_REF] Wu | Progress and Challenges for Live-cell Imaging of Genomic Loci Using CRISPR-based Platforms[END_REF] ). Typically CRISPR-based imaging records the position of two genomic loci, although targeting up to 6 genomic loci has been achieved for repetitive sequences [START_REF] Ma | Multiplexed labeling of genomic loci with dCas9 and engineered sgRNAs using CRISPRainbow[END_REF] . Imaging non-repetitive sequences has been proven challenging due to the complexity of simultaneously co-expressing multiple sgRNA species in one cell. Furthermore, off-target binding and background fluorescence can further limit the application of current CRISPR-based imaging methods. More recently, a radically different approach successfully followed the 3D position of a single gene in real time while simultaneously monitoring mRNA synthesis in the same cell [START_REF] Germier | Real-Time Imaging of a Single Gene Reveals Transcription-Initiated Local Confinement[END_REF][START_REF] Chen | Dynamic interplay between enhancer-promoter topology and gene activity[END_REF] by combining stem-loop-based labeling (MS2 and/or PP7 [START_REF] Yunger | Single-allele analysis of transcription kinetics in living mammalian cells[END_REF][START_REF] Larson | Real-time observation of transcription initiation and elongation on an endogenous yeast gene[END_REF][START_REF] Fukaya | Enhancer Control of Transcriptional Bursting[END_REF] ) and the ParS/ParB system [START_REF] Saad | DNA dynamics during early double-strand break processing revealed by non-intrusive imaging of living cells[END_REF] . This approach was used to study the position of a genomic locus and a transcription spot at the same time in living Drosophila embryos [START_REF] Chen | Dynamic interplay between enhancer-promoter topology and gene activity[END_REF] . This approach requires genetic manipulation to introduce ectopic sequences, and is limited at present to a maximum of two colors (typically a transcript and a genomic locus).

Experimental design

The Hi-M protocol presented here (Fig. 1) consists in the design and amplification of Oligopaint probes (steps 1-39 and Fig. 2), collection and fixation of Drosophila embryos (steps 40-50), RNA and DNA labeling of embryos (steps 51-92), sample mounting (steps 93-100 and Fig. 3), sequential imaging of multiple genomic locations (steps 101-116 and Figs. 4-6), and image processing and analysis (steps 117-149 and Fig. 78) in order to reveal chromatin organization and its relationship with the transcriptional status of single nuclei (Fig. 9).

Oligopaint probes. The method is based on massive oligonucleotide synthesis to design probes targeting the genomic locations of interest to perform a FISH-based labeling approach [START_REF] Boyle | Fluorescence in situ hybridization with high-complexity repeat-free oligonucleotide probes generated by massively parallel synthesis[END_REF] . This protocol describes how to design a library and amplify Oligopaint probes. Oligonucleotide primary probes contain three regions (Fig. 2): (1) a region of genomic homology composed of 42-nt complementary to the target locus, (2) a readout region composed of 32-nt complementary to a readout oligo bearing a fluorophore, and (3) two flanking 20-nt regions containing primers for the PCR amplification of the whole Oligopaint library. With this design, it is possible to include 2 readout sequences per primary oligo, in the 5'-and 3'-ends of the genomic homology region.

The design pipeline implemented in the current protocol is based on a previous development by Beliveau et al. [START_REF] Beliveau | Single-molecule super-resolution imaging of chromosomes and in situ haplotype visualization using Oligopaint FISH probes[END_REF] and requires the user to input the genomic region of interest and the number of probes per barcode or, alternatively, the genomic size per barcode (Fig. 2a). The unique sequences were mined using OligoArray [START_REF] Rouillard | OligoArray 2.0: design of oligonucleotide probes for DNA microarrays using a thermodynamic approach[END_REF] and are available online for a variety of species (Oligopaint website, https://oligopaints.hms.harvard.edu/ ). An alternative for the design of oligopaint primary probes, although limited to the human genome, is the use of the web interface ( http://ifish4u.org ) that allows for the selection of specific sets of oligos in a user-friendly environment including ~400 validated probes [START_REF] Gelali | iFISH is a publically available resource enabling versatile DNA FISH to study genome architecture[END_REF] . Of note, a recent development, OligoMiner [START_REF] Beliveau | OligoMiner provides a rapid, flexible environment for the design of genome-scale oligonucleotide in situ hybridization probes[END_REF] , relieve the use of online databases as it is capable of discovering thousands of oligo probes in minutes, tailoring the design of each probe set to the experimental question at hand.

A minimal number of primary oligos per barcode is needed for a high enough SNR to detect barcodes with high localization precision. Currently, we use a minimum of 40 primary oligos/barcode (i.e. 80 fluorophores per barcode). This number is comparable to the 48 fluorophores used typically for single-molecule RNA FISH [START_REF] Raj | Imaging individual mRNA molecules using multiple singly labeled probes[END_REF] . Given an average of 12 unique primary oligos per kb in Drosophila [START_REF] Beliveau | OligoMiner provides a rapid, flexible environment for the design of genome-scale oligonucleotide in situ hybridization probes[END_REF] , a probe can be as short as ~3 kb. In the human genome, the average number of primary oligos/kb is considerably lower, thus we would recommend using a probeset spanning ~5 kb to ensure robust detection is most systems and conditions. Recently, a different oligo dataset has been mined with a higher density of probes/kb [START_REF] Gelali | iFISH is a publically available resource enabling versatile DNA FISH to study genome architecture[END_REF] ., possibly enabling for a reduction in the genomic size of the barcode. The fiducial barcode requires additional considerations, as it will need to be repeatedly imaged in each cycle of hybridization (i.e. it will suffer more from photobleaching than standard barcodes). Thus, we recommend using a higher number of primary oligos for the fiducial barcode (e.g. 200 oligos spanning ~20 kb). Currently, we fit the position of the fiducial barcode by using a 3D Gaussian function, as the image of this barcode is a diffraction-limited spot. It is important to realize that if the genomic region occupied by the fiducial barcode becomes too large, its image in the camera will not be diffraction-limited. This would need to be taken into consideration for the fitting of the position of this barcode by appropriate modifications in the analysis pipeline.

For library amplification, the protocol follows a strategy previously introduced by Moffitt and Zhuang for the detection of RNAs using combinatorial approaches [START_REF] Moffitt | RNA Imaging with Multiplexed Error-Robust Fluorescence In Situ Hybridization (MERFISH)[END_REF] . In short, library amplification consists of four steps: (1) the Oligopaint library is PCR-amplified using a reverse primer that adds the T7 promoter sequence, (2) the PCR product is converted to RNA via an in vitro transcription using T7 polymerase, (3) single-stranded DNA is generated via reverse transcription, and (4) the RNA template is degraded using alkaline hydrolysis (Fig. 2b). Quality and concentration are monitored during the different steps to ensure the success of the amplification and purification process (Fig. 2 c-e).

Embryo collection and fixation. The protocol here does not deviate much from a previously published protocol [START_REF] Trcek | mRNA quantification using single-molecule FISH in Drosophila embryos[END_REF] . Flies lay embryos on yeasted agar plates for 1.5 h. Plates are incubated at 25 °C until embryos reach the desired developmental stage. Embryos are then collected, dechorionated by the use of bleach, thoroughly rinsed with water and immediately fixed by using formaldehyde and formaldehyde-saturated heptane. Fixative is then removed, methanol added and embryos vortexed. Embryos that sank to the bottom of the tube are devitellinized, which is critical to allow penetration of FISH probes into the sample. Devitellinized embryos are washed with methanol and stored at -20 °C until further use.

RNA & DNA FISH. The protocol has two main steps: RNA in situ hybridization followed by DNA Oligopaint FISH. To ensure RNA signal preservation after DNA FISH, tyramide signal amplification (TSA), adapted from a previous protocol [START_REF] Shpiz | Combined RNA/DNA fluorescence in situ hybridization on whole-mount Drosophila ovaries[END_REF] is performed. The single-stranded digoxigenin-labeled RNA probe is obtained from an in vitro transcription reaction in the presence of digoxigenin haptenes as described elsewhere [START_REF] Cardozo Gizzi | Microscopy-Based Chromosome Conformation Capture Enables Simultaneous Visualization of Genome Organization and Transcription in Intact Organisms[END_REF][START_REF] Boettiger | Rapid transcription fosters coordinate snail expression in the Drosophila embryo[END_REF] . RNA probes are targeted with a specific antibody that is coupled to horseradish peroxidase (HRP). HRP then reacts with hydrogen peroxide creating tyramide free radicals from fluorophore-labeled tyramide, that will covalently bind to the vicinity of the RNA probe. It is possible to label a second RNA species by performing a sequential, second antibody/HRP incubation against a biotinylated probe. In any case, controls should be made to ensure specificity of the RNA probe/s. In our previous paper [START_REF] Cardozo Gizzi | Microscopy-Based Chromosome Conformation Capture Enables Simultaneous Visualization of Genome Organization and Transcription in Intact Organisms[END_REF] , we labeled the snail gene, that has a distinctive spatial expression pattern that can be used to assert signal specificity. However, we did include a control sample without RNA probe to establish the expected background levels. In case the expression pattern of the target gene is homogenous (or unknown), an anti-sense probe can be used to verify that the sense probe is actually binding to the target RNA.

After the TSA reaction, DNA FISH is performed based on a previous method 38 that we have optimized for Oligopaint hybridization.

Embryo attachment. Firm attachment of embryos to the flow chamber coverslip is essential to resist the pressure from non-continuous flow rates during a 2-3 day experiment. To this end, embryos are deposited and oriented on an agarose pad and then transferred to a glass coverslip coated previously with poly-L-lysine. The microfluidics chamber is then assembled and the system filled with liquid. The complete procedure is shown in Fig. 3.

For a different type of sample, tests should be performed to assure stable attachment. This should not be a problem if adherent cells are used. A control with a labeled sample (e.g. using fiducial markers), imaged before and after a certain period of time (~30 min) of continuous flow and at the beginning and at the end of a full experiment should be performed to assess sample stability and stage drift. The software analysis pipeline corrects for stage drift (see Image analysis section), but if the sample become loose or detaches during the experiment, drift correction would not be possible.

Image acquisition. Hi-M requires three acquisition steps. The pre-sequential step involves the acquisition of 3D bright-field, and multi-color fluorescence images for each ROI. The channels in the pre-sequential step are as follows: [channel 1] 3D image for DNA masks (DAPI-stained nuclei, excited using the 405 nm laser line); [channel 2] 3D image for RNA (RNA-stained embryos excited using the 488 laser line); [channel 3] 3D image of the fiducial barcode used for image registration (obtained by using the 561 nm laser line).

The sequential imaging acquisition step involves sequential imaging of barcodes. For each cycle of hybridization (see below) a 3D, two-color fluorescence image is acquired: [channel 1] 3D image of the fiducial barcode (excitation using the 561 nm laser line); [channel 2] 3D image of the N -th barcode (acquired using the 641 nm laser line). Thus, for N cycles of hybridization and k ROIs one obtains k(2N+4) three-dimensional images. In a typical experiment with 10 embryos (~30 ROIs) and 22 barcodes, one needs to analyze a total of 1440 3D images. In our current implementation, the acquisition time for 22 barcodes and ~30 ROIs (i.e. 7-9 embryos) is around 24 h. This time scales linearly with the total number of barcodes and ROIs. Drosophila embryos in nuclear cycle 14 have ~6,000 nuclei, thus ~25,000 nuclei can be retrieved in a single experiment.

Each cycle of hybridization involves the following steps: (1) injecting a solution containing the fluorescent readout oligo that will hybridize to the complementary sequence of the primary oligos of a barcode, (2) washing non-specifically bound or unbound readout oligos with a formamide-containing solution, (3) injecting an imaging solution including an oxygen scavenger enzymatic reagent to prevent photobleaching during acquisition, (4) stopping flow and perform the sequential imaging step described above for all desired ROIs, (5) bleaching barcodes (see below).

The bleaching step can be achieved by different means: (1) light-induced photobleaching using a high-power laser. The implementation of this option is straightforward but the time required for photo-bleaching all ROIs scales linearly with the number of acquired ROIs; (2) chemical bleaching. This option requires the fluorescent molecule in the readout oligo to be attached via a disulfide linkage cleavable by the use of a mild reducing agent such as Tris(2-carboxyethyl)phosphine (TCEP) [START_REF] Moffitt | High-throughput single-cell gene-expression profiling with multiplexed error-robust fluorescence in situ hybridization[END_REF] . The advantage of this option is that all fluorophores are removed at once in a single step, making the bleaching time independent of the number of acquired ROIs. We note that if chemical photobleaching is employed, the fluorophore in the fiducial barcode needs to be resistant to the reducing agent (i.e. do not use a disulfide linkage).

In the final acquisition step, a 3D bright field image for each ROI is acquired for a second time. This image is used later to verify that embryos did not detach during acquisition (see Controls below).

Image analysis. The first image analysis step involves the deconvolution of images to remove out-of-plane light to increase the SNR and contrast. We perform this operation using Huygens (SVI, Nederlands).

The second step involves the comparison of bright-field images of embryos before and after sequential imaging. Embryos displaying any apparent movement or morphological distortion are discarded from further analysis.

Next, a custom-made code in MATLAB is used to perform the following image analysis steps after deconvolution (Figs. 78). The workflow starts with the segmentation of nuclei from pre-sequential images using a graphical user interface (GUI). A number of parameters can be pre-tuned (threshold, z-range, etc.) (Fig. 8) and manually modified in the GUI. Next, the GUI loads the stack, extracts the usable z-range, corrects for inhomogeneous excitation, and flattens the image by maximum intensity projection. Next, a detection algorithm with tunable parameters (threshold, intensity range, etc.) segments nuclei by using adaptive thresholding and water shedding. The masks are verified by the user and stored locally. Once parameters have been optimized and verified, all the ROIs can be analyzed in batch.

A similar procedure is used to segment barcodes. This procedure involves loading the image, extracting the z-range, correcting for inhomogeneous excitation, and segmentation by local thresholding. An estimate of the 3D positions of barcodes is obtained from the center of gravity of the masks segmented in this step. These 3D coordinates are next refined by using a 3D gaussian fitting algorithm.

Finally, a registration step is performed by image cross-correlation of the fiducial barcodes. A correction vector is derived and applied for each barcode. Corrected 3D barcode coordinates and nuclei masks are then used to determine which barcodes are associated with which nuclei. These data are used to calculate the mean absolute contact probabilities and normalized mean pairwise distances for each pair of barcodes (see heatmaps in Fig. 9).

Controls.

During in situ hybridization, chromatin is denatured by heating in the presence of formamide to enable the binding of primary probes. First, to ensure that this step did not affect the labeling of RNA, it is necessary to compare RNA intensities and distributions before and after DNA hybridization.

Second, it is important to take steps to quantify the efficiency of hybridization of primary probes and the efficiency of binding of imaging probes. For this, it is useful to measure the distribution, the SNR, and the number of barcode spots per cell. These measurements should be performed for each barcode in several embryos. Barcode spots should appear dense and uniform across the field of view. In Drosophila , we typically observe that ~60-70% of nuclei display barcode spots, reflecting the limited labeling efficiency. In these cells, ~80% contain a single barcode, consistent with a high degree of homologous pairing [START_REF] Fung | Homologous chromosome pairing in Drosophila melanogaster proceeds through multiple independent initiations[END_REF][START_REF] Cattoni | Single-cell absolute contact probability detection reveals chromosomes are organized by multiple low-frequency yet specific interactions[END_REF] . In mammalian cells instead, two barcode spots should be detected in most labeled cells. The typical SNR in our experiments was 50-500 after deconvolution. A reduced SNR could indicate incomplete binding of primary or imager oligos.

Third, a bright-field image is acquired before and after the experiment to ensure that embryos did not move during the experiment. During the analysis phase, it is verified that embryos did not change morphology or position during the experiment. Small-scale changes in embryos may happen during acquisition, such as inhomogeneous expansions/contractions of a few hundred nanometers. To account for these, fiducial marks are used. This allows us to both correct for stage drift as well as to account for any inhomogeneous expansion or contraction.

Forth, Hi-M matrices should be generated from different regions of interest and for different embryos to test that the data is highly correlated (Pearson test on the Hi-M pairwise distances and contact probabilities). Finally, a consolidated Hi-M contact probability matrix is built and compared with existing Hi-C datasets (Pearson test on contact probabilities). Additionally, it can be verified that TAD borders are located at the same genomic position for both datasets. When available, comparisons of Hi-M matrices with other sources of data (e.g. ChIP-seq, enhancer trapping) is also important to ensure the validity of the results.

Spatial resolution.

In our approach we avoid chromatic shift by using a single channel to record all barcodes. By recording in two channels, the number of hybridization cycles can be reduced by half. However, chromatic aberrations needs to be properly corrected, as described elsewhere [START_REF] Cattoni | Single-cell absolute contact probability detection reveals chromosomes are organized by multiple low-frequency yet specific interactions[END_REF] . Stage drift is inherently present and also needs to be corrected using fiducial labels. The reported residual error of fiducial barcodes after drift correction is around 80 ± 60 nm in xyz 3 . Ultimately, this will limit the minimal distance that can be resolved between any two barcodes.

Materials Biological materials

• Wild-type fruit flies (Bloomington Drosophila Stock Center) or the flies specified by the experiment.

Reagents

• 131-150 -nt Oligopool (CustomArray) To avoid the use of a mechanical filter-wheel, separation between excitation and emission light is done using a four-band dichroic mirror (zt405/488/561/640rpc-UF2, Chroma) combined with a four-band emission filter (ZET405/488/561/640m, Chroma). Finally, the objective lens is mounted on a single-axis piezo-stage (Nano-F100, Mad City Labs Inc.), allowing for a nm-precision control of the objective axial position during z-scan and focus stabilization.

A home-made focus stabilization system was used to compensate the axial drift in real-time. A 785 nm laser beam (OBIS-785, Coherent) is focused on the back-focal plane of the objective, reaching the coverslip/sample interface in near-TIRF illumination conditions. The position of the reflected beam is then measured on a position-sensitive detector (OBP-A-4H, Newport) and any variation in the objective-sample distance above 100 nm is automatically compensated by repositioning the objective lens. Hi-M sequential hybridization: Design for fluid handling circuits was implemented as described in Cardozo Gizzi et al [START_REF] Cardozo Gizzi | Microscopy-Based Chromosome Conformation Capture Enables Simultaneous Visualization of Genome Organization and Transcription in Intact Organisms[END_REF] . The sample is mounted in a FCS2 chamber and flow is created using a negative pressure pump. An online flow-unit is used to continuously monitor flow-rate, allowing for a precise control of injected volumes as well as for maintaining a steady flow in the chamber. Buffers and probes are selected using a combination of three eight-way HVXM8-5 valves. Finally, an online degassing unit is inserted before the fluidic chamber to avoid air-bubble nucleation during Hi-M experiments. User/microscope interface: Image acquisition, sample positioning and liquid handling are controlled by a custom-made software package developed in LabView 2015.

Procedure Design of Oligopaint libraries * Timing 4-5 h

1.

Download Oligopaint scripts [START_REF] Beliveau | Versatile design and synthesis platform for visualizing genomes with Oligopaint FISH probes[END_REF] and .bed files containing all primary oligos following the instructions in http://genetics.med.harvard.edu/oligopaints . CRITICAL STEP: .bed files contain the sequences of oligos previously mined using OligoArray [START_REF] Rouillard | OligoArray 2.0: design of oligonucleotide probes for DNA microarrays using a thermodynamic approach[END_REF] or OligoMiner [START_REF] Beliveau | OligoMiner provides a rapid, flexible environment for the design of genome-scale oligonucleotide in situ hybridization probes[END_REF] , covering the Drosophila non-repetitive genome.

2.

Define genomic locations of interest (barcodes) and use grabRegion.py to select the oligos corresponding to each barcode. Register the number of oligos in each barcode. CRITICAL STEP: Include also a fiducial barcode.

3.

An output text file is created with a list of oligos for each barcode. Concatenate all output files using a Linux command line.

4.

Create a unique text file with the readout sequences for all barcodes. It consists of a line for each barcode. In each line, add i) the 5' readout sequence, ii) the 3' readout sequence (repeat the previous sequence), iii) and the range of probes that compose the barcodes (i.e. 1-25, 26-50) based on the number of oligos in each barcode. Information i) to iii) must be separated with a Tab. Use the sequences from Supplementary Table 2. CRITICAL STEP: The sequences must be given 5' to 3'. 5.

Use order.py to add the readout sequences. It will require the full list of oligos from step 3 and the list of readout sequences to add from step 4. 6.

Use order.py in interactive mode (-i) with the output file from last step to add the sequence of the universal priming region. Use sequences from Supplementary Table 3.

CRITICAL STEP: It is possible to embed multiple libraries within one oligopool by using different sets of universal primers. 7.

Order the microarray from an oligopool synthesizer company. CRITICAL STEP: Companies typically require two weeks to synthesize a custom-made oligopool.

Amplification of

17.

Perform the small scale limited-cycle PCR by setting up the following reaction mix for 8 tubes as indicated in Table 2. CRITICAL STEP: The limited number of cycles is done to find the cycle number where the PCR is still at is exponential phase (Fig. 2c). Perform this step before proceeding to the large-scale PCR. CRITICAL STEP: The T7 promoter sequence (5'-TAATACGACTCACTATAGGGT-3') should be added to the reverse primer used for the emulsion PCR step to allow for the reverse transcription step. Run 20 µL of the PCR product in a 1.5 % agarose gel with 0.01% SYBR Safe at 100 V for 45 min. Find the cycle with a single band of the expected size and the maximum intensity (Fig. 2c). 20.

Perform a large scale limited-cycle PCR by running a reaction mix for 16 tubes as indicated in Table 3. This step will generate a big quantity of Oligopaints. CRITICAL STEP: The T7 promoter sequence should be added to the reverse primer to allow for the reverse transcription step. Collect the 50 µL-aliquots from the previous step in a 15 mL falcon tube and proceed to DNA column purification according to the manufacturer's instructions. CRITICAL STEP: Use Zymo DNA purification kit with 25 µg capacity. Elute using 30 µL of DNAse-and RNAse-free water.

24.

Quantify product concentration with a NanoDrop using double-stranded DNA parameters. This typically requires a 1/10 dilution of a 2 µL aliquot of the purified product. Concentration should be between 30-50 ng/µL. 25.

Run the reminder of the 1/10 stock dilution in a 1.5 % agarose gel as in step 16 (Fig. 2d). CRITICAL: Check for a single band of the expected size.

26.

Perform in vitro transcription by setting up the reaction mix as indicated in Table 4.

CRITICAL STEP: This step is a high-yield reaction that further amplifies the template molecules as well as converts them into RNA. It is necessary to keep RNAse-free conditions at all times. ? TROUBLESHOOTING Make a 1/10 dilution to perform a quantification of the purified RNA on NanoDrop using RNA parameters. Concentration should be between 0.5-2 µg/µL. CRITICAL STEP: The concentration obtained allows to estimate concentration in non-purified RNA. For example, a 2 µg/µL concentration in the purified RNA can be translated to an estimated concentration of 6 µg/µL in the non-purified RNA considering a factor 3 dilution (from a 5 µL aliquot to a final volume of 15 µL). The total yield of the in vitro transcription step should be around 150-450 µg from a single transcription step (60 µL in total).

30.

Check for the RNA quality by Urea PAGE ( Fig. 2e) . Perform a pre-run for 30 min in 1X TBE at 190 V to eliminate the excess of persulfate. When finished, wash the wells with the running buffer. Load 100 ng of purified RNA per lane.

Heat the samples at 95 °C for 5 min and put it immediately on ice for 2 min. Perform the PAGE for 1 h at 190 V. For gel staining, incubate protected from light for 20 min in 30 mL of TBE 1X and 3 µL of SyBR Gold.

31.

Perform the reverse transcription reaction according to Maxima H Reverse Transcriptase kit by setting up the reaction mix indicated in Table 5. CRITICAL STEP: In this step, the non-purified RNA from step 27 is directly used. RNA should always be kept in ice to prevent degradation. CRITICAL STEP: Primer sequence is the same as for forward primer used in emulsion PCR or limited-cycle PCR. Quantify oligo concentration with a NanoDrop using ssDNA parameters. CRITICAL: Total quantity of ssDNA should be in the order of 80-120 µg. 39.

Control the quality of ssDNA by Urea PAGE as in step 30 (Fig. 2e). CRITICAL STEP: This step allows to verify RNA degradation and the efficacy of reverse transcription step. PAUSE POINT: Probes can be stored at -20 °C for months.

Embryo collection and fixation * Timing 2-3 h 40.

Place 200-400 flies with a 2:1 female/male ratio into an egg-collection cage mounted with an apple juice plate containing a dollop of yeast paste and prewarmed to 25 °C (or the temperature required for the specific experiment). Perform an ON pre-laying step. 41.

Replace the plate with a new one containing a dollop of yeast paste and prewarmed to 25 °C. Perform a laying step during 1.5 h at 25 °C. 42.

Remove the plate, put the cover and incubate 1 h (or the time required to obtain embryos in the desired developmental stage) at 25 °C. 43.

Rinse the plates with ddH 2 O and carefully detach embryos using a brush. Filter the liquid using a nylon filter. Embryos will remain on it. 44.

Prepare a six well plate with one well containing bleach at 2.6% active chlorine, and the other five containing water. Put the filter with the embryos in the bleach containing well and incubate for 5 min. 45.

Rinse sequentially the embryos by immersing the nylon filter into the water-containing wells. Dry them in between steps by pressing on a paper tissue. Place the embryos at the center of the filter.

46.

Using a 1 mL pipet, add 5 mL of 4% (v/v) formaldehyde in PBS to rinse the filter and displace embryos into a 20-mL glass vial. ! CAUTION Formaldehyde is toxic and should be handled with protective gloves under a fume hood and discarded according to the relevant environmental and safety instructions. 47.

Add 5 mL of heptane to the vial, close and vigorously shake it manually during 30 sec. You may cover the cap of the vial with parafilm to avoid leakage of the formaldehyde and heptane solution inside. Incubate the embryos during 20 minutes at RT. 48.

Aspirate the lower aqueous phase on the bottom of the vial using a glass Pasteur pipet. ! CAUTION Formaldehyde is toxic and should be handled with protective gloves under a fume hood and discarded according to the relevant environmental and safety instructions. 49.

Add 5 mL of methanol and vortex the glass vial during 15 seconds. Using a glass Pasteur pipet, transfer the embryos at the bottom of the glass vial to a 1.5 mL tube. ! CAUTION Methanol is toxic and highly volatile and should be handled with protective gloves under a fume hood and discarded according to the relevant environmental and safety instructions. CRITICAL STEP: Glass pipet is used to avoid embryos attaching to the walls. Avoid using plastic tips. 50.

Wash the embryos three times with 1 mL of methanol. PAUSE POINT: Fixed embryos can be stored in methanol at -20°C for months.

RNA in situ hybridization * Timing 2.5 days CRITICAL: This procedure can be omitted if only DNA-labeled embryos are required.

51.

Transfer 30 µL of fixed embryos to a 1.5 mL tube. CRITICAL STEP: Use a glass Pasteur pipette. 1000

52.

Rinse the embryos with 1 mL of 100% (v/v) methanol. Wash the embryos with 1 mL of a 1:1 mixture of 100% (v/v) methanol and 100% (v/v) ethanol and incubate for 5 min at RT in a rotating wheel. 53.

Rinse the embryos twice with 1 mL of 100% (v/v) ethanol. Wash the embryos with 1 mL of 100% (v/v) ethanol and incubate for 5 min at RT in a rotating wheel. 54.

Repeat previous step. CRITICAL STEP: These steps remove impurities and reduce background. 55.

Rinse the embryos twice with 1 mL of 100% (v/v) methanol. Wash the embryos with 1 mL of 100% (v/v) methanol and incubate for 5 min at RT in a rotating wheel. 56.

Wash the embryos with 1 mL of a 1:1 mixture of 100% (v/v) methanol/ 5% (v/v) formaldehyde in PBT and incubate for 5 min at RT in a rotating wheel. Rinse the embryos with 1 mL of 5% (v/v) formaldehyde in PBT. ! CAUTION Formaldehyde is toxic and should be handled with protective gloves under a fume hood and discarded according to the relevant environmental and safety instructions. 57.

Fix the embryos with 1 mL of 5% (v/v) formaldehyde in PBT for 25 min at RT in a rotating wheel. CRITICAL STEP: Post-fixation assures RNA integrity. 58.

Rinse the embryos twice with 1 mL of PBT. Wash the embryos four times with 1 mL of PBT and incubate for 15 min at RT in a rotating wheel. PAUSE POINT: Once rehydrated, the embryos can be stored in PBT for several hours at RT or for several days at 4 °C before continuing to next step. 59.

Permeabilize the embryos by incubating with PBS-Tr for 1 h at RT in a rotating wheel. 60.

Rinse the embryos with 1 mL of PBT. Wash the embryos three times with 1 mL of PBT and incubate for 5 min at RT in a rotating wheel. 61.

Wash the embryos with 1 mL of a 1:1 mixture of RHS/ PBT and incubate for 10 min at RT in a rotating wheel. PAUSE POINT: It is possible to store the embryos in RHS at -20 °C for several weeks. 62.

Incubate the embryos with 1 mL of prewarmed RHS in a Thermomixer at 800-900 rpm at 55 °C for 10 min. ! CAUTION RHS contains formamide, that is toxic and should be handled with protective gloves under a fume hood and discarded according to the relevant environmental and safety instructions. 63.

Change media with fresh RHS and incubate the embryos at 55 °C in a Thermomixer at 800-900 rpm for 45 min. CRITICAL STEP: Before changing media, allow the embryos to settle down to the bottom of the tube. Since RHS is highly viscous, this could take several minutes. It is possible to use Thermomixer at 300 rpm to speed up the process. 64.

Repeat previous step with an incubation time of 1 h and 15 min. 65.

Completely remove RHS and immediately add the 250 µL of RNA probe (see Reagent setup for probe preparation). Incubate the embryos at 55 °C ON in a Thermomixer at 800-900 rpm.

CRITICAL STEP: Work fast to ensure embryos remain at 55 °C when adding the probe directly from the ice. 66.

Recuperate the used probe for two more utilizations by carefully aspirating the supernatant. Used probe can be stored at -20 °C for up to several months. CRITICAL STEP: Allow the embryos to settle down to the bottom of the tube by stopping the thermomixer agitation for 3-5 min. 67.

Rinse the embryos twice with 1 mL of RHS prewarmed to 55 °C. Wash the embryos four times with 1 mL of prewarmed RHS in a Thermomixer at 800-900 rpm at 55 °C for 30 min. 68.

Wash the embryos with 1 mL of a 1:1 mixture of RHS/PBT and incubate for 10 min at RT in a rotating wheel. 69.

Wash the embryos three times with 1 mL of PBT and incubate for 20 min at RT in a rotating wheel. 70.

Perform a saturation step by incubating with 1X blocking solution for 45 min at RT in a rotating wheel. CRITICAL STEP: The use of the commercially available blocking solution greatly reduces unspecific binding of the antibody. 71.

Remove 1X blocking solution and incubate the embryos with 1 mL of 1% hydrogen peroxide(v/v) in PBT for 30 min at RT in a rotating wheel. CRITICAL STEP: The inactivation of endogenous peroxidases is required to avoid a high fluorescence background. 72.

Wash the embryos two times with 1 mL of PBT and incubate for 5 min at RT in a rotating wheel. 73.

Incubate the embryo with the anti-DIG antibody (1/500 dilution in 1X blocking solution) ON at 4°C in a rotating wheel. 74.

Rinse the embryos twice with 1 mL of PBT. Wash the embryos five times with 1 mL of PBT and incubate for 12 min at RT in a rotating wheel. 75.

Incubate the embryos with the tyramide solution (5 µL of Alexa 488-tyramide reagent in 500 µL of PBT) for 30 min at RT in a rotating wheel. CRITICAL STEP: Use an aluminium foil to protect embryos from the light. 76.

Prepare a 1.5 % hydrogen peroxide(v/v) solution. Directly add 4 µL of the solution in the previous step to the embryos and incubate for 30 min at RT in a rotating wheel. 77.

Rinse the embryos twice with 1 mL of PBT. Wash the embryos three times with 1 mL of PBT and incubate for 5 min at RT in a rotating wheel. PAUSE POINT: RNA-labeled embryos can be stored for weeks at 4 °C before proceeding to DNA labeling or imaging. Carefully remove as much mineral oil as possible from the tube with a P20 pipette. CRITICAL STEP: Remaining oil dramatically affects embryo attachment to coverslips, as well as interfere with image acquisition. 87.

DNA

Add 500 μl of 50 % formamide, 2× SSC, 0.3 % CHAPS and remove supernatant.

CRITICAL STEP: This helps to immediately remove the mineral oil after hybridization. If the quantity of remaining oil is too big, this step will not be enough to prevent posterior issues of attachment and image acquisition. 88.

Perform post-hybridization washes by passing embryos through 1mL of the following freshly made solutions : (1) 50 % formamide, 2× SSC, 0. 4) 20 min at 37 °C in a thermomixer with agitation (800 to 900 rpm), perform washes ( 5)-( 7) 20 min at RT on a rotating wheel. 89.

(Optional) Rinse the embryos with 1 mL of PBT. Crosslink primary library by incubating the embryos with 1 mL of 4% (w/v) paraformaldehyde in PBT for 30 min at RT in a rotating wheel.

CRITICAL: Although optional, in our hands crosslinking the primary library improved the labelling efficiency. 90.

Rinse the embryos with 1 mL of PBT. Incubate the embryos with Rhodamine-labeled readout probe in 1 mL hybridization buffer (25 nM readout probe, 2X SSC, 40% v/v formamide) for 30 min at RT in a rotating wheel. CRITICAL STEP: Rhodamine-labeled probe is used for the fiducial barcode, protect samples from light exposure. 91.

(Optional) Perform an additional crosslinking step as in step 89. 92.

Rinse the embryos with 1 mL of PBT. Incubate the embryos with DAPI for 20 min at RT in a rotating wheel. Afterward, remove the DAPI and rinse the embryos three times with 1 mL of PBS. CRITICAL: Detergent-containing PBT can prevent embryos from attaching to the coverslip. PAUSE POINT: DNA-labeled embryos can be stored for weeks at 4 °C before proceeding to mounting and imaging.

Attachment of embryos to microfluidic chamber * Timing 1 h

93.

Wash a coverslip sequentially with acetone, ethanol and water and dry it with a soft flame. Put it into a 35 mm plastic dish. CRITICAL: Heating excessively the coverslip with the flame may deform it and may affect imaging and sealing of the sample in the microfluidics chamber. 94.

Add 1 mL of poly-L-lysine solution (1:10 dilution in ddH 2 O) to the coverslip and incubate for 20 min at RT. Steps for embryo attachment are shown in Fig. 3a. Afterward, rinse the coverslip with ddH 2 O. 95.

Dry the coverslip with a paper tissue. Thoroughly dry the coverslip by using compressed air. CRITICAL STEP: Embryos will not attach if coverslip is not completely dry. 96.

Cut a piece of agarose and put it under the binocular microscope. Transfer 20-30 embryos to the agarose pad. CRITICAL STEP: Use a glass Pasteur pipette. 97.

Align the embryos using metal tweezers and looking at the binocular microscope. It might be necessary to wait for a few minutes for excess of PBS to evaporate, which facilitates visualization and the displacement of embryos over the agarose pad. CRITICAL STEP: Alignment will greatly facilitate finding the embryos in the microscope when defining ROIs. Be gentle when touching/moving the embryos with the tweezers, otherwise embryos could break. 98.

Dry the embryos using a paper tissue to absorb surrounding liquid. CRITICAL STEP: Embryos will not attach if there is an excess of liquid. If necessary, wait a few minutes for the liquid to evaporate. 99.

Attach the embryos to a poly-L-lysine-coated coverslip by gently pressing coverslip against the agarose pad. CRITICAL STEP: Press gently for a few seconds to ensure attaching. 100. Put the coverslip in a 35 mm plastic dish with PBS until ready for chamber assembly ? TROUBLESHOOTING Hi-M data acquisition * Timing ~1-1.5 h per barcode CRITICAL: Experiments are performed on a home-made wide-field epifluorescence microscope coupled to a microfluidics device.

101. Wash all the microfluidics tubing with ddH 2 O first and then with filtered 2X SCC. CRITICAL STEP: Microfluidics tubing should remain filled with 50% ethanol between experiments, which prevents bacterial growth and, at the same time, facilitates air bubble removal. CRITICAL STEP: Check that pressure/flow rate is constant for all valves to discard clogging. 102. Open the microfluidics chamber by unscrewing it. Carefully remove the glass coverslip from the chamber. Steps for chamber assembly are shown in Fig. 3b. 103. Remove the plastic spacer and dry it thoughtfully with a paper tissue.

CRITICAL STEP: Dry as much as possible the whole microfluidics chamber 104. Put back the dried spacer and mount the coverslip with the attached embryos 105. Screw the chamber and mount it into the platine of the microscope. 106. Fill the chamber with 2X SSC by slowly aspirating the buffer with a 10 mL syringe. CRITICAL STEP: If the pressure exerted at this stage is to high, embryos risk to detach. At the time of the filling, keep the chamber upwards to prevent air retention. ? TROUBLESHOOTING 107. Connect all tubings with the corresponding solution and note the respective Hamilton valves numbers. 108. Put a small drop of oil onto the objective and make focus on the coverslip surface. Locate the embryos using brightfield imaging. CRITICAL STEP: Check if embryos are properly attached. Embryos borders can be observed out of focus when embryos are detaching. ? TROUBLESHOOTING 109. Select the ROIs by checking the DAPI stained nuclei.

CRITICAL STEP: Select embryos based on the developmental stage you are interested. Check for RNA expression pattern as it might depend on the orientation of each particular embryo. Be brief when checking to avoid photobleaching of RNA signal. 110. Check the autofocus and select the starting point for the Z stacks. Select the total number of planes to ensure acquiring the full embryo in the axial direction. 111. Acquire brightfield images for all ROIs. 112. Acquire DAPI, RNA and fiducial barcode channels. Normally, 3D images of embryos are acquired with a 250 nm Z-step size, spanning a 15 μm depth. CRITICAL STEP: Make sure there is enough space in the computer storage disk. The acquisition of 30 ROIs (~10 embryos) for 20 barcodes can take up to 1-1.5 terabytes. ? TROUBLESHOOTING 113. Set the injection procedure for the sequential imaging steps as follows:

CRITICAL STEP: Keep the flow rate below 0.3 mL/min. The embryos can detach from the coverslip with a higher flow rate. CRITICAL STEP: Allow for pressure stabilization before starting imaging.

Step Solution Volume (mL) Flow Rate (mL/min) Proceed to photobleaching using 100% of the laser power for 6-10 sec in each ROI. See Experimental design section for further information. 116. Repeat the steps 113-115 for all the barcodes.

Hi-M data analysis * Timing 3-4 days

CRITICAL: Multiple types of software can be used to implement image segmentation. Here, we provide a typical script in MATLAB format.

117. Deconvolve the 3D-acquired wide-field epifluorescence images using the Huygens deconvolution software. CRITICAL STEP: Specify the correct parameter values for deconvolution, such as pixel size, numerical aperture of the objective, excitation and emission wavelengths, and refraction index of medium. ? TROUBLESHOOTING 118. Organize stacks to include in one folder all the ROIs corresponding to one embryo. CRITICAL STEP: Include in this folder the .inf files that contain the parameters needed for the analysis. 119. Launch MATLAB and load the provided home-made script. The script is written in a modular way, where user must sequentially execute (Control+Enter) the different steps that are described from now on. Input the folder where ROIs are in "destDir" line. 120. Launch the GUI by running the "GUI to segment DAPI masks" block.

121. Click on "Read new ROI", wait for the program to load the image and then click on "Process". CRITICAL STEP: Select the starting and end planes to be read in the "ImageSettings" square. If the "autoPlanes" box in the Options square is marked, it would only load the number of planes above and below the more intense defined by "zWindow" box in "ImageSettings" square. CRITICAL STEP: If you have GPUs available for processing, tick on "GPU" box in the Options square. This will considerably reduce processing time. 122. Segment nuclei (Fig. 4). Adjust Segmentation parameters and click on "Resegment". A visual output will be displayed showing each segmented nucleus as a mask of a different color. CRITICAL STEP: Optimize parameters in an iterative manner by visually inspecting the segmentation output (Fig. 4c) in order to correctly segment nuclei. For our data, the typical values used are "Threshold": 0.9-1.1 (with relative threshold box ticked); "# Voxels": 400-5000; "extent": 0.2-1, "equivDiameter": 15-100. Use the histograms on the GUI to discard outliers. CRITICAL STEP: By ticking on "watershed" box, the segmentation is greatly improved. ? TROUBLESHOOTING 123. (Optional) Due to border effects, it may be necessary to define a polygon around the embryo, in order to discard regions outside. To do so, tick on "ROI_loc" and click on "Resegment". A pop-up window will appear to manually select the polygon. Click once to define the vertices of the polygon. You can use the backspace key to delete last vertex. Double-click once you are done with the selection. An example is shown in Fig. 7. 124. Repeat steps 121-123 for all ROIs for the embryo (typically 2-4 ROIs). Change the selected ROI by changing the "nROI" bar (Fig. 4b). This whole process can also be performed in batch. In this mode, all ROIs are processed without user input using the set of parameters provided in the GUI. CRITICAL: Even if batch processing we recommend to manually explore the segmentation results for each ROI after segmentation. 125. Press on "save data" button and close GUI window.

CRITICAL STEP: If "save data" is not pressed, segmented data will be lost. 126. (Optional) Dilate DAPI masks by running the corresponding block. 127. Launch the spot-detection GUI to segment fiducial barcode corresponding to the first acquisition cycle (Fig. 4a). Follow the procedure as in steps 121-123 for each ROI, only this time execute the "GUI to segment internal marks DAPI" block. For historical reasons, barcodes are called "RTs" in the program. CRITICAL STEP: Change the contrast in the "ImageSettings" square to correctly visualize the spots. A typical contrast range is between 0.1-0.999. CRITICAL STEP: Optimize parameters in an iterative manner by visually inspecting the selection of spots (Fig. 4d) to segment all spots. A blue circle will be created around each detected spot in the raw image. Zoom in as needed.

For our data, the typical values used are "Threshold": 1.5-4 (with relative threshold box unticked); "# Voxels": 5-1000; "extent": 0.2-1, "equivDiameter": 1-50.

? TROUBLESHOOTING 128. Fit the detections performed in the previous step using a 3D gaussian fitting, using the "Refits RTs using 3D gaussian fitting" block. 129. Launch the spot-detection GUI to segment the readouts for all cycles. Follow the procedure as in steps 121-123 for each ROI. It is possible to use "batch processing" (see next step). For our data, the typical values used are "Threshold": 1.8-5 (with relative threshold box unticked) ; "# Voxels": 5-1000; "extent": 0.2-1, "equivDiameter": 1-50. ? TROUBLESHOOTING 130. (Optional) Once parameters are determined for a particular ROI, you can automatically segment all ROIs by clicking on "batch processing", and unticking "batchSingleROI" box in the options section of the GUI. Furthermore, by ticking on "Iterate" box on the segmentation square before pressing "batch processing", the program can automatically iterate to find the most suitable parameters for each ROI (Fig. 4a). "targetObjects" are the expected number of spots to detect, with a "tolerance" indicating the allowed range in percentage. "Alpha" is a factor by which it will change the threshold in each iteration, considering the difference between the segmented objects and "targetObjects". Its standard value is 0.001. "maxIterations" is the maximal number of iterations it would perform, even if it didn't reach the expected number of objects, before going to the next ROI. CRITICAL STEP: Tick "batchSingleROI" box and untick "bachSingleRT" in the options square to process all readouts for the same ROI. 131. Use the spot-detection GUI to segment the fiducial barcodes in all hybridization cycles following the procedure of steps 121-123. It is possible to use "batch processing" as in previous step. ? TROUBLESHOOTING CRITICAL STEP: It is necessary to segment each barcode for EACH ROI. Remember to press on "save data" button before closing the GUI window. 132. Fit the detections performed in the previous step using a 3D gaussian fitting by running the "Refits RTs using 3D gaussian fitting" block. 133. Calculates the drift along the cycles by running the "Correct drift using internal marker" block. It cross-correlates fiducial barcode spots with the ones from the reference cycle (the first hybridization cycle) to obtain a correction vector. CRITICAL STEP: Select the fiducial barcode of the first cycle as reference, by changing the value of "referenceRT" variable. 134. Assess the quality of drift correction by running the "Benchmarks drift correction quality" block (Fig. 4d). ? TROUBLESHOOTING 135. Align the barcode spots from all hybridization cycles by running the next block.

It uses the correction vector from the fiducial barcode spots closest to the barcode to align. 136. Segment RNA signal by running the "Segments RNA" block. A pop-up window will appear to manually select the polygon. CRITICAL STEP: Load in this section the data paths that contain the genomic coordinates of the readout probes used in data acquisition. 143. Set parameters, by running "Sets parameters" section. They are defined by default, but can be adapted for each experiment. CRITICAL STEP: Choose the correct value for the p.process variable (RNAon, RNAoff, or none), depending on whether nuclei containing RNA staining are to be analyzed separately from those who do not (RNAon and RNAoff respectively). By choosing the value "none", both type of nuclei will be processed together. 144. Run the "Loops over cells and detects clusters" section. This will group barcodes in clusters. 145. Order readouts according to their genomic position, by running the dedicated section. This will allow to assign to each barcode the correct genomic coordinates, and later construct distance matrices. 146. Run the "Populates distanceMatrix" section. Then, run the "Calculates mean distance matrix and contact probability matrix from distanceMatrix structure". 147. Plot genomic distances versus mean physical distances using the corresponding block. 148. Plot contact probability versus genomic distance by running the corresponding block. 149. Plot the normalised distance matrix and normalised contact probability matrix by running "Plots the normalised distance matrix and normalised contact probability matrices" section.

Timing

Steps

Anticipated results

This protocol provides a detailed description of the steps required design Oligopaint probes, stain and image simultaneously RNA and DNA, and to segment nuclei, RNA and multiple barcodes in thousand of cells in an intact organism.

A typical set of results is shown in Fig. 9. It consists of matrices of pairwise absolute contact probability, pairwise distance maps, and ratio between standard deviation and mean pairwise distances. Critically, the simultaneous detection of RNA expression of a target gene allows for the analysis of nuclei according to their transcriptional state. ) a forward and reverse 20-nt universal priming region in blue-green, 2) a 32-nt readout sequence in blue (x2) and 3) a 42-nt genome homology variable region in black. Lower panel, schematic description of the steps to design an oligopool. b , Upper panel, oligopool amplification scheme.. Blue-green represents universal priming region common to all barcodes whereas blue, amber and burgundy represent barcode-specific readout sequences. Lower panel, schematic description of main steps involved. c , Example of an agarose gel electrophoresis result for the small scale limited-cycle PCR step. "L" is the DNA ladder or molecular weight size marker. A band of the expected size (166-nt in this case) is observed between the 100-and 200-nt bands of the ladder. In cycles 13 and 14 a second, non-specific band of ~300-nt begins to appear. Therefore, 11 amplification cycles (at PCR cycle 12) were chosen for this specific amplification reaction. d , Example of an agarose gel electrophoresis result for the large scale limited-cycle PCR step. "L" is the ladder as in panel c . Lane 1 and 2 correspond to a PCR performed without or with template, respectively. dNTPs are observed at the bottom. Lane 3 corresponds to column-purified PCR product. e , Example of an Urea PAGE result. "L" is the low range ssRNA ladder. Bands from lanes 1-4 appear close to the height of the 150-nt band from the ladder. Lane 1 corresponds to 200 ng of emulsion PCR break, lane 2 to 200 ng of RNA product from in vitro transcription (note the higher size due to the presence of the T7-promoter region), lanes 3 and 4 to 200 ng of ssDNA before and after precipitation, respectively.

Legends to the Figures

Figure 1 .

 1 Figure 1. Outline of the Hi-M protocolSchematic description of the main steps in the Hi-M protocol.

Figure 2 .

 2 Figure 2. Design and amplification of Oligopaintsa ,Upper panel, schematic structure of oligos: 1) a forward and reverse 20-nt universal priming region in blue-green, 2) a 32-nt readout sequence in blue (x2) and 3) a 42-nt genome homology variable region in black. Lower panel, schematic description of the steps to design an oligopool. b , Upper panel, oligopool amplification scheme.. Blue-green represents universal priming region common to all barcodes whereas blue, amber and burgundy represent barcode-specific readout sequences. Lower panel, schematic description of main steps involved. c , Example of an agarose gel electrophoresis result for the small scale limited-cycle PCR step. "L" is the DNA ladder or molecular weight size marker. A band of the expected size (166-nt in this case) is observed between the 100-and 200-nt bands of the ladder. In cycles 13 and 14 a second, non-specific band of ~300-nt begins to appear. Therefore, 11 amplification cycles (at PCR cycle 12) were chosen for this specific amplification reaction. d , Example of an agarose gel electrophoresis result for the large scale limited-cycle PCR step. "L" is the ladder as in panel c . Lane 1 and 2 correspond to a PCR performed without or with template, respectively. dNTPs are observed at the bottom. Lane 3 corresponds to column-purified PCR product. e , Example of an Urea PAGE result. "L" is the low range ssRNA ladder. Bands from lanes 1-4 appear close to the height of the 150-nt band from the ladder. Lane 1 corresponds to 200 ng of emulsion PCR break, lane 2 to 200 ng of RNA product from in vitro transcription (note the higher size due to the presence of the T7-promoter region), lanes 3 and 4 to 200 ng of ssDNA before and after precipitation, respectively.

Figure 3 .

 3 Figure 3. Procedure for attaching embryos to the microfluidics chamber Where it corresponds, the sequence is indicated as i, ii, iii and iv. a , Embryo attachment. (Step 94) Add poly-L-lysine solution to coverslip. (Step 96) Cut an agarose pad and transfer 20-30 embryos to the agarose pad. (Step 97) Use metal tweezers to align the embryos using a binocular microscope to visualize them. (Step 98) Dry the embryos using a paper tissue. (Step 99) Attach the embryos to a poly-L-lysine-coated coverslip by gently pressing coverslip against the agarose pad. b , Embryo mounting to chamber. (Step 102) Open the microfluidics chamber by unscrewing it. Carefully remove the glass coverslip from the chamber. (Step 103) Remove the plastic spacer and dry it thoroughly with a paper tissue. (Step 104) Put back the dried spacer and mount the coverslip with the attached embryos. (Step 105) Screw the chamber and mount it to the microscope stage. (Step 106) Flow 2X SSC buffer through the chamber by slowly aspirating with a syringe.

Figure 4 .

 4 Figure 4. Scheme of hybridization/imaging cycles a , Primary oligopool is hybridized on the bench to genomic DNA. b , A readout oligo (blue), bearing a fluorophore (red star), specifically binds to the blue readout barcode. c , Once hybridized, images are recorded for all ROIs. d , The fluorophore on the readout oligo is chemically cleaved or alternatively, photobleached. e , A new hybridization cycle starts with a different readout oligo, now targeting the ambar barcode.

Figure 5 .

 5 Figure 5. Hi-M setupIn the center, an image of the Hi-M setup. White arrows indicate the location of the 60X water-immersion objective (not visible). The microfluidics tubing is highlighted in yellow.Color rectangles zoom into key components. (i) The solid state lasers lasers are combined by dichroic mirrors and an acousto-optic filter (AOTF) is used to switch the different laser lines on/off and to change intensity. (ii) Beams are expanded by a telescope and focused at the back-focal-plane of a 60X objective. (iii) Flow is created by a negative pressure pump at the outlet. Liquid is withdrawn from the inlet of a valve, (iv), passes through the FCS2 flow chamber (v), the online flow-unit and is then discarded into the bottle in the outlet.

Figure 6 .

 6 Figure 6. Hi-M image acquisition flowchartLeft, sequence of steps required for sample mounting, microscope set-up and DAPI/RNA signal acquisition (violet boxes). Right, sequence of steps needed for the sequential barcode acquisition (yellow boxes).

Figure 7 .

 7 Figure 7. Hi-M image analysis flowchart Sequence of steps required for image analysis (spot detection and registration). Violet boxes indicate key steps, yellow boxes indicate refinement of obtained masks (either by dilating the nuclei mask or by 3D Gaussian fitting of barcode positions), whereas pink boxes indicate quality check steps.

Figure 8 .

 8 Figure 8. Data analysis a, MATLAB GUI for image analysis employed in steps 120-125, 127, 129 and 131. The panels show the center buttons, the processing options, image and segmentation parameters that are used to segment nuclei or barcodes. b, ROI selection bar. nRT is the corresponding barcode whereas nROI is the selected ROI. c, Typical example of nuclei segmentation. Each nuclei mask is represented with a different color. d, Example of a barcode image Z-projection after segmentation. The intensity is represented in a color code that ranges from black to orange to white. Identified barcodes are marked with a blue circle around them. e , RNA signal segmentation, performed in a pop-up window. RNA-positive nuclei are manually selected by a

Figure 9 .

 9 Figure 9. Hi-M output

Figure 1 Steps

 1 Figure 1

  Figure 2 a

  Figure 4 a DNA FISH

  Figure 5

100 mM NaH 2 PO 4 pH=7 To

  Minus Reverse transcriptase kit (Fisher Scientific, cat. no. 13243159) • dNTP Set 100 mM Solution (Fisher Scientific, cat. no. 10083252) • Rnasin Ribonuclease Inhibitors (Promega, cat. no. N2515) • Oligo clean & concentrator kit (Zymo, cat. no. D4060) • DNA Clean & Concentrator kit -25 µg capacity (Zymo, cat. no. D4033) • DNA Clean & Concentrator kit -100 µg capacity (Zymo, cat. no. D4029) • SYBR Safe nucleic acid gel stain (Invitrogen, cat. no. S33102) • RNA Loading Dye 2X (New England Biolabs, cat.no. B0363S) • Low Range ssRNA Ladder (New England Biolabs, cat. no. N0364S) • SYBR Gold Nucleic Acid Gel Stain (Fisher Scientific, cat. no. S11494) • Agarose Standard DNA Grade (Euromedex, cat. no. D5-E) • GeneRuler 100 bp DNA Ladder (Fisher Scientific, cat. no. SM0243) • Ammonium acetate 5 M (Fisher Scientific, cat. no. 10534645) • Glycogen 5 mg/mL (Ambion, cat. no. AM9510) • TEMED (Thermo Scientific, cat. no. 17919) • Ammonium Persulfate (APS) (Fisher Scientific, cat. no. 17874) • Acrylamide/Bis-Acrylamide 19:1, 40% Solution (Fisher Scientific, cat. no. BP1406-01) • Cetyl PEG/PPG-10/1 dimethicone (ABIL EM-90, Evonik) • Diethyl ether (Sigma-Aldrich, cat. no. 296082) • Ethyl acetate (Sigma-Aldrich, cat. no. 270989) • Mineral oil (500 mL; Sigma-Aldrich, cat. no. M5904) • Triton X-100 (250 mL; Sigma-Aldrich, cat. no. T8787) • Tween-20 (500 mL; Sigma-Aldrich, cat. no. P2287) • CHAPS (Sigma, cat. no. 226947) • Dulbecco's phosphate-buffered saline (PBS) (Gibco, cat. no. 14190169) • Poly-L-lysine solution (Sigma-Aldrich, cat. no. P8920) • 20X Saline-sodium citrate buffer (SSC) containing 3 M NaCl in 0.3 M sodium citrate (Thermo Fisher Scientific, cat. no. AM 9770) • Tris Base, BM grade (Euromedex, cat. no. 200923-A) • Sodium chloride (99,5%) (Euromedex, cat. no. 1112-A) • Sodium dihydrogen phosphate, dihydrate (Euromedex, cat. no. T879) • Dry fine yeast (Lab Scientific, cat. no. FLY-8040-20F) • Clorox Ultra Germicidal Liquid Bleach (Fisher Scientific,cat. no. 50371500) • Heptane (Fisher Chemical, cat. no. O3008-4) 30 % (w/w) hydrogen peroxide solution (Sigma-Aldrich, cat. no. H1009) CRITICAL: The stabilizer included in this reagent warrants a long shelf time. • Alexa Fluor 488 Tyramide Reagent (Invitrogen, cat. no. B40953) • Tris(2-carboxyethyl)phosphine hydrochloride (TCEP; Sigma-Aldrich, cat. no. Roche, cat. no. 10711454001) • 4′,6-Diamidine-2′-phenylindole dihydrochloride (DAPI; Roche, cat. no. 10236276001) • Glucose oxidase (Sigma-Aldrich, cat. no. G2133) • Catalase (Sigma-Aldrich, cat. no. C30) • D(+) Glucose anhydrous (Euromedex, cat. no. UG3050) • Alexa-647 readout probes (IDT DNA). Sequences can be found in Supplementary Table 1 and are complementary to the readout sequences. F148505) • 2 mL 11-mm Glass vial (VWR, cat. no. 66009-822) • Magnetic stirring bar (BelArt, cat. no. 371191083) • Magnetic stirrer (10 mm) • NanoDrop spectrophotometer (Thermo Scientific, model no. ND-1000UV/Vis) • Vortex, standard mini vortex (VWR ) • Falcon 15-mL Conical Centrifuge Tubes (Fisher Scientific, cat. no. 14-959-53A) • Falcon 50-mL Conical Centrifuge Tubes (Fisher Scientific, cat. no. 14-959-49A) • Tabletop centrifuge (Eppendorf, cat. no. 5424) • Syringe 30 mL (Terumo, cat. no. SS-30S) • Syringe 20 mL (Terumo, cat. no. SS-20S2) • Embryo collection cage (8.75 cm × 14.8 cm; Flystuff.com, cat. no. 59-101) • Nylon Filter (BD Falcon, cat. no. 352350) • Water bath Grant Instruments JBN5 (Fisher Scientific, cat. no. 15177015). • Thermomixer-AccuTherm Microtube Shaking Incubator (Labnet, cat. no. I-4001-HCS) • Gas burner • Disposable scalpel (Swann-Morton, cat. no. 0516) • Plastic petri dishes (Greiner Bio-One; 60 mm diameter petri dish, cat. no.628163) • Disposable glass Pasteur pipette (VWR, cat. no. 612-1702) • Glass vial for embryo collection (DWK Life Sciences, cat. no. 986562) • Rotating wheel • Wide-field epifluorescence microscope (see Reagent setup) • Microscope coverslips (Bioptechs Inc., cat. no. 40-1313-0319) • Microfluidics FCS2 chamber (Bioptechs Inc., cat. no. 03060319-2-NH) • MFCS-EZ negative pressure pump (Fluigent, cat. no. EZ-80345001) • Flow unit L (Fluigent, ref. FLU_L_D)• Online degassing unit (HPLC DegaSi Plus, Cluzeau Info Labo, cat. no. If available, with the use of a positive displacement pipette it is possible to directly pipette 2 mL of ABIL EM90, 65 µL of Triton X-100 and 47.975 mL of mineral oil to a 50-mL Falcon tube. Add the mineral oil in two steps, vortexing in between them. If positive displacement pipette is not available, volume can be accurately determined by weighing. To prepare 50 mL of PCR oil phase, weigh 20.3 g of mineral oil (around 24 mL) directly into a 50-mL Falcon tube, add 2 mL of ABIL EM90 and 65 µL of Triton X-100, vortex thoroughly and leave it rest for 5 min. Then add 20 g of mineral oil and homogenize by inversion of the tube. Make 20 mL aliquots of PCR Oil phase and store indefinitely at 4 °C. Mix 50 µL of Tween 20 with 450 µL of ddH 2 O and vortex until the solution becomes homogeneous. Store at 4 °C for up to two weeks. Mix 6 g urea, 1.25 mL TBE 10X and 3.5 mL of ddH 2 O. Heat the solution at 60 °C in a water bath until the urea is dissolved. Add 3.125 mL of acrylamide/bisacrylamide, 75 µL of APS 10% and 15 µL of TEMED. Cast the polyacrylamide gel in 0.75 mm thick spacers. Put 2 µL of RNA probe in 250 µL of RHS, incubate at 85 °C on a dry bath incubator for 2.5 min. Then incubate on ice for at least two minutes before adding it to the embryos. CRITICAL: Freshly prepare the RNA probe, keeping it on ice no more than an hour before its use. Check the temperature of the dry bath to avoid probe degradation. Do not exceed 2.5 min incubation as high temperature might degrade the probe. Maleic acid buffer To make 200 mL of buffer, add 2.3 g of maleic acid, 1.7 g of NaCl, 1.2 g of NaOH and 100 mL of ddH 2 O. Measure pH and adjust to pH=7.5 with 5 M NaOH. Make up the volume to 200 mL with ddH 2 O and filter. Solution can be stored at RT for up to six months. prepare 50 mL of this solution, mix 0.78 g of NaH 2 PO 4 in 30 mL of ddH 2 O. Adjust to pH=7, and complete with ddH 2 O to 50 mL. Pass it through a 0.22 µm filter. The solution can be stored at 4 °C for several months. To prepare 50 mL of this solution, mix 2.92 g of NaCl with 30 mL of ddH 2 O in a 50-mL Falcon tube and dissolve. Complete to 50 mL with ddH 2 O and pass it through a 0.22 µm filter. The solution can be stored at RT for several months.1 M Tris-HCl pH=8 solutionTo prepare 50 mL of this solution, mix 6 g of Tris base with 30 mL of ddH 2 O. Using a pH meter, add slowly HCl using a glass pasteur pipette to reach the desired pH. Complete to 50 mL with ddH 2 O, and pass it through a 0.22 µm filter. The solution can be stored at RT for several months. 55

	• HVXM8-5 injection valve and controller (Hamilton, cat. no. 36766 & 36798)
	• MATLAB Release 2017b (Mathworks)
	• Huygens	deconvolution	software	(Scientific	Volume	Imaging,
	https://svi.nl/HuygensSoftware )
	• A server running on Linux with 32 CPU processors, two GeForce GTX 1080Ti Prepare freshly.
	GPU cards, and 128GB of RAM. RNA Hybridization solution (RHS) To prepare 250 mL of RHS, mix 125 mL of
	formamide, 62.5 mL of 20X SSC, 1.25 mL of 10 mg/mL heparin, 2.5 mL 10% Tween-20
	Reagent setup (v/v), 2.5 mL of 10 mg/mL of salmon sperm and 56.5 mL ddH 2 O. Prepare 50 mL
	aliquots and stock at -20 °C for several months.
	PCR Oil phase The mix final concentration is 95.95% mineral oil:4% ABIL RNA probe preparation Pre-Hybridization Mixture (pHM) 50 % formamide, 4× SSC, 100 mM NaH 2 PO 4 , pH=7, 0.1 % Tween 20. Prepare freshly. EM-90:0.05% Triton X-100 oil phase (v/v/v). PBS-Tween 20 (PBT) solution Combine 49.5 mL of PBS with 500 µL of 10% Tween DNA hybridization solution (DHS) Combine 5 mL of formamide, 2 mL of 50% (v/v)
	646547) 20 (v/v). CRITICAL: Prepare freshly. Dextran sulfate, 1 mL of 20X SSC, 500 µL of Salmon Sperm (10 mg/mL) and 1.5 mL of
	• Anti-Digoxigenin-POD, Fab fragments (Roche, cat. no. 11207733910, PBS-Triton X-100 (PBS-Tr) solution Add 50 µL of Triton X-100 to 10 mL of PBS and ddH 2 O. Store at -20 °C for up to several months. Prewarm at 37 °C before use.
	RRID:AB_514500) vortex until the solution becomes homogeneous. CRITICAL: Prepare freshly. 50% (w/v) Glucose To prepare 40 mL of 50% (w/v) glucose, combine 20 g of glucose
	• Blocking reagent (Sigma-Aldrich, cat. no. 11096176001) 4% (w/v) formaldehyde in PBS To prepare 8 mL, mix 1 mL of 32% formaldehyde with 30 mL ddH 2 O, heat to 60 °C until it dissolves and then add ddH 2 O to 40 mL. The
	CRITICAL: Commercial blocking reagent warrants reproducibility. (w/v) -methanol free with 7 mL of PBS. CRITICAL: Prepare freshly. solution can be stored at RT for several months.
	00036352A)

• KAPA Taq Kit with dNTPs (CliniSciences, cat. no. BK1003) • HiScribe T7 High Yield RNA Synthesis Kit (New England Biolabs, cat. no. E2040S) • Maxima H • 32% Formaldehyde Solution (w/v), Methanol-free (Electron Microscopy Sciences, cat. no. 15714) ! CAUTION Paraformaldehyde is a toxic cross-linking agent. Wear protective gloves and handle it under the fume hood. Discard according to the relevant environmental health and safety instructions. CRITICAL: The use of methanol-free paraformaldehyde to fix embryos can greatly reduce autofluorescence. • 37 % Formaldehyde solution (w/v) (Sigma-Aldrich, cat. no. 47608) • Methanol (Fisher Chemical, cat. no. A412-4) • Acetone (Merck, cat. no. 1000122500) • Deionized formamide (100 ml; Amresco, cat. no. 0606) ! CAUTION Formamide is toxic and should be handled with protective gloves under a fume hood and discarded according to the relevant environmental health and safety instructions. • • RNase A (Sigma-Aldrich, cat. no. R6513) • Dextran sulfate (Sigma-Aldrich, cat. no. D8906) • Salmon sperm DNA (Ambion, cat. no. AM9680) • Heparin (Sigma-Aldrich, cat. no. H4784) • BSA (• Rhodamine-labeled DNA oligo: CATTGCCGTATGGGCTAGGATGACCTGGCTCG/3RhodRd-XN/ (IDT DNA) Equipment • PCR Machine (T100 Thermal cycler, Bio-Rad) • Positive displacement micropipette Gilson M250 (Fisher Scientific, cat. no. 1 M NaOH solution Weigh 2 g of NaOH and mix it with 30 mL ddH 2 O in a 50-mL Falcon tube and dissolve. Complete to 50 mL and pass it through a 0.22 µm filter. The solution can be stored at room temperature (RT, ~23 °C) for several months.

0.5 M EDTA solution To prepare 200 mL, weigh 37.23 g of EDTA and mix it with 150 mL of ddH 2 O in a glass beaker. Add a magnetic stirring bar and stir while adjusting to pH 8 with NaOH 10 M. Add ddH 2 O up to 200 mL. Filter solution with a 0.22 µm filter. The solution can be stored at 4 °C for several months. CRITICAL: EDTA will not dissolve until pH approaches to 8. Verify the final solution as pH may decrease when EDTA is dissolved. Water-saturated diethyl ether Mix 3 mL of diethyl ether with 3 mL of ddH 2 O and vortex for 30 sec. Allow the mixture to settle and use the organic upper phase. Prepare freshly. Water-saturated ethyl acetate Mix 2 mL of ethyl acetate with 2 mL of ddH 2 O and vortex for 30 sec. Allow the mixture to settle and use the organic upper phase. Prepare freshly. 10% Tween 20 (v/v) solution 5% (w/v) formaldehyde in PBT Mix 1.35 mL of 37 % formaldehyde solution with 9 mL of PBT. CRITICAL: Prepare freshly. TBE 10X solution Dissolve 60.55 g of Tris base, 30.9 g Boric acid and 3.7 g of EDTA. Adjust volume to 500 mL with ddH 2 O. Store at RT indefinitely.

Gel for denaturing urea polyacrylamide gel electrophoresis (Urea PAGE). 5X blocking solution

Combine 10 g of blocking reagent with 50 mL of maleic acid buffer, agitate and heat until complete dissolution. Complete to 100 mL with maleic acid buffer. Autoclave and make 10 mL aliquots. CRITICAL: 5X Blocking solution can be stored at -20 °C for up to several months. Once defrozen, keep it on ice at all times. 1X blocking solution Prepare the solution by diluting to one fifth the 5X Blocking solution with PBT. CRITICAL: Freshly prepare solution and keep it on ice. Discard any remaining aliquot. RNAse A solution Dissolve the 10 mg vial in 1 mL of ddH 2 O (100X). Make small aliquots and store at -20 °C for up to a year. 50% (w/v) Dextran sulfate To prepare the solution combine 25 g of dextran sulfate with 40 mL of ddH 2 O, heat to 37 °C until it fully dissolves and then add ddH 2 O to a final volume of 50 mL. The solution can be stored at 4 °C for several months. DAPI solution Prepare a 0.5 μg/mL DAPI solution in 1× PBS by diluting the stock solution. Store the solution with an aluminium fold at 4 °C. The solution can be employed during several weeks.

1 M NaCl solution

mM NaCl in 11 mM Tris-HCl pH=8 solution

  To prepare 50 mL of this solution, mix 2.75 mL of 1M NaCl solution, 0.55 mL of 1M Tris-HCl pH=8 solution, and 46.7 mL of ddH 2 O. Prepare freshly.Gloxy solutionTo prepare 1 mL of Gloxy solution, mix 50 mg Glucose oxidase, 100 µL catalase and 900 µL of 55 mM NaCl in 11 mM Tris-HCl pH=8. CRITICAL: Make 60 µL aliquots and store at -20 °C. Solution is stable for several months. Defrost on the day of the experiment and keep it on ice until use. If there is a precipitate, spin it down and employ the supernatant. Once defrozen, the aliquot should be used within one week.

	Wide-field epifluorescence microscope A modular microscope system (RAMM,
	Applied Scientific Instrument) equipped with a 60x water-immersion objective
	(Plan-achromat NA=1.2, Nikon) and a sCMOS camera (Orca Flash 4.0v3,
	Hamamatsu) is used for Hi-M imaging. With this objective/tube lens combination, we
	obtained a 108 nm pixel size, leading to a ~220x220 µm field of view. Sample
	displacement and embryo selection are performed using a 2-axis translation stage
	(MS2000, Applied Scientific Instrumentation). Wide-field epifluorescence illumination is
	achieved using 405/488/561 and 641 nm lasers (OBIS-405/488/640 and Sapphire 561
	-Coherent) combined with an acousto-optic tunable filter (AOTFnC-400.650, AA
	opto-electronics).

Hi-M wash buffer

To prepare 100 mL, combine 10 mL of 20X SSC, 40 mL of formamide and make up to 100 mL with ddH 2 O (Final concentration of 40% v/v formamide). CRITICAL: Freshly prepare formamide containing solutions and pass them through a 0.22 µm filter.

Hi-M acquisition solution

To prepare 10 mL of solution, combine 1.1 mL of 50% (w/v) glucose with 9.9 mL of PBS and 110 µL of Gloxy. CRITICAL: Add Gloxy solution just before using the solution and mix. Once the tubing is introduced, add a layer of mineral oil to prevent contact with oxygen from the ambient. Replace after 12-15 h.

Readout probe solution

The final composition of this solution is 25 nM of the corresponding readout oligo in 40% (v/v) formamide 2X SSC. Readout oligos sequences can be found in Supplementary Table

1

. CRITICAL: Prepare freshly and keep it protected from light. Chemical bleaching solution To prepare 10 mL of chemical bleaching solution, mix one 1-mL ampule of TCEP with 9 mL of 2X SSC. CRITICAL: Prepare the solution right before its use and discard any remaining solution.

Oligopaints * Timing 4-5 days 8

  . Emulsion PCR . This step is performed to amplify the starting oligopool (which can be limiting) in a non-biased manner. Set up a PCR Master Mix for each library as indicated in Table1and keep it on ice until needed. Pre-chill a 2-mL 11 mm glass vial in the freezer, place it on the center of a controlled stir plate and then add a pre-cooled stirring bar to the vial. Transfer 600 µL of PCR oil phase to the glass vial with a positive displacement pipette. Stir at 1000 rpm for at least 1 minute. While the stirring bar is still spinning, add 100 µL of PCR master mix in steps of 20 µL increments using a P20 pipette (i.e. dispense 20 µL 5 times). Stir at 1000 rpm for 10 minutes, the emulsion should appear milky white and foamy. Transfer the emulsion to a PCR strip tube (~8 x 75 µL) with a positive displacement pipette. CRITICAL STEP: Forward primer is the 5' => 3' forward universal priming sequence whereas reverse primer is the reverse complement of the reverse universal priming sequence. CRITICAL STEP: Emulsion preparation must be performed in a cold room at 4°C. All the equipment must be put there in advance to cool it down before use. CRITICAL STEP: It would not be possible to transfer the whole emulsion volume to the PCR strip tube, quality over quantity here.

Table 1 .

 1 Emulsion PCR master mix. Small scale emulsion PCR breaking. Pool the emulsion PCR reactions in a 1.5 mL microcentrifuge tube. Add 1 µL of gel loading buffer to visualize the aqueous phase. Add 200 µL of mineral oil and vortex for 30 sec. Centrifuge at maximum speed for 10 min and remove the upper organic phase. 11.Add 1 mL of water-saturated diethyl ether and vortex for 1 min. Centrifuge at maximum speed for 1 min and remove the diethyl ether upper phase. 12.Add 1 mL of water-saturated ethyl acetate and vortex 1 for min. Centrifuge at maximum speed for 1 min and remove the ethyl acetate upper phase. 13. Repeat step 11. Evaporate the residual diethyl ether by incubating the tube at 37 °C for 5 min with the cap open. CRITICAL STEP: The final volume should be around 80 µL. PAUSE POINT: PCR product can be stored at 4 °C for a few days. 14. Purify the DNA by using Zymo Oligo Clean & Concentrator kit . Mix 80 µL of DNA from the emulsion PCR breaking, 160 µL of oligo binding buffer and 320 µL of ethanol. Homogenize the solution by pipetting up and down 10 times. Follow the manufacturer's instructions up to the DNA elution. Repeat elution with an extra 15 µL of water and then add 20 µL of water directly into the tube to obtain a final volume of 50 µL.

	Reagent	Quantity (µL)
	ddH 2 O	79
	10X Taq buffer	10
	BSA (10 µg/µl)	5
	dNTPs (10 mM)	2
	Forward primer (200 µM)	1
	Reverse primer (200 µM)	1
	Kapa polymerase enzyme (5	1
	U/µL)
	ssDNA library (10-30 ng/µl)	1

Table 2 .

 2 Small scale limited-cycle PCR set-up.

		Product			Quantity per tube (µL)
		Kapa buffer A		5
		dNTP (100 mM)		1
		Forward primer (100 uM)		0.5
		Reverse primer (100 uM)		0.5
		Template emulsion PCR (1 ng/ µL)	2.5
		obtained in step 7.30
		Kapa polymerase enzyme (5 U/µL)	0.5
		ddH 2 O			Make up to a final volume of 50 µL
	18.	Run the following PCR program:
	Cycle number	Denature	Anneal	Extend
	1		95 °C, 5 min
	2-15		95 °C, 30 sec	60 °C, 45 sec	72 °C, 30 sec
		Pick up the corresponding tube after each of the cycles 8-15 just after the
		extension phase. To do so, quickly open the PCR machine, remove the
		corresponding tube, close the lid and resume program.
		PAUSE POINT: PCR product can be left overnight (ON) at 4°C or frozen for up
		to a month at -20°C .
	19.

Table 3 .

 3 Large scale limited-cycle PCR mix.

	Product	Quantity (µL)
	Kapa buffer A	80
	DNTP (10 µM)	16

Table 4 .

 4 In vitro transcription solution mix.

	Product	Quantity (µL)
	Purified PCR product	6 µg template DNA
	ATP (100 mM)	6
	UTP (100 mM)	6
	CTP (100 mM)	6

Table 5 .

 5 Reverse transcription mix.

	Product	Quantity (µL)
	Non purified transcription product	150 µg

DNA probe purification . Mix the 2 aliquots in a sterile 50-mL Falcon tube. Add 4.8 mL of oligo binding buffer and 19.2 mL of ethanol. Homogenize and spread over two columns. Follow the manufacturer's instructions from this point on. CRITICAL STEP: Use the Zymo DNA purification kit with 100 µg capacity.

  STEP: If the embryos are RNA-labeled, omit previous step. 80.Incubate the embryos with 1 mL of PBT, 100 𝜇g/mL of RNAse for 2 h at RT or

		ON at 4 °C in a rotating wheel.
	81.	Permeabilize the embryos by incubating them with PBS-Tr for 1 h at RT in a
		rotating wheel.
	82.	Transfer tissues into pHM by passing embryos through 1 mL of the following
		freshly made solutions: (1) 80 % PBS-Tr, 20 % pHM; (2) 50 % PBS-Tr, 50 %
		pHM; (3) 20 % PBS-Tr, 80 % pHM; (4) 100 % pHM. Incubate 20 min at RT on a
		rotating wheel for each step.
		CRITICAL STEP: Before exchanging solutions, allow the embryos to settle
		down 2-3 min.
	83.	Prepare primary DNA probe by adding 45-225 pmol of Oligopaint probe to 25
		µL of DHS. Keep the mix on ice. Denature primary DNA probe by incubating for
		15 min at 80 °C in the Thermomixer.
		CRITICAL STEP: The amount of probe employed should be tested by
		quantifying the efficiency of labeling vs. increasing concentrations of DNA probe
		.
	84.	Carefully remove the pHM solution from the embryos tube and add 1 mL of
		fresh pHM. Denature embryonic DNA by incubating for 15 min at 80 °C in a
		water bath.
	85.
		In situ hybridization * Timing 1.5 days
	78.	Transfer ~30 µL of embryos from either step 50 or 77 to a 1.5 mL tube.
		CRITICAL STEP: Use a glass Pasteur pipette to prevent embryos sticking to
		the pipette.
	79.

Rehydrate the fixed embryos by incubating them with 1 mL of the following solutions (1) 90 % methanol, 10 % PBT; (2) 70 % methanol, 30 % PBT; (3) 50 % methanol, 50 % PBT; (4) 30 % methanol, 70 % PBT; (5) 100 % PBT. Incubate 3-5 min at RT on a rotating wheel for each step.

CRITICAL Carefully remove the pHM solution from the embryos tube and add 30 µL of the probes. Mix by gently flicking the tube with a finger. Carefully add 40 µL of mineral oil. Change the water bath temperature to 37 °C and incubate the embryos ON at 37 °C in the water bath. CRITICAL STEP: Mineral oil layer is added on top to prevent evaporation. CRITICAL STEP: Allowing the embryos to slowly cool down from 80 °C to 37 °C in the water bath greatly increases efficiency of labeling. 86.

  Click once to define the vertices of the polygon. If needed, use the backspace key to delete last vertex. Double-click once done with the selection.137. Build results structure. 138. Control how successful was the clustering of spots in single nuclei by running the " Assesses results quality" block. A high percentage (over 80%) of clustered barcode spots is expected. ? TROUBLESHOOTING 139. Assign detected readouts to the segmented nuclei, and build the CellID structure, by running the "Finds RTs for each Cell mask in each ROI" block . 140. Save segmented data, by saving MATLAB's workspace. 141. Launch merfish_cellID_analysis_v4.m analysis software in MATLAB. The script is written in a modular way, where user must sequentially execute (Control+Enter) the different steps that are described from now on. Place the files obtained in previous step in a folder, and add the folder path to the data path in the program. 142. Load datasets, by running the first section.

Table 6 .

 6 Troubleshooting table

	1-7, design of Oligopaint libraries: 4-5 h
	Steps 8-39, amplification of Oligopaints: 4-5 days
	Steps 40-50, embryo collection and fixation: 2-3 h
	Steps 51-77, RNA in situ hybridization: 2.5 days

Acknowledgments

This project has received funding from the European Research Council (ERC) under the European Union's Horizon 2020 Research and Innovation Program (grant ID 724429). This work also benefited from support from Labex EpiGenMed, an ''Investments for the Future'' program (grant ID ANR-10-LABX-12-01). We acknowledge the France-BioImaging infrastructure supported by the French National Research Agency (grant ID ANR-10-INBS-04, ''Investments for the Future''). A.M.C.G. is at present a postdoctoral fellow of Consejo Nacional de Investigaciones Científicas y Técnicas (CONICET).

Author contributions statements

Competing interests

The authors declare no competing interests.

Data and code availability

The code used and described in this paper as well as the experimental dataset used to construct the Fig. 9 have been uploaded to: https://doi.org/10.17632/5f5hd9yj3z.1#folder-26d1f8c0-fc58-4b87-8c4f-cd8a294a555.S oftware Additional advice on how to use it can be obtained from the authors upon reasonable request. Further information and requests for resources, reagents and software should be directed to and will be fulfilled by the Lead Contact, Marcelo Nollmann (marcelo.nollmann@cbs.cnrs.fr).

Supplementary information

Supplementary Table 1. Fluorescent readout probe sequences. Supplementary Table 2. Readout region sequences. Supplementary Table 3. Universal priming region sequences.