Skip to content

Commit

Permalink
Doing some minor cleanup (#364)
Browse files Browse the repository at this point in the history
  • Loading branch information
mwatts15 committed Jan 19, 2019
1 parent d6ab109 commit 2ecbb70
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 15 deletions.
2 changes: 1 addition & 1 deletion LICENSE.txt
@@ -1,6 +1,6 @@
The MIT License (MIT)

Copyright (c) 2014-2018 OpenWorm
Copyright (c) 2014-2019 OpenWorm

Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
Expand Down
15 changes: 5 additions & 10 deletions PyOpenWorm/data_trans/data_with_evidence_ds.py
Expand Up @@ -38,17 +38,14 @@ def __init__(self, *args, **kwargs):
self.__ad_hoc_contexts = dict()

self.data_context = _DataContext.contextualize(self.context)(maker=self,
imported=(CONTEXT,),
conf=self.conf)
imported=(CONTEXT,))

self.evidence_context = _EvidenceContext.contextualize(self.context)(maker=self,
imported=(CONTEXT,),
conf=self.conf)
imported=(CONTEXT,))

self.combined_context = _CombinedContext.contextualize(self.context)(maker=self,
imported=(self.data_context,
self.evidence_context),
conf=self.conf)
self.evidence_context))

def data_context_for(self, **kwargs):
ctx = self.context_for(**kwargs)
Expand All @@ -67,16 +64,14 @@ def context_for(self, **kwargs):
def commit_augment(self):
saved_contexts = set([])
self.data_context.save_context(inline_imports=True, saved_contexts=saved_contexts)
# self.data_context.save_imports()
self.evidence_context.save_context(inline_imports=True, saved_contexts=saved_contexts)
# self.evidence_context.save_imports()
print(self.combined_context)
self.combined_context.save_imports()


class _SContext(Context):
def __init__(self, maker, **kwargs):
super(_SContext, self).__init__(**kwargs)
conf = kwargs.pop('conf', maker.conf)
super(_SContext, self).__init__(conf=conf, **kwargs)
self.maker = maker

@property
Expand Down
3 changes: 1 addition & 2 deletions PyOpenWorm/data_trans/excel_ds.py
Expand Up @@ -7,6 +7,5 @@
class XLSXHTTPFileDataSource(HTTPFileDataSource):
rdf_namespace = Namespace(DS_NS['XLSXHTTPFileDataSource#'])

# column_headers = Informational(display_name='Header column names', multiple=False)

# csv_field_delimiter = Informational(display_name='Field delimiter')
__yarom_mapped_classes__ = (XLSXHTTPFileDataSource,)
2 changes: 0 additions & 2 deletions PyOpenWorm/data_trans/sci_rna_seq.py
@@ -1,5 +1,3 @@
#!/home/ubuntu/env/bin/python

from rpy2.robjects.packages import importr
from rpy2.robjects import r as R
from PyOpenWorm.datasource import DataTranslator, DataSource, Informational
Expand Down

0 comments on commit 2ecbb70

Please sign in to comment.