Skip to content

Commit b69f651

Browse files
committed
test with customer model, working
1 parent 19f6863 commit b69f651

File tree

6 files changed

+180
-3
lines changed

6 files changed

+180
-3
lines changed
Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<Scheme
3+
LastUpgradeVersion = "1520"
4+
version = "1.7">
5+
<BuildAction
6+
parallelizeBuildables = "YES"
7+
buildImplicitDependencies = "YES">
8+
</BuildAction>
9+
<TestAction
10+
buildConfiguration = "Debug"
11+
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
12+
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
13+
shouldUseLaunchSchemeArgsEnv = "YES"
14+
shouldAutocreateTestPlan = "YES">
15+
<Testables>
16+
<TestableReference
17+
skipped = "NO">
18+
<BuildableReference
19+
BuildableIdentifier = "primary"
20+
BlueprintIdentifier = "RoboflowTests"
21+
BuildableName = "RoboflowTests"
22+
BlueprintName = "RoboflowTests"
23+
ReferencedContainer = "container:">
24+
</BuildableReference>
25+
</TestableReference>
26+
</Testables>
27+
</TestAction>
28+
<LaunchAction
29+
buildConfiguration = "Debug"
30+
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
31+
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
32+
launchStyle = "0"
33+
useCustomWorkingDirectory = "NO"
34+
ignoresPersistentStateOnLaunch = "NO"
35+
debugDocumentVersioning = "YES"
36+
debugServiceExtension = "internal"
37+
allowLocationSimulation = "YES">
38+
</LaunchAction>
39+
<ProfileAction
40+
buildConfiguration = "Release"
41+
shouldUseLaunchSchemeArgsEnv = "YES"
42+
savedToolIdentifier = ""
43+
useCustomWorkingDirectory = "NO"
44+
debugDocumentVersioning = "YES">
45+
</ProfileAction>
46+
<AnalyzeAction
47+
buildConfiguration = "Debug">
48+
</AnalyzeAction>
49+
<ArchiveAction
50+
buildConfiguration = "Release"
51+
revealArchiveInOrganizer = "YES">
52+
</ArchiveAction>
53+
</Scheme>
Lines changed: 92 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,92 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<Scheme
3+
LastUpgradeVersion = "1520"
4+
version = "1.7">
5+
<BuildAction
6+
parallelizeBuildables = "YES"
7+
buildImplicitDependencies = "YES">
8+
<BuildActionEntries>
9+
<BuildActionEntry
10+
buildForTesting = "YES"
11+
buildForRunning = "YES"
12+
buildForProfiling = "YES"
13+
buildForArchiving = "YES"
14+
buildForAnalyzing = "YES">
15+
<BuildableReference
16+
BuildableIdentifier = "primary"
17+
BlueprintIdentifier = "Roboflow"
18+
BuildableName = "Roboflow"
19+
BlueprintName = "Roboflow"
20+
ReferencedContainer = "container:">
21+
</BuildableReference>
22+
</BuildActionEntry>
23+
<BuildActionEntry
24+
buildForTesting = "YES"
25+
buildForRunning = "YES"
26+
buildForProfiling = "NO"
27+
buildForArchiving = "NO"
28+
buildForAnalyzing = "YES">
29+
<BuildableReference
30+
BuildableIdentifier = "primary"
31+
BlueprintIdentifier = "RoboflowTests"
32+
BuildableName = "RoboflowTests"
33+
BlueprintName = "RoboflowTests"
34+
ReferencedContainer = "container:">
35+
</BuildableReference>
36+
</BuildActionEntry>
37+
</BuildActionEntries>
38+
</BuildAction>
39+
<TestAction
40+
buildConfiguration = "Debug"
41+
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
42+
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
43+
shouldUseLaunchSchemeArgsEnv = "YES"
44+
shouldAutocreateTestPlan = "YES">
45+
<Testables>
46+
<TestableReference
47+
skipped = "NO">
48+
<BuildableReference
49+
BuildableIdentifier = "primary"
50+
BlueprintIdentifier = "RoboflowTests"
51+
BuildableName = "RoboflowTests"
52+
BlueprintName = "RoboflowTests"
53+
ReferencedContainer = "container:">
54+
</BuildableReference>
55+
</TestableReference>
56+
</Testables>
57+
</TestAction>
58+
<LaunchAction
59+
buildConfiguration = "Debug"
60+
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
61+
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
62+
launchStyle = "0"
63+
useCustomWorkingDirectory = "NO"
64+
ignoresPersistentStateOnLaunch = "NO"
65+
debugDocumentVersioning = "YES"
66+
debugServiceExtension = "internal"
67+
allowLocationSimulation = "YES">
68+
</LaunchAction>
69+
<ProfileAction
70+
buildConfiguration = "Release"
71+
shouldUseLaunchSchemeArgsEnv = "YES"
72+
savedToolIdentifier = ""
73+
useCustomWorkingDirectory = "NO"
74+
debugDocumentVersioning = "YES">
75+
<MacroExpansion>
76+
<BuildableReference
77+
BuildableIdentifier = "primary"
78+
BlueprintIdentifier = "Roboflow"
79+
BuildableName = "Roboflow"
80+
BlueprintName = "Roboflow"
81+
ReferencedContainer = "container:">
82+
</BuildableReference>
83+
</MacroExpansion>
84+
</ProfileAction>
85+
<AnalyzeAction
86+
buildConfiguration = "Debug">
87+
</AnalyzeAction>
88+
<ArchiveAction
89+
buildConfiguration = "Release"
90+
revealArchiveInOrganizer = "YES">
91+
</ArchiveAction>
92+
</Scheme>

Package.swift

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ let package = Package(
1717
.target(
1818
name: "Roboflow",
1919
path: "Sources/Roboflow"
20-
)
20+
),
21+
.testTarget(name:"RoboflowTests", dependencies: ["Roboflow"])
2122
]
2223
)

Roboflow.podspec

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
Pod::Spec.new do |spec|
22
spec.name = "Roboflow"
3-
spec.version = "1.0.3"
3+
spec.version = "1.1.6"
44
spec.platform = :ios, '15.2'
55
spec.ios.deployment_target = '15.2'
66
spec.summary = "A framework for interfacing with Roboflow"

Sources/Roboflow/Classes/RFObjectDetectionModel.swift

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ import Foundation
99
import CoreML
1010
import Vision
1111
import UIKit
12-
1312
//Creates an instance of an ML model that's hosted on Roboflow
1413
public class RFObjectDetectionModel: NSObject {
1514

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
//
2+
// LoadModel.swift
3+
//
4+
//
5+
// Created by Maxwell Stone on 8/10/23.
6+
//
7+
8+
import XCTest
9+
import Roboflow
10+
11+
// cash counter api_key (already public)
12+
var API_KEY = "fEto4us79wdzRJ2jkO6U"
13+
14+
final class LoadModel: XCTestCase {
15+
var model: RFObjectDetectionModel?
16+
17+
override func setUpWithError() throws {
18+
// Put setup code here. This method is called before the invocation of each test method in the class.
19+
}
20+
21+
override func tearDownWithError() throws {
22+
// Put teardown code here. This method is called after the invocation of each test method in the class.
23+
}
24+
25+
func testLoadModel() async {
26+
let rf = RoboflowMobile(apiKey: API_KEY)
27+
let (model, error, str1, str2) = await rf.load(model: "playing-cards-ow27d", modelVersion: 2)
28+
self.model = model
29+
XCTAssertNil(error)
30+
}
31+
32+
}

0 commit comments

Comments
 (0)