summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndreas Maunz <andreas@maunz.de>2012-10-01 17:35:21 +0200
committerAndreas Maunz <andreas@maunz.de>2012-10-01 17:35:21 +0200
commit34c6eb7840464d3d2b30982f4d51109faa1e8a3e (patch)
tree0da5e5c514be45f5d89b57971c00311963af5697
parentbdec94f5e190f0bd03b10bb88f351a13237cdabb (diff)
Fixed row parsingHEADmaster
-rw-r--r--lib/parser.rb3
-rw-r--r--lib/utils.rb3
2 files changed, 4 insertions, 2 deletions
diff --git a/lib/parser.rb b/lib/parser.rb
index 257d250..5ac934c 100644
--- a/lib/parser.rb
+++ b/lib/parser.rb
@@ -525,7 +525,8 @@ module OpenTox
end
def split_row(row)
- row.chomp.gsub(/["']/,'').split(/\s*[,;\t]\s*/,-1) # -1: do not skip empty cells
+ CSV.parse(row)[0]
+ #row.chomp.gsub(/["']/,'').split(/\s*[,;\t]\s*/,-1) # -1: do not skip empty cells
end
end
diff --git a/lib/utils.rb b/lib/utils.rb
index 555ac17..d34081b 100644
--- a/lib/utils.rb
+++ b/lib/utils.rb
@@ -312,7 +312,8 @@ module OpenTox
sdf_data = []
params[:compounds].each_with_index { |c_uri, c_idx|
cmpd = OpenTox::Compound.new(c_uri)
- LOGGER.debug "3D for #{cmpd.to_smiles}"
+ #LOGGER.debug "3D for #{cmpd.to_smiles}"
+ LOGGER.debug "3D for #{c_idx}"
obconv = OpenBabel::OBConversion.new
obmol = OpenBabel::OBMol.new
obconv.set_in_format("smi")