mirror of
https://github.com/immich-app/immich
synced 2025-10-17 18:19:27 +00:00
feat(web,server)!: configure machine learning via the UI (#3768)
This commit is contained in:
parent
2cccef174a
commit
8211afb726
52 changed files with 831 additions and 649 deletions
44
mobile/openapi/lib/model/server_features_dto.dart
generated
44
mobile/openapi/lib/model/server_features_dto.dart
generated
|
|
@ -13,14 +13,19 @@ part of openapi.api;
|
|||
class ServerFeaturesDto {
|
||||
/// Returns a new [ServerFeaturesDto] instance.
|
||||
ServerFeaturesDto({
|
||||
required this.machineLearning,
|
||||
required this.clipEncode,
|
||||
required this.facialRecognition,
|
||||
required this.oauth,
|
||||
required this.oauthAutoLaunch,
|
||||
required this.passwordLogin,
|
||||
required this.search,
|
||||
required this.sidecar,
|
||||
required this.tagImage,
|
||||
});
|
||||
|
||||
bool machineLearning;
|
||||
bool clipEncode;
|
||||
|
||||
bool facialRecognition;
|
||||
|
||||
bool oauth;
|
||||
|
||||
|
|
@ -30,33 +35,46 @@ class ServerFeaturesDto {
|
|||
|
||||
bool search;
|
||||
|
||||
bool sidecar;
|
||||
|
||||
bool tagImage;
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) => identical(this, other) || other is ServerFeaturesDto &&
|
||||
other.machineLearning == machineLearning &&
|
||||
other.clipEncode == clipEncode &&
|
||||
other.facialRecognition == facialRecognition &&
|
||||
other.oauth == oauth &&
|
||||
other.oauthAutoLaunch == oauthAutoLaunch &&
|
||||
other.passwordLogin == passwordLogin &&
|
||||
other.search == search;
|
||||
other.search == search &&
|
||||
other.sidecar == sidecar &&
|
||||
other.tagImage == tagImage;
|
||||
|
||||
@override
|
||||
int get hashCode =>
|
||||
// ignore: unnecessary_parenthesis
|
||||
(machineLearning.hashCode) +
|
||||
(clipEncode.hashCode) +
|
||||
(facialRecognition.hashCode) +
|
||||
(oauth.hashCode) +
|
||||
(oauthAutoLaunch.hashCode) +
|
||||
(passwordLogin.hashCode) +
|
||||
(search.hashCode);
|
||||
(search.hashCode) +
|
||||
(sidecar.hashCode) +
|
||||
(tagImage.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'ServerFeaturesDto[machineLearning=$machineLearning, oauth=$oauth, oauthAutoLaunch=$oauthAutoLaunch, passwordLogin=$passwordLogin, search=$search]';
|
||||
String toString() => 'ServerFeaturesDto[clipEncode=$clipEncode, facialRecognition=$facialRecognition, oauth=$oauth, oauthAutoLaunch=$oauthAutoLaunch, passwordLogin=$passwordLogin, search=$search, sidecar=$sidecar, tagImage=$tagImage]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
json[r'machineLearning'] = this.machineLearning;
|
||||
json[r'clipEncode'] = this.clipEncode;
|
||||
json[r'facialRecognition'] = this.facialRecognition;
|
||||
json[r'oauth'] = this.oauth;
|
||||
json[r'oauthAutoLaunch'] = this.oauthAutoLaunch;
|
||||
json[r'passwordLogin'] = this.passwordLogin;
|
||||
json[r'search'] = this.search;
|
||||
json[r'sidecar'] = this.sidecar;
|
||||
json[r'tagImage'] = this.tagImage;
|
||||
return json;
|
||||
}
|
||||
|
||||
|
|
@ -68,11 +86,14 @@ class ServerFeaturesDto {
|
|||
final json = value.cast<String, dynamic>();
|
||||
|
||||
return ServerFeaturesDto(
|
||||
machineLearning: mapValueOfType<bool>(json, r'machineLearning')!,
|
||||
clipEncode: mapValueOfType<bool>(json, r'clipEncode')!,
|
||||
facialRecognition: mapValueOfType<bool>(json, r'facialRecognition')!,
|
||||
oauth: mapValueOfType<bool>(json, r'oauth')!,
|
||||
oauthAutoLaunch: mapValueOfType<bool>(json, r'oauthAutoLaunch')!,
|
||||
passwordLogin: mapValueOfType<bool>(json, r'passwordLogin')!,
|
||||
search: mapValueOfType<bool>(json, r'search')!,
|
||||
sidecar: mapValueOfType<bool>(json, r'sidecar')!,
|
||||
tagImage: mapValueOfType<bool>(json, r'tagImage')!,
|
||||
);
|
||||
}
|
||||
return null;
|
||||
|
|
@ -120,11 +141,14 @@ class ServerFeaturesDto {
|
|||
|
||||
/// The list of required keys that must be present in a JSON.
|
||||
static const requiredKeys = <String>{
|
||||
'machineLearning',
|
||||
'clipEncode',
|
||||
'facialRecognition',
|
||||
'oauth',
|
||||
'oauthAutoLaunch',
|
||||
'passwordLogin',
|
||||
'search',
|
||||
'sidecar',
|
||||
'tagImage',
|
||||
};
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue