{ "cells": [ { "cell_type": "markdown", "metadata": {}, "source": [ "# Final stage of HELP data processing\n", "\n", "This notebook collates the final output files ready for writing to csv for ingestion to a VO server. At the bottom of the notebook we also summarise the pipeline products which are processed on a given field. This are generated using the dmu32 meta_main.yml files which contain links to the XID+, CIGALE and photo-z catalogues which feed in to the final catalogues for publishing.\n", "\n", "Summary of notebook:\n", "\n", "- Take DR1 masterlist suffixes from overview table\n", "- Find dmu32 full table names and write to a file\n", "- Create summary of all the data products per field using the dmu32 meta_main.yml files" ] }, { "cell_type": "code", "execution_count": 1, "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "This notebook was run with herschelhelp_internal version: \n", "017bb1e (Mon Jun 18 14:58:59 2018 +0100)\n", "This notebook was executed on: \n", "2018-07-12 17:19:01.808314\n" ] } ], "source": [ "from herschelhelp_internal import git_version\n", "print(\"This notebook was run with herschelhelp_internal version: \\n{}\".format(git_version()))\n", "import datetime\n", "print(\"This notebook was executed on: \\n{}\".format(datetime.datetime.now()))" ] }, { "cell_type": "code", "execution_count": 2, "metadata": {}, "outputs": [ { "name": "stderr", "output_type": "stream", "text": [ "/opt/anaconda3/envs/herschelhelp_internal/lib/python3.6/site-packages/seaborn/apionly.py:6: UserWarning: As seaborn no longer sets a default style on import, the seaborn.apionly module is deprecated. It will be removed in a future version.\n", " warnings.warn(msg, UserWarning)\n" ] } ], "source": [ "from astropy.table import Table, Column\n", "from astropy import units as u\n", "import numpy as np\n", "\n", "from pymoc import MOC\n", "\n", "from herschelhelp_internal.masterlist import find_last_ml_suffix\n", "\n", "import yaml\n", "\n", "import os\n", "import time\n", "\n", "import humanfriendly" ] }, { "cell_type": "code", "execution_count": 3, "metadata": { "collapsed": true }, "outputs": [], "source": [ "TODAY = os.environ.get('SUFFIX', time.strftime(\"_%Y%m%d\"))" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## The definition of HELP DR1\n", "Here we take the DR1 definition from dmu1. We then propagate those suffixes through to dmu32. Note that this does not include a specification of how the masterlist made its way through the whole HELP process." ] }, { "cell_type": "code", "execution_count": 4, "metadata": { "collapsed": true }, "outputs": [], "source": [ "dr1 = Table.read(\"../dmu1/dr1_overview.fits\")" ] }, { "cell_type": "code", "execution_count": 5, "metadata": {}, "outputs": [ { "data": { "text/html": [ "Table length=23\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "
idxfielddr1_suffixlast_suffixobjectsarea_sq_degreesfile_size_bytesfile_size_readable
0AKARI-NEP20180215201802155317469.194732358779467348848640348.85 MB
1AKARI-SEP20180221201802218441728.713306475131118538606080538.61 MB
2Bootes2018052020180520348166111.4281529909548650020444805 GB
3CDFS-SWIRE2018061320180613217105112.97124640371706857055939205.71 GB
4COSMOS201806192018061925993745.0838634784968161051717536010.52 GB
5EGS201805012018050114126133.56638327512215838084803203.81 GB
6ELAIS-N12017101620180216402629213.50748455545476352422796805.24 GB
7ELAIS-N2201802182018021817832409.16747990399111320079648002.01 GB
8ELAIS-S1201804162018041616555649.00294064688550819701561601.97 GB
9GAMA-0920180601201806011293798262.013934172849151991161152019.91 GB
10GAMA-1220180218201802181236941562.709332807721071463306688014.63 GB
11GAMA-1520180213201802131423288061.701145659808421659558528016.6 GB
12HDF-N20180427201804271306790.6717832558166041185996160186 MB
13Herschel-Stripe-82201803072018030750196455363.22747930641884127047306240127.05 GB
14Lockman-SWIRE2018021920180219436629822.41386340294921851959318405.2 GB
15NGP20180219201805016759591177.698197107716249548067204.95 GB
16SA13201805012018050197990.2741637932843118427216002.72 MB
17SGP201802212018022129790690294.56845409006424519253088045.19 GB
18SPIRE-NEP201802202018022026740.128066046937739112038401.2 MB
19SSDF201802212018022112661903111.1162494934353980783193608.08 GB
20xFLS20180501201805019771487.4404324214075410504742401.05 GB
21XMM-13hr2018050120180501386290.75702401665836331067616010.68 MB
22XMM-LSS2018050420180504870583721.754579393313742824183872028.24 GB
\n", "\n" ], "text/plain": [ "" ] }, "execution_count": 5, "metadata": {}, "output_type": "execute_result" } ], "source": [ "dr1.show_in_notebook()" ] }, { "cell_type": "code", "execution_count": 6, "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "./dmu32_AKARI-NEP/data/AKARI-NEP_20180215_cigale.fits\n", "./dmu32_AKARI-SEP/data/AKARI-SEP_20180221_cigale.fits\n", "./dmu32_Bootes/data/Bootes_20180520_cigale.fits\n", "./dmu32_CDFS-SWIRE/data/CDFS-SWIRE_20180613.fits\n", "./dmu32_COSMOS/data/COSMOS_20180619.fits\n", "./dmu32_EGS/data/EGS_20180501_cigale.fits\n", "./dmu32_ELAIS-N1/data/ELAIS-N1_20171016.fits\n", "./dmu32_ELAIS-N2/data/ELAIS-N2_20180218_cigale.fits\n", "./dmu32_ELAIS-S1/data/ELAIS-S1_20180416.fits\n", "./dmu32_GAMA-09/data/GAMA-09_20180601.fits\n", "./dmu32_GAMA-12/data/GAMA-12_20180218.fits\n", "./dmu32_GAMA-15/data/GAMA-15_20180213.fits\n", "./dmu32_HDF-N/data/HDF-N_20180427_cigale.fits\n", "./dmu32_Herschel-Stripe-82/data/Herschel-Stripe-82_20180307_cigale.fits\n", "./dmu32_Lockman-SWIRE/data/Lockman-SWIRE_20180219.fits\n", "./dmu32_NGP/data/NGP_20180219_cigale.fits\n", "./dmu32_SA13/data/SA13_20180501_cigale.fits\n", "./dmu32_SGP/data/SGP_20180221.fits\n", "./dmu32_SPIRE-NEP/data/SPIRE-NEP_20180220_cigale.fits\n", "./dmu32_SSDF/data/SSDF_20180221_cigale.fits\n", "./dmu32_xFLS/data/xFLS_20180501_cigale.fits\n", "./dmu32_XMM-13hr/data/XMM-13hr_20180501_cigale.fits\n", "./dmu32_XMM-LSS/data/XMM-LSS_20180504_cigale.fits\n" ] } ], "source": [ "GAVO_FOLDER = '/mnt/hedam/data_vo/'\n", "stilts_command = 'stilts tpipe {in_file} omode=out ofmt=csv out={GAVO_FOLDER}{out_file}'\n", "\n", "final_data = open('help_to_vo.sh', 'w+')\n", "for field in dr1:\n", " final_help_product = './dmu32_{}/data/{}_{}.fits'.format(field[0], field[0], field[1])\n", " cigale_input = './dmu32_{}/data/{}_{}_cigale.fits'.format(field[0], field[0], field[1])\n", "\n", " if os.path.exists(final_help_product):\n", " print(final_help_product)\n", " \n", " #Test with Cigale input files\n", " final_data.write(stilts_command.format(in_file=final_help_product, \n", " GAVO_FOLDER=GAVO_FOLDER, \n", " out_file='herschelhelp/main/{}_{}_all.csv \\n'.format(field[0], \n", " field[1])))\n", " elif os.path.exists(cigale_input):\n", " print(cigale_input)\n", " final_data.write(stilts_command.format(in_file=cigale_input, \n", " GAVO_FOLDER=GAVO_FOLDER, \n", " out_file='herschelhelp/main/{}_{}_incomplete.csv \\n'.format(field[0], \n", " field[1])))\n", " \n", " else:\n", " final_data.write('# No data for {} \\n'.format(field[0]))\n", " \n", " #final_data.write('./dmu32_{}/data/{}_{}.fits'.format(field[0], field[0], field[1]))\n", " \n", "final_data.close()" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "The out put of this notebook is a shell script which will write all the fits files to csv files in the vo folder" ] }, { "cell_type": "code", "execution_count": 7, "metadata": { "collapsed": true }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "../dmu1/dmu1_ml_AKARI-NEP/data/depths_akari-nep_20180215.fits\n", "../dmu1/dmu1_ml_AKARI-SEP/data/depths_akari-sep_20180221.fits\n", "../dmu1/dmu1_ml_Bootes/data/depths_bootes_20180520.fits\n", "../dmu1/dmu1_ml_CDFS-SWIRE/data/depths_cdfs-swire_20180613.fits\n", "../dmu1/dmu1_ml_COSMOS/data/depths_cosmos_20180619.fits\n", "../dmu1/dmu1_ml_EGS/data/depths_egs_20180501.fits\n", "../dmu1/dmu1_ml_ELAIS-N1/data/depths_elais-n1_20171016.fits\n", "../dmu1/dmu1_ml_ELAIS-N2/data/depths_elais-n2_20180218.fits\n", "../dmu1/dmu1_ml_ELAIS-S1/data/depths_elais-s1_20180416.fits\n", "../dmu1/dmu1_ml_GAMA-09/data/depths_gama-09_20180601.fits\n", "../dmu1/dmu1_ml_GAMA-12/data/depths_gama-12_20180218.fits\n", "../dmu1/dmu1_ml_GAMA-15/data/depths_gama-15_20180213.fits\n", "../dmu1/dmu1_ml_HDF-N/data/depths_hdf-n_20180427.fits\n", "../dmu1/dmu1_ml_Herschel-Stripe-82/data/depths_herschel-stripe-82_20180307.fits\n", "../dmu1/dmu1_ml_Lockman-SWIRE/data/depths_lockman-swire_20180219.fits\n", "../dmu1/dmu1_ml_NGP/data/depths_ngp_20180219.fits\n", "../dmu1/dmu1_ml_SA13/data/depths_sa13_20180501.fits\n", "../dmu1/dmu1_ml_SGP/data/depths_sgp_20180221.fits\n", "../dmu1/dmu1_ml_SPIRE-NEP/data/depths_spire-nep_20180220.fits\n", "../dmu1/dmu1_ml_SSDF/data/depths_ssdf_20180221.fits\n", "../dmu1/dmu1_ml_xFLS/data/depths_xfls_20180501.fits\n", "../dmu1/dmu1_ml_XMM-13hr/data/depths_xmm-13hr_20180501.fits\n", "../dmu1/dmu1_ml_XMM-LSS/data/depths_xmm-lss_20180504.fits\n" ] } ], "source": [ "depths_to_vo = open('depths_to_vo.sh', 'w+')\n", "for field in dr1:\n", " final_depth_product = '../dmu1/dmu1_ml_{}/data/depths_{}_{}.fits'.format(field[0], field[0].lower(), field[1])\n", " \n", "\n", " if os.path.exists(final_depth_product):\n", " print(final_depth_product)\n", " \n", " #Test with Cigale input files\n", " depths_to_vo.write(stilts_command.format(in_file=final_depth_product, \n", " GAVO_FOLDER=GAVO_FOLDER, \n", " out_file='depth/{}_{}.csv \\n'.format(field[0], \n", " field[1])))\n", "\n", " \n", " else:\n", " depths_to_vo.write('# No depths for {} \\n'.format(field[0]))\n", " \n", " #final_data.write('./dmu32_{}/data/{}_{}.fits'.format(field[0], field[0], field[1]))\n", " \n", "depths_to_vo.close()" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Summarise completeness of HELP data sets\n", "\n", "Here we get information about what is available on each field to summarise the data products available per field. We take the cigale, xid+ and photo-z filenames from the per field meta_main.yml files here and check they are there and how large they are. This then given a summary of all the data present." ] }, { "cell_type": "code", "execution_count": 8, "metadata": { "collapsed": true }, "outputs": [], "source": [ "dr1_data_products = dr1.copy()\n", "\n", "fields_info = yaml.load(open(\"../dmu2/meta_main.yml\", 'r'))" ] }, { "cell_type": "code", "execution_count": 9, "metadata": { "collapsed": true }, "outputs": [], "source": [ "dr1_data_products.add_column(Column(data =np.full(len(dr1_data_products), 0, dtype=int), name = 'xid_objects'))\n", "dr1_data_products.add_column(Column(data =np.full(len(dr1_data_products), 0, dtype=int), name = 'photoz_objects'))\n", "dr1_data_products.add_column(Column(data =np.full(len(dr1_data_products), 0, dtype=int), name = 'cigale_objects'))" ] }, { "cell_type": "code", "execution_count": 10, "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "AKARI-NEP:\n", " - xid not done.\n", " - photoz not done.\n", " - cigale not done.\n", "AKARI-SEP:\n", " - xid not done.\n", " - photoz not done.\n", " - cigale not done.\n", "Bootes:\n", " - xid not done.\n", " - photoz not done.\n", " - cigale not done.\n", "CDFS-SWIRE:\n", " - xid: dmu_products/dmu26/dmu26_XID+SPIRE_CDFS-SWIRE/data/dmu26_XID+SPIRE_CDFS-SWIRE_cat_20170919.fits\n", " - xid: dmu_products/dmu26/dmu26_XID+MIPS_CDFS-SWIRE/data/dmu26_XID+MIPS_CDFS-SWIRE_cat_20170901.fits\n", " - xid: dmu_products/dmu26/dmu26_XID+PACS_CDFS-SWIRE/data/dmu26_XID+PACS_CDFS-SWIRE_cat_20171019.fits\n", " - photoz: dmu_products/dmu24/dmu24_CDFS-SWIRE/data/master_catalogue_cdfs-swire_20171103_photoz_20180210.fits\n", " - cigale: dmu_products/dmu28/dmu28_CDFS-SWIRE/data/zphot/HELP_final_results.fits\n", "COSMOS:\n", " - xid: dmu_products/dmu26/dmu26_XID+MIPS_COSMOS/data/dmu26_XID+MIPS_COSMOS_20170213.fits\n", " - xid: dmu_products/dmu26/dmu26_XID+PACS_COSMOS/data/dmu26_XID+PACS_COSMOS_20170303.fits\n", " - xid: dmu_products/dmu26/dmu26_XID+SPIRE_COSMOS/data/dmu26_XID+SPIRE_COSMOS_20161129.fits\n", " - photoz: dmu_products/dmu24/dmu24_COSMOS/data/COSMOS2015-HELP_selected_20160613_photoz_v1.0.fits\n", " - cigale: dmu_products/dmu28/dmu28_COSMOS/data/zphot/final_results.fits\n", "EGS:\n", " - xid not done.\n", " - photoz: dmu_products/dmu24/dmu24_EGS/data/master_catalogue_egs_20180501_photoz_20180608.fits\n", " - cigale not done.\n", "ELAIS-N1:\n", " - xid: dmu_products/dmu26/dmu26_XID+MIPS_ELAIS-N1/data/dmu26_XID+MIPS_ELAIS-N1_SERVS_cat_20170725.fits\n", " - xid: dmu_products/dmu26/dmu26_XID+PACS_ELAIS-N1/data/dmu26_XID+PACS_ELAIS-N1_SWIRE_cat_20170808.fits\n", " - xid: dmu_products/dmu26/dmu26_XID+SPIRE_ELAIS-N1/data/dmu26_XID+SPIRE_ELAIS-N1_SERVS_cat_20170725.fits\n", " - photoz: dmu_products/dmu24/dmu24_ELAIS-N1/data/master_catalogue_elais-n1_20170706_photoz_20170725_irac1_optimised.fits\n", " - cigale: dmu_products/dmu28/dmu28_ELAIS-N1/data/zphot/HELP_final_results.fits\n", "ELAIS-N2:\n", " - xid not done.\n", " - photoz not done.\n", " - cigale not done.\n", "ELAIS-S1:\n", " - xid: dmu_products/dmu26/dmu26_XID+MIPS_ELAIS-S1/data/dmu26_XID+MIPS_ELAIS-S1_20180215.fits\n", " - xid: dmu_products/dmu26/dmu26_XID+PACS_ELAIS-S1/data/dmu26_XID+PACS_ELAIS-S1_cat_20180416.fits\n", " - xid: dmu_products/dmu26/dmu26_XID+SPIRE_ELAIS-S1/data/dmu26_XID+SPIRE_ELAIS-S1_20180327.fits\n", " - photoz: dmu_products/dmu24/dmu24_ELAIS-S1/data/master_catalogue_elais-s1_20180221_photoz_20180412.fits\n", " - cigale: dmu_products/dmu28/dmu28_ELAIS-S1/data/zphot/HELP_final_results.fits\n", "GAMA-09:\n", " - xid: dmu_products/dmu26/dmu26_XID+SPIRE_GAMA-09/data/dmu26_XID+SPIRE_GAMA-09_20180508.fits\n", " - photoz: dmu_products/dmu24/dmu24_GAMA-09/data/master_catalogue_gama-09_20171206_photoz_20180213_r_optimised.fits\n", " - cigale: dmu_products/dmu28/dmu28_GAMA-09/data/zphot/HELP_final_results.fits\n", "GAMA-12:\n", " - xid: dmu_products/dmu26/dmu26_XID+SPIRE_GAMA-12/data/dmu26_XID+SPIRE_GAMA_12_20180508.fits\n", " - photoz: dmu_products/dmu24/dmu24_GAMA-12/data/master_catalogue_gama-12_20171210_photoz_20180410_r_optimised.fits\n", " - cigale: dmu_products/dmu28/dmu28_GAMA-12/data/zphot/HELP_final_results.fits\n", "GAMA-15:\n", " - xid: dmu_products/dmu26/dmu26_XID+SPIRE_GAMA-15/data/dmu26_XID+SPIRE_GAMA-15_cat_20180416.fits\n", " - photoz: dmu_products/dmu24/dmu24_GAMA-15/data/master_catalogue_gama-15_20180119_photoz_20180210_r_optimised.fits\n", " - cigale: dmu_products/dmu28/dmu28_GAMA-15/data/zphot/HELP_final_results.fits\n", "HDF-N:\n", " - xid not done.\n", " - photoz not done.\n", " - cigale not done.\n", "Herschel-Stripe-82:\n", " - xid not done.\n", " - photoz: dmu_products/dmu24/dmu24_Herschel-Stripe-82/data/master_catalogue_herschel-stripe-82_20180307_photoz_20180509.fits\n", " - cigale not done.\n", "Lockman-SWIRE:\n", " - xid: dmu_products/dmu26/dmu26_XID+MIPS_Lockman-SWIRE/data/dmu26_XID+MIPS_Lockman-SWIRE_cat_20171214.fits\n", " - xid: dmu_products/dmu26/dmu26_XID+PACS_Lockman-SWIRE/data/dmu26_XID+PACS_Lockman-SWIRE_cat_20180220.fits\n", " - xid: dmu_products/dmu26/dmu26_XID+SPIRE_Lockman-SWIRE/data/dmu26_XID+SPIRE_Lockman-SWIRE_20180220.fits\n", " - photoz: dmu_products/dmu24/dmu24_Lockman-SWIRE/data/master_catalogue_Lockman-SWIRE_20170710_photoz_20170802_r_and_irac1_optimised_UPDATED_IDs_20180219.fits\n", " - cigale: dmu_products/dmu28/dmu28_Lockman-SWIRE/data/zphot/best_extcor/HELP_final_results.fits\n", "NGP:\n", " - xid not done.\n", " - photoz: dmu_products/dmu24/dmu24_NGP/data/master_catalogue_ngp_20180501_photoz_20180601_r_optimised.fits\n", " - cigale not done.\n", "SA13:\n", " - xid not done.\n", " - photoz not done.\n", " - cigale not done.\n", "SGP:\n", " - xid: dmu_products/dmu26/dmu26_XID+SPIRE_SGP/data/dmu26_XID+SPIRE_SGP_20180625.fits\n", " - photoz: dmu_products/dmu24/dmu24_SGP/data/master_catalogue_sgp_20180221_photoz_20180502_r_optimised.fits\n", " - cigale: dmu_products/dmu28/dmu28_SGP/data/zphot/HELP_final_results.fits\n", "SPIRE-NEP:\n", " - xid not done.\n", " - photoz not done.\n", " - cigale not done.\n", "SSDF:\n", " - xid not done.\n", " - photoz: dmu_products/dmu24/dmu24_SSDF/data/master_catalogue_ssdf_20180221_photoz_20180612_r_optimised.fits\n", " - cigale not done.\n", "xFLS:\n", " - xid not done.\n", " - photoz not done.\n", " - cigale not done.\n", "XMM-13hr:\n", " - xid not done.\n", " - photoz not done.\n", " - cigale not done.\n", "XMM-LSS:\n", " - xid not done.\n", " - photoz: dmu_products/dmu24/dmu24_XMM-LSS/data/master_catalogue_xmm-lss_20180221_photoz_20180518_r_optimised.fits\n", " - cigale not done.\n" ] } ], "source": [ "for field in fields_info['fields']:\n", " print(field['name'] + ':')\n", " xid_objects = 0\n", " photoz_objects = 0\n", " cigale_objects = 0\n", " dmu32_info = yaml.load(open('./dmu32_{}/meta_main.yml'.format(field['name']), 'r'))\n", "\n", " \n", " try: \n", " for n, xid_file in enumerate(dmu32_info['xid']):\n", " #print(n,xid_file,xid_file.replace('dmu_products', '..'))\n", " xid_objects = len(Table.read(xid_file.replace('dmu_products', '..')))\n", " print(\" - xid: {}\".format(dmu32_info['xid'][n]))\n", " except FileNotFoundError:\n", " print(\" - xid not done.\".format(field['name']))\n", " \n", " try: \n", " #print(dmu32_info['photoz'].replace('dmu_products', '..'))\n", " photoz_objects = len(Table.read(dmu32_info['photoz'].replace('dmu_products', '..')))\n", " print(\" - photoz: {}\".format(dmu32_info['photoz']))\n", " except FileNotFoundError:\n", " print(\" - photoz not done.\".format(field['name']))\n", " \n", " try: \n", " cigale_objects = len(Table.read(dmu32_info['cigale'].replace('dmu_products', '..')))\n", " print(\" - cigale: {}\".format(dmu32_info['cigale']))\n", " except FileNotFoundError:\n", " print(\" - cigale not done.\".format(field['name']))\n", " \n", " \n", " dr1_data_products['xid_objects'][dr1_data_products['field'] == field['name']] = xid_objects\n", " dr1_data_products['photoz_objects'][dr1_data_products['field'] == field['name']] = photoz_objects\n", " dr1_data_products['cigale_objects'][dr1_data_products['field'] == field['name']] = cigale_objects" ] }, { "cell_type": "code", "execution_count": 11, "metadata": {}, "outputs": [ { "data": { "text/html": [ "Table length=23\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "
idxfielddr1_suffixlast_suffixobjectsarea_sq_degreesfile_size_bytesfile_size_readablexid_objectsphotoz_objectscigale_objects
0AKARI-NEP20180215201802155317469.194732358779467348848640348.85 MB000
1AKARI-SEP20180221201802218441728.713306475131118538606080538.61 MB000
2Bootes2018052020180520348166111.4281529909548650020444805 GB000
3CDFS-SWIRE2018061320180613217105112.97124640371706857055939205.71 GB2404891395329308
4COSMOS201806192018061925993745.0838634784968161051717536010.52 GB4431069447815747
5EGS201805012018050114126133.56638327512215838084803203.81 GB011834900
6ELAIS-N12017101620180216402629213.50748455545476352422796805.24 GB120282288511650129
7ELAIS-N2201802182018021817832409.16747990399111320079648002.01 GB000
8ELAIS-S1201804162018041616555649.00294064688550819701561601.97 GB194276110231925393
9GAMA-0920180601201806011293798262.013934172849151991161152019.91 GB13866598834023130293
10GAMA-1220180218201802181236941562.709332807721071463306688014.63 GB10994778591676108139
11GAMA-1520180213201802131423288061.701145659808421659558528016.6 GB123639510109159117234
12HDF-N20180427201804271306790.6717832558166041185996160186 MB000
13Herschel-Stripe-82201803072018030750196455363.22747930641884127047306240127.05 GB0216138210
14Lockman-SWIRE2018021920180219436629822.41386340294921851959318405.2 GB242065138243846719
15NGP20180219201805016759591177.698197107716249548067204.95 GB031753390
16SA13201805012018050197990.2741637932843118427216002.72 MB000
17SGP201802212018022129790690294.56845409006424519253088045.19 GB351159417057212352804
18SPIRE-NEP201802202018022026740.128066046937739112038401.2 MB000
19SSDF201802212018022112661903111.1162494934353980783193608.08 GB092687830
20xFLS20180501201805019771487.4404324214075410504742401.05 GB000
21XMM-13hr2018050120180501386290.75702401665836331067616010.68 MB000
22XMM-LSS2018050420180504870583721.754579393313742824183872028.24 GB061529200
\n", "\n" ], "text/plain": [ "" ] }, "execution_count": 11, "metadata": {}, "output_type": "execute_result" } ], "source": [ "dr1_data_products.show_in_notebook()" ] }, { "cell_type": "code", "execution_count": 12, "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "XID+: There are 9 fields with XID+ fluxes computed totalling 543.97 square degrees.\n", " This is a total of 8075547 objects with an average of 10% of objects on processed areas.\n", "Photo-zs: There are 14 fields with photozs computed totalling 1221.34 square degrees.\n", " This is a total of 92190306 objects with an average of 56% of objects on processed areas.\n", "CIGALE SEDs: There are 9 fields with SEDs computed totalling 543.97 square degrees.\n", " This is a total of 855766 objects with an average of 1% of objects on processed areas.\n" ] } ], "source": [ "has_xid = dr1_data_products['xid_objects'] != 0\n", "has_photoz = dr1_data_products['photoz_objects'] != 0\n", "has_cigale = dr1_data_products['cigale_objects'] != 0\n", "\n", "print(\"XID+: There are {} fields with XID+ fluxes computed totalling {area:.2f} square degrees.\".format(\n", " np.sum(has_xid),\n", " area=np.sum(dr1_data_products['area_sq_degrees'][has_xid])))\n", "print(\" This is a total of {} objects with an average of {perc:.0f}% of objects on processed areas.\".format(\n", " np.sum(dr1_data_products['xid_objects'][has_xid]),\n", " perc=100 * np.sum(dr1_data_products['xid_objects'][has_xid])/np.sum(dr1_data_products['objects'][has_xid])))\n", "\n", "print(\"Photo-zs: There are {} fields with photozs computed totalling {area:.2f} square degrees.\".format(\n", " np.sum(has_photoz),\n", " area=np.sum(dr1_data_products['area_sq_degrees'][has_photoz])))\n", "print(\" This is a total of {} objects with an average of {perc:.0f}% of objects on processed areas.\".format(\n", " np.sum(dr1_data_products['photoz_objects'][has_photoz]),\n", " perc=100 * np.sum(dr1_data_products['photoz_objects'][has_photoz])/np.sum(dr1_data_products['objects'][has_photoz])))\n", "\n", "print(\"CIGALE SEDs: There are {} fields with SEDs computed totalling {area:.2f} square degrees.\".format(\n", " np.sum(has_cigale),\n", " area=np.sum(dr1_data_products['area_sq_degrees'][has_cigale])))\n", "print(\" This is a total of {} objects with an average of {perc:.0f}% of objects on processed areas.\".format(\n", " np.sum(dr1_data_products['cigale_objects'][has_cigale]),\n", " perc=100 * np.sum(dr1_data_products['cigale_objects'][has_cigale])/np.sum(dr1_data_products['objects'][has_cigale])))" ] }, { "cell_type": "code", "execution_count": 13, "metadata": { "collapsed": true }, "outputs": [], "source": [ "dr1_data_products.write('dr1_data_products_overview{}.csv'.format(TODAY), overwrite=True)" ] } ], "metadata": { "kernelspec": { "display_name": "Python (herschelhelp_internal)", "language": "python", "name": "helpint" }, "language_info": { "codemirror_mode": { "name": "ipython", "version": 3 }, "file_extension": ".py", "mimetype": "text/x-python", "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", "version": "3.6.8" } }, "nbformat": 4, "nbformat_minor": 2 }