ref test
This commit is contained in:
parent
6f7b2c9ec6
commit
05e8b9a15d
@ -2,8 +2,6 @@
|
||||
<project version="4">
|
||||
<component name="ChangeListManager">
|
||||
<list default="true" id="f410c5c2-3ffe-4260-93eb-e3d83256d263" name="Default Changelist" comment="">
|
||||
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/camera.py" beforeDir="false" afterPath="$PROJECT_DIR$/camera.py" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/index.py" beforeDir="false" afterPath="$PROJECT_DIR$/index.py" afterDir="false" />
|
||||
</list>
|
||||
<option name="EXCLUDED_CONVERTED_TO_IGNORED" value="true" />
|
||||
@ -14,11 +12,11 @@
|
||||
</component>
|
||||
<component name="FileEditorManager">
|
||||
<leaf SIDE_TABS_SIZE_LIMIT_KEY="300">
|
||||
<file pinned="false" current-in-tab="false">
|
||||
<file pinned="false" current-in-tab="true">
|
||||
<entry file="file://$PROJECT_DIR$/index.py">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="540">
|
||||
<caret line="36" column="67" selection-start-line="36" selection-start-column="67" selection-end-line="36" selection-end-column="67" />
|
||||
<state relative-caret-position="360">
|
||||
<caret line="36" column="72" selection-start-line="36" selection-start-column="72" selection-end-line="36" selection-end-column="72" />
|
||||
<folding>
|
||||
<element signature="e#0#21#0" expanded="true" />
|
||||
</folding>
|
||||
@ -36,7 +34,7 @@
|
||||
<provider selected="true" editor-type-id="images" />
|
||||
</entry>
|
||||
</file>
|
||||
<file pinned="false" current-in-tab="true">
|
||||
<file pinned="false" current-in-tab="false">
|
||||
<entry file="file://$PROJECT_DIR$/camera.py">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="165">
|
||||
@ -119,8 +117,8 @@
|
||||
<option value="$PROJECT_DIR$/image_tools.py" />
|
||||
<option value="$PROJECT_DIR$/example.env" />
|
||||
<option value="$PROJECT_DIR$/.env" />
|
||||
<option value="$PROJECT_DIR$/index.py" />
|
||||
<option value="$PROJECT_DIR$/camera.py" />
|
||||
<option value="$PROJECT_DIR$/index.py" />
|
||||
</list>
|
||||
</option>
|
||||
</component>
|
||||
@ -198,7 +196,7 @@
|
||||
<window_info anchor="bottom" id="Inspection" order="5" weight="0.4" />
|
||||
<window_info anchor="bottom" id="TODO" order="6" />
|
||||
<window_info anchor="bottom" id="Version Control" order="7" />
|
||||
<window_info anchor="bottom" id="Terminal" order="8" weight="0.32972974" />
|
||||
<window_info active="true" anchor="bottom" id="Terminal" order="8" visible="true" weight="0.32972974" />
|
||||
<window_info anchor="bottom" id="Python Console" order="9" />
|
||||
<window_info anchor="bottom" id="Event Log" order="10" side_tool="true" />
|
||||
<window_info anchor="right" id="Commander" internal_type="SLIDING" order="0" type="SLIDING" weight="0.4" />
|
||||
@ -272,16 +270,6 @@
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/index.py">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="540">
|
||||
<caret line="36" column="67" selection-start-line="36" selection-start-column="67" selection-end-line="36" selection-end-column="67" />
|
||||
<folding>
|
||||
<element signature="e#0#21#0" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/camera.py">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="165">
|
||||
@ -292,5 +280,15 @@
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/index.py">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="360">
|
||||
<caret line="36" column="72" selection-start-line="36" selection-start-column="72" selection-end-line="36" selection-end-column="72" />
|
||||
<folding>
|
||||
<element signature="e#0#21#0" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
</component>
|
||||
</project>
|
2
index.py
2
index.py
@ -34,7 +34,7 @@ def poll():
|
||||
|
||||
for stall in doc_ref_stalls:
|
||||
stall_obj = stall.to_dict()
|
||||
color_reference = image_tools.average_color(75, 400, 50, 50, reference)
|
||||
color_reference = image_tools.average_color(75, 400, 50, 50, img)
|
||||
color_compare = image_tools.average_color(stall_obj['locationX'], stall_obj['locationY'], stall_obj['width'], stall_obj['height'], img)
|
||||
stall_occupied = image_tools.threshold(image_tools.differences(color_reference, color_compare), float(os.getenv('E_HAT_TRIGGER_LEVEL')))
|
||||
stall_obj['open'] = not stall_occupied
|
||||
|
Loading…
Reference in New Issue
Block a user