Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Iss7 #12

Merged
merged 9 commits into from
Apr 29, 2016
Merged

Iss7 #12

merged 9 commits into from
Apr 29, 2016

Conversation

dneise
Copy link
Member

@dneise dneise commented Feb 11, 2016

trying to solve issue #7

@maxnoe
Copy link
Member

maxnoe commented Feb 11, 2016

Should this really be in plotting? Maybe an own submodule like pixelmapping would make more sense? THis can then be used in plotting.

@dneise
Copy link
Member Author

dneise commented Feb 11, 2016

good question. get_pixel_coords is in plotting at the moment. But I have no strong opinion.

@maxnoe
Copy link
Member

maxnoe commented Feb 11, 2016

Yeah, i think because get_pixel_coords was not thought for outside use. But if this is a feature for users, it should not be in plotting.

__bias_to_trigger_patch_map = None

def bias_to_trigger_patch_map():
global __bias_to_trigger_patch_map
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this kind of caching? Better use from functools import lru_cache and @lru_cache

@dneise
Copy link
Member Author

dneise commented Apr 29, 2016

maybe we can merge this now.
But I have no idea if everything still works. We have no units tests, and I forgot what I should test manually.


@lru_cache(maxsize=1)
def bias_to_trigger_patch_map():
mapfile = res.resource_filename("fact", "resources/FACTmap111030.txt")
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You do not have to load the file again, it is in the namespace of this submodule

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

does this speak against merging?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah now I understand. Thanks ,... I'll use that

@dneise
Copy link
Member Author

dneise commented Apr 29, 2016

please don't merge yet

I need the credentials ... I would like to include them into this package now...

@maxnoe
Copy link
Member

maxnoe commented Apr 29, 2016

Ok

@dneise
Copy link
Member Author

dneise commented Apr 29, 2016

okay done

@maxnoe maxnoe merged commit 14dd0ef into master Apr 29, 2016
@maxnoe maxnoe deleted the iss7 branch April 29, 2016 15:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants