Skip to content

Commit

Permalink
automatic update
Browse files Browse the repository at this point in the history
  • Loading branch information
mmoda-esg-bot committed Dec 10, 2024
1 parent a0bbe0f commit acc600e
Show file tree
Hide file tree
Showing 4 changed files with 121 additions and 16 deletions.
35 changes: 35 additions & 0 deletions tools/analyse-short-astro-text/Untitled.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
#!/usr/bin/env python
# coding: utf-8

_galaxy_wd = os.getcwd()

with open("inputs.json", "r") as fd:
inp_dic = json.load(fd)
if "_data_product" in inp_dic.keys():
inp_pdic = inp_dic["_data_product"]
else:
inp_pdic = inp_dic

# flake8: noqa

import json
import os

from pipeline_ra_dec import rule_based_ra_dec_detector

text = "The candidate Be/X-ray Binary system RX J0032.9-7348 (ATEL #16880) has been detected in 2 observations conducted by the Swift SMC Survey (S-CUBED) over the past month. This system was first detected by S-CUBED on 22 October 2024 with a 0.3-10 keV band flux of 1.46 x 10^-11 erg/cm^2/s. The most recent detection, obtained by Swift on 11 November 2024, shows that the source has since brightened to a 0.3-10 keV flux of 2.77 x 10^-11 erg/cm^2/s. The time-averaged spectrum of both observations is best fit to an absorbed power law with a photon index of 0.7 (+0.5, -0.4) and a column density of NH = 4.2 (+29.9, - 4.2) x 10^20 cm^-2.Using S-CUBED data, we can refine the localization of this source to a new position of: R.A. = 00:32:59.30 (8.22459d), Dec. = -73:48:28.1 (-73.8078d) with a 90% confidence error region of 4.3 arc-seconds. This new position places RX J0032.9-7348 within 5” of two early-type stars. One of these stars is the B0.5V star GSC 09141-01338 (Evans et al., 2004). The other is marked as Object 1 in Figure 1a of Stevens el al. (1999), where it is observed to have an emission feature that corresponds to the Balmer Series Hydrogen alpha line. However, those authors were searching a large ROSAT error region and warned that there were many such H-alpha emitters in the region. At this time, the exact optical counterpart cannot be determined. Further observations are required to distinguish between the two stars. "
text_id = "16900"

rule_based_ra_dec_detector(text_id, text)

from astropy import units as u
from astropy.coordinates import SkyCoord

SkyCoord(ra="00:32:59.30", dec="-73:48:28.1", unit=(u.hourangle, u.deg))

# output gathering
_galaxy_meta_data = {}

