<commit_before>#!/sw/arch/bin/perl -w

use strict;
use FileHandle;
use DBI;

my $rfam_release = "10.1";

my $in_file = shift;
# prefix, e.g. the seq_region name to be received as a command-line argument
my $prefix = shift || "";

print STDERR "gene name prefix set to $prefix\n";

if (!defined $in_file) {
  die "input file not specified!\n";
}

# output

#chrI    SGD     ncRNA   99306   99869   .       +       .       ID=HRA1;Name=HRA1;gene=HRA1;Alias=HRA1;Ontology_term=GO:0003674,GO:0005575,GO:0000462;Note=Non-protein-coding%20RNA%2C%20substrate%20of%20RNase%20P%2C%20possibly%20involved%20in%20rRNA%20processing%2C%20specifically%20maturation%20of%2020S%20precursor%20into%20the%20mature%2018S%20rRNA;dbxref=SGD:S000119380
#chrI    SGD     noncoding_exon  99306   99869   .       +       .       Parent=HRA1;Name=HRA1;gene=HRA1;Alias=HRA1;Ontology_term=GO:0003674,GO:0005575,GO:0000462,SO:0000198;Note=Non-protein-coding%20RNA%2C%20substrate%20of%20RNase%20P%2C%20possibly%20involved%20in%20rRNA%20processing%2C%20specifically%20maturation%20of%2020S%20precursor%20into%20the%20mature%2018S%20rRNA;dbxref=SGD:S000119380

# input

#supercontig:EF1:DS178410:1:65833:1	Rfam	similarity	8482	8661	61.50	+	.	evalue=1.58e-16;gc-content=46;id=MIR807.1;model_end=176;model_start=1;rfam-acc=RF00886;rfam-id=MIR807;score=61.50

my $instance = "PRPRO";
my $user = "proteomes_prod";
my $pass = "<PASSWORD>";

my $dsn = "DBI:Oracle:$instance";
my $dbh = DBI->connect("$dsn",$user,$pass, {RaiseError => 1});
my $query = "select embl_feature_key, rfam_desc, biotype from proteomes.rfam_2_embl_classification where rfam_ac = ?";
my $sth = $dbh->prepare($query);

# Name => Name attribute
# Description: Note attribute
# ID => stable Id
# dbxref => Rfam for exple

my $algo = "ncRNA";
my $index = 1;<commit_msg>updated the mapping to ensembl biotype from rfamscan classification from oracle to mysql pan-1 server<commit_after>#!/sw/arch/bin/perl -w

use strict;
use FileHandle;
use DBI;

my $rfam_release = "10.1";

my $in_file = shift;
# prefix, e.g. the seq_region name to be received as a command-line argument
my $prefix = shift || "";

print STDERR "gene name prefix set to $prefix\n";

if (!defined $in_file) {
  die "input file not specified!\n";
}

# output

#chrI    SGD     ncRNA   99306   99869   .       +       .       ID=HRA1;Name=HRA1;gene=HRA1;Alias=HRA1;Ontology_term=GO:0003674,GO:0005575,GO:0000462;Note=Non-protein-coding%20RNA%2C%20substrate%20of%20RNase%20P%2C%20possibly%20involved%20in%20rRNA%20processing%2C%20specifically%20maturation%20of%2020S%20precursor%20into%20the%20mature%2018S%20rRNA;dbxref=SGD:S000119380
#chrI    SGD     noncoding_exon  99306   99869   .       +       .       Parent=HRA1;Name=HRA1;gene=HRA1;Alias=HRA1;Ontology_term=GO:0003674,GO:0005575,GO:0000462,SO:0000198;Note=Non-protein-coding%20RNA%2C%20substrate%20of%20RNase%20P%2C%20possibly%20involved%20in%20rRNA%20processing%2C%20specifically%20maturation%20of%2020S%20precursor%20into%20the%20mature%2018S%20rRNA;dbxref=SGD:S000119380

# input

#supercontig:EF1:DS178410:1:65833:1	Rfam	similarity	8482	8661	61.50	+	.	evalue=1.58e-16;gc-content=46;id=MIR807.1;model_end=176;model_start=1;rfam-acc=RF00886;rfam-id=MIR807;score=61.50

my $instance = "mysql-eg-pan-1.ebi.ac.uk";
my $port = 4276;
my $db_name = "ensembl_production";
my $user = "ensro";
my $pass = undef;

my $dsn = "DBI:mysql:database=$db_name;host=$instance;port=$port";
my $dbh = DBI->connect("$dsn",$user,$pass, {RaiseError => 1});
my $query = "select embl_feature_key, rfam_desc, biotype from rfam_2_ensembl_biotype where rfam_ac = ?";
my $sth = $dbh->prepare($query);

# Name => Name attribute
# Description: Note attribute
# ID => stable Id
# dbxref => Rfam for exple

my $algo = "ncRNA";
my $index = 1;
{'fraction_non_alphanumeric': 0.14429976082912568, 'fraction_numerical': 0.1334041987775711, 'mean_word_length': 5.906422018348624, 'pattern_counts': {'":': 0, '<': 4, '<?xml version=': 0, '>': 16, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2484425', 'n_tokens_mistral': 1912, 'n_tokens_neox': 1581, 'n_words': 249}