with open(os.path.join(_galaxy_wd, "galaxy.json"), "w") as fd:
json.dump(_galaxy_meta_data, fd)
print("*** Job finished successfully ***")
Original file line number Diff line number Diff line change
Expand Up @@ -15,30 +15,70 @@
<requirement type="package" version="4.43.2">transformers</requirement>
<requirement type="package" version="1.2.28">oda-api</requirement>
<requirement type="package" version="1.4.0">fake-useragent</requirement>
<requirement type="package" version="8.30.0">ipython</requirement>
<!--Requirements string 'nb2workflow' can't be converted automatically. Please add the galaxy/conda requirement manually or modify the requirements file!-->
</requirements>
<command detect_errors="exit_code">python '$__tool_directory__/extract_data_predict_workflow.py'</command>
<command detect_errors="exit_code">python '$__tool_directory__/${_data_product._selector}.py'</command>
<configfiles>
<inputs name="inputs" filename="inputs.json" data_style="paths" />
</configfiles>
<inputs>
<param name="text" type="text" value="We received an alert about a candidate fast transient from the FINK broker (Peloton, Ishida &amp; Moller et al.) on 2024-06-22 09:58:42.001 UTC, named ZTF24aasjjkf (https://fink-portal.org/ZTF24aasjjkf). This transient was classified by FINK on the same day with a 17 percent probability of being a fast transient. We triggered the TAROT-TCA and TRT-SRO telescopes for further investigation, observing in the R, r', and i' bands, and collecting data from 2024-06-23 around 04:55:14 UTC to 2024-06-24 01:00:00 UTC. Our results, along with public ZTF data, can be found here: https://skyportal-icare.ijclab.in2p3.fr/public/sources/ZTF24aasjjkf/version/07cf393bb53513abe80d3b7863938d8f TAROT-TCA telescope observations can be also labeled as generic in the plot. We utilized STDWeb (Karpov et al.) to perform our photometry, using the Pan-STARRS DR1 (PS1) catalog and subtracting the constant flux of background with a reference PS1 image. We note that in the TAROT-TCA data, we have slight contamination from other stars. However, we mitigated this effect by subtracting the PS1 reference image. According to the ZTF data in the r' band, both before and after our observations, as well as ATLAS data (in the orange band) and the Gaia Alert (2024LXA), the source might be 10 days old or more. Its multi-band light curve is not consistent with a fast transient like a kilonova (a decay rate of 0.15 per day in r-band) but resembles a supernova (also classified by FINK on 2024-06-24 at 08:00 UTC). The source has been independently classified by Jianlin Xu et al. as a CV. We thank the FINK team for their valuable collaboration with GRANDMA. GRANDMA is a worldwide telescope network (https://grandma.lal.in2p3.fr/) devoted to the observation of transients in the context of multi-messenger astrophysics (Antier et al. 2020 MNRAS 497, 5518). Kilonova-Catcher (KNC) is the citizen science program of GRANDMA (http://kilonovacatcher.in2p3.fr/)." label="text" />
<param name="number" type="text" value="ATel #16672" label="number" />
<conditional name="_data_product">
<param name="_selector" type="select" label="Data Product">
<option value="extract_data_predict_workflow" selected="true">extract_data_predict_workflow</option>
<option value="Untitled" selected="false">Untitled</option>
</param>
<when value="extract_data_predict_workflow">
<param name="text" type="text" value="We received an alert about a candidate fast transient from the FINK broker (Peloton, Ishida &amp; Moller et al.) on 2024-06-22 09:58:42.001 UTC, named ZTF24aasjjkf (https://fink-portal.org/ZTF24aasjjkf). This transient was classified by FINK on the same day with a 17 percent probability of being a fast transient. We triggered the TAROT-TCA and TRT-SRO telescopes for further investigation, observing in the R, r', and i' bands, and collecting data from 2024-06-23 around 04:55:14 UTC to 2024-06-24 01:00:00 UTC. Our results, along with public ZTF data, can be found here: https://skyportal-icare.ijclab.in2p3.fr/public/sources/ZTF24aasjjkf/version/07cf393bb53513abe80d3b7863938d8f TAROT-TCA telescope observations can be also labeled as generic in the plot. We utilized STDWeb (Karpov et al.) to perform our photometry, using the Pan-STARRS DR1 (PS1) catalog and subtracting the constant flux of background with a reference PS1 image. We note that in the TAROT-TCA data, we have slight contamination from other stars. However, we mitigated this effect by subtracting the PS1 reference image. According to the ZTF data in the r' band, both before and after our observations, as well as ATLAS data (in the orange band) and the Gaia Alert (2024LXA), the source might be 10 days old or more. Its multi-band light curve is not consistent with a fast transient like a kilonova (a decay rate of 0.15 per day in r-band) but resembles a supernova (also classified by FINK on 2024-06-24 at 08:00 UTC). The source has been independently classified by Jianlin Xu et al. as a CV. We thank the FINK team for their valuable collaboration with GRANDMA. GRANDMA is a worldwide telescope network (https://grandma.lal.in2p3.fr/) devoted to the observation of transients in the context of multi-messenger astrophysics (Antier et al. 2020 MNRAS 497, 5518). Kilonova-Catcher (KNC) is the citizen science program of GRANDMA (http://kilonovacatcher.in2p3.fr/)." label="text" />
<param name="number" type="text" value="ATel #16672" label="number" />
</when>
<when value="Untitled" />
</conditional>
</inputs>
<outputs>
<data label="${tool.name} -&gt; extract_data_predict_workflow table_telescopes" name="out_extract_data_predict_workflow_table_telescopes" format="auto" from_work_dir="table_telescopes_galaxy.output" />
<data label="${tool.name} -&gt; extract_data_predict_workflow table_sources" name="out_extract_data_predict_workflow_table_sources" format="auto" from_work_dir="table_sources_galaxy.output" />
<data label="${tool.name} -&gt; extract_data_predict_workflow table_unknown_sources" name="out_extract_data_predict_workflow_table_unknown_sources" format="auto" from_work_dir="table_unknown_sources_galaxy.output" />
<data label="${tool.name} -&gt; extract_data_predict_workflow table_source_classes" name="out_extract_data_predict_workflow_table_source_classes" format="auto" from_work_dir="table_source_classes_galaxy.output" />
<data label="${tool.name} -&gt; extract_data_predict_workflow table_astrobert_results" name="out_extract_data_predict_workflow_table_astrobert_results" format="auto" from_work_dir="table_astrobert_results_galaxy.output" />
<data label="${tool.name} -&gt; extract_data_predict_workflow table_vectorized_text" name="out_extract_data_predict_workflow_table_vectorized_text" format="auto" from_work_dir="table_vectorized_text_galaxy.output" />
<data label="${tool.name} -&gt; extract_data_predict_workflow table_vectorized_url" name="out_extract_data_predict_workflow_table_vectorized_url" format="auto" from_work_dir="table_vectorized_url_galaxy.output" />
<data label="${tool.name} -&gt; extract_data_predict_workflow table_vectorized_url_scores" name="out_extract_data_predict_workflow_table_vectorized_url_scores" format="auto" from_work_dir="table_vectorized_url_scores_galaxy.output" />
<data label="${tool.name} -&gt; extract_data_predict_workflow table_telescopes" name="out_extract_data_predict_workflow_table_telescopes" format="auto" from_work_dir="table_telescopes_galaxy.output">
<filter>_data_product['_selector'] == 'extract_data_predict_workflow'</filter>
</data>
<data label="${tool.name} -&gt; extract_data_predict_workflow table_sources" name="out_extract_data_predict_workflow_table_sources" format="auto" from_work_dir="table_sources_galaxy.output">
<filter>_data_product['_selector'] == 'extract_data_predict_workflow'</filter>
</data>
<data label="${tool.name} -&gt; extract_data_predict_workflow table_source_positions" name="out_extract_data_predict_workflow_table_source_positions" format="auto" from_work_dir="table_source_positions_galaxy.output">
<filter>_data_product['_selector'] == 'extract_data_predict_workflow'</filter>
</data>
<data label="${tool.name} -&gt; extract_data_predict_workflow table_unknown_sources" name="out_extract_data_predict_workflow_table_unknown_sources" format="auto" from_work_dir="table_unknown_sources_galaxy.output">
<filter>_data_product['_selector'] == 'extract_data_predict_workflow'</filter>
</data>
<data label="${tool.name} -&gt; extract_data_predict_workflow table_source_classes" name="out_extract_data_predict_workflow_table_source_classes" format="auto" from_work_dir="table_source_classes_galaxy.output">
<filter>_data_product['_selector'] == 'extract_data_predict_workflow'</filter>
</data>
<data label="${tool.name} -&gt; extract_data_predict_workflow table_astrobert_results" name="out_extract_data_predict_workflow_table_astrobert_results" format="auto" from_work_dir="table_astrobert_results_galaxy.output">
<filter>_data_product['_selector'] == 'extract_data_predict_workflow'</filter>
</data>
<data label="${tool.name} -&gt; extract_data_predict_workflow table_vectorized_text" name="out_extract_data_predict_workflow_table_vectorized_text" format="auto" from_work_dir="table_vectorized_text_galaxy.output">
<filter>_data_product['_selector'] == 'extract_data_predict_workflow'</filter>
</data>
<data label="${tool.name} -&gt; extract_data_predict_workflow table_vectorized_url" name="out_extract_data_predict_workflow_table_vectorized_url" format="auto" from_work_dir="table_vectorized_url_galaxy.output">
<filter>_data_product['_selector'] == 'extract_data_predict_workflow'</filter>
</data>
<data label="${tool.name} -&gt; extract_data_predict_workflow table_vectorized_url_scores" name="out_extract_data_predict_workflow_table_vectorized_url_scores" format="auto" from_work_dir="table_vectorized_url_scores_galaxy.output">
<filter>_data_product['_selector'] == 'extract_data_predict_workflow'</filter>
</data>
</outputs>
<tests>
<test expect_num_outputs="8">
<param name="text" value="We received an alert about a candidate fast transient from the FINK broker (Peloton, Ishida &amp; Moller et al.) on 2024-06-22 09:58:42.001 UTC, named ZTF24aasjjkf (https://fink-portal.org/ZTF24aasjjkf). This transient was classified by FINK on the same day with a 17 percent probability of being a fast transient. We triggered the TAROT-TCA and TRT-SRO telescopes for further investigation, observing in the R, r', and i' bands, and collecting data from 2024-06-23 around 04:55:14 UTC to 2024-06-24 01:00:00 UTC. Our results, along with public ZTF data, can be found here: https://skyportal-icare.ijclab.in2p3.fr/public/sources/ZTF24aasjjkf/version/07cf393bb53513abe80d3b7863938d8f TAROT-TCA telescope observations can be also labeled as generic in the plot. We utilized STDWeb (Karpov et al.) to perform our photometry, using the Pan-STARRS DR1 (PS1) catalog and subtracting the constant flux of background with a reference PS1 image. We note that in the TAROT-TCA data, we have slight contamination from other stars. However, we mitigated this effect by subtracting the PS1 reference image. According to the ZTF data in the r' band, both before and after our observations, as well as ATLAS data (in the orange band) and the Gaia Alert (2024LXA), the source might be 10 days old or more. Its multi-band light curve is not consistent with a fast transient like a kilonova (a decay rate of 0.15 per day in r-band) but resembles a supernova (also classified by FINK on 2024-06-24 at 08:00 UTC). The source has been independently classified by Jianlin Xu et al. as a CV. We thank the FINK team for their valuable collaboration with GRANDMA. GRANDMA is a worldwide telescope network (https://grandma.lal.in2p3.fr/) devoted to the observation of transients in the context of multi-messenger astrophysics (Antier et al. 2020 MNRAS 497, 5518). Kilonova-Catcher (KNC) is the citizen science program of GRANDMA (http://kilonovacatcher.in2p3.fr/)." />
<param name="number" value="ATel #16672" />
<test expect_num_outputs="9">
<conditional name="_data_product">
<param name="_selector" value="extract_data_predict_workflow" />
<param name="text" value="We received an alert about a candidate fast transient from the FINK broker (Peloton, Ishida &amp; Moller et al.) on 2024-06-22 09:58:42.001 UTC, named ZTF24aasjjkf (https://fink-portal.org/ZTF24aasjjkf). This transient was classified by FINK on the same day with a 17 percent probability of being a fast transient. We triggered the TAROT-TCA and TRT-SRO telescopes for further investigation, observing in the R, r', and i' bands, and collecting data from 2024-06-23 around 04:55:14 UTC to 2024-06-24 01:00:00 UTC. Our results, along with public ZTF data, can be found here: https://skyportal-icare.ijclab.in2p3.fr/public/sources/ZTF24aasjjkf/version/07cf393bb53513abe80d3b7863938d8f TAROT-TCA telescope observations can be also labeled as generic in the plot. We utilized STDWeb (Karpov et al.) to perform our photometry, using the Pan-STARRS DR1 (PS1) catalog and subtracting the constant flux of background with a reference PS1 image. We note that in the TAROT-TCA data, we have slight contamination from other stars. However, we mitigated this effect by subtracting the PS1 reference image. According to the ZTF data in the r' band, both before and after our observations, as well as ATLAS data (in the orange band) and the Gaia Alert (2024LXA), the source might be 10 days old or more. Its multi-band light curve is not consistent with a fast transient like a kilonova (a decay rate of 0.15 per day in r-band) but resembles a supernova (also classified by FINK on 2024-06-24 at 08:00 UTC). The source has been independently classified by Jianlin Xu et al. as a CV. We thank the FINK team for their valuable collaboration with GRANDMA. GRANDMA is a worldwide telescope network (https://grandma.lal.in2p3.fr/) devoted to the observation of transients in the context of multi-messenger astrophysics (Antier et al. 2020 MNRAS 497, 5518). Kilonova-Catcher (KNC) is the citizen science program of GRANDMA (http://kilonovacatcher.in2p3.fr/)." />
<param name="number" value="ATel #16672" />
</conditional>
<assert_stdout>
<has_text text="*** Job finished successfully ***" />
</assert_stdout>
</test>
<test expect_num_outputs="0">
<conditional name="_data_product">
<param name="_selector" value="Untitled" />
</conditional>
<assert_stdout>
<has_text text="*** Job finished successfully ***" />
</assert_stdout>
Expand Down
Loading

0 comments on commit acc600e

Please sign in to comment.