-
Notifications
You must be signed in to change notification settings - Fork 52
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update spectrogram creation to skip ones already created for an overl…
…apping range.
- Loading branch information
Showing
5 changed files
with
208 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
21 changes: 21 additions & 0 deletions
21
...priv/repo/migrations/20240910222932_update_audio_image_feed_segment_join_table_unique.exs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
defmodule Orcasite.Repo.Migrations.UpdateAudioImageFeedSegmentJoinTableUnique do | ||
@moduledoc """ | ||
Updates resources based on their most recent snapshots. | ||
This file was autogenerated with `mix ash_postgres.generate_migrations` | ||
""" | ||
|
||
use Ecto.Migration | ||
|
||
def up do | ||
create unique_index(:audio_image_feed_segments, [:feed_segment_id, :audio_image_id], | ||
name: "audio_image_feed_segments_unique_audio_image_index" | ||
) | ||
end | ||
|
||
def down do | ||
drop_if_exists unique_index(:audio_image_feed_segments, [:feed_segment_id, :audio_image_id], | ||
name: "audio_image_feed_segments_unique_audio_image_index" | ||
) | ||
end | ||
end |
171 changes: 171 additions & 0 deletions
171
server/priv/resource_snapshots/repo/audio_image_feed_segments/20240910222932.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,171 @@ | ||
{ | ||
"attributes": [ | ||
{ | ||
"allow_nil?": false, | ||
"default": "fragment(\"gen_random_uuid()\")", | ||
"generated?": false, | ||
"primary_key?": true, | ||
"references": null, | ||
"size": null, | ||
"source": "id", | ||
"type": "uuid" | ||
}, | ||
{ | ||
"allow_nil?": false, | ||
"default": "fragment(\"(now() AT TIME ZONE 'utc')\")", | ||
"generated?": false, | ||
"primary_key?": false, | ||
"references": null, | ||
"size": null, | ||
"source": "inserted_at", | ||
"type": "utc_datetime_usec" | ||
}, | ||
{ | ||
"allow_nil?": false, | ||
"default": "fragment(\"(now() AT TIME ZONE 'utc')\")", | ||
"generated?": false, | ||
"primary_key?": false, | ||
"references": null, | ||
"size": null, | ||
"source": "updated_at", | ||
"type": "utc_datetime_usec" | ||
}, | ||
{ | ||
"allow_nil?": true, | ||
"default": "nil", | ||
"generated?": false, | ||
"primary_key?": false, | ||
"references": { | ||
"deferrable": false, | ||
"destination_attribute": "id", | ||
"destination_attribute_default": null, | ||
"destination_attribute_generated": null, | ||
"index?": false, | ||
"match_type": null, | ||
"match_with": null, | ||
"multitenancy": { | ||
"attribute": null, | ||
"global": null, | ||
"strategy": null | ||
}, | ||
"name": "audio_image_feed_segments_feed_segment_id_fkey", | ||
"on_delete": null, | ||
"on_update": null, | ||
"primary_key?": true, | ||
"schema": null, | ||
"table": "feed_segments" | ||
}, | ||
"size": null, | ||
"source": "feed_segment_id", | ||
"type": "uuid" | ||
}, | ||
{ | ||
"allow_nil?": true, | ||
"default": "nil", | ||
"generated?": false, | ||
"primary_key?": false, | ||
"references": { | ||
"deferrable": false, | ||
"destination_attribute": "id", | ||
"destination_attribute_default": null, | ||
"destination_attribute_generated": null, | ||
"index?": false, | ||
"match_type": null, | ||
"match_with": null, | ||
"multitenancy": { | ||
"attribute": null, | ||
"global": null, | ||
"strategy": null | ||
}, | ||
"name": "audio_image_feed_segments_audio_image_id_fkey", | ||
"on_delete": null, | ||
"on_update": null, | ||
"primary_key?": true, | ||
"schema": null, | ||
"table": "audio_images" | ||
}, | ||
"size": null, | ||
"source": "audio_image_id", | ||
"type": "uuid" | ||
} | ||
], | ||
"base_filter": null, | ||
"check_constraints": [], | ||
"custom_indexes": [ | ||
{ | ||
"all_tenants?": false, | ||
"concurrently": false, | ||
"error_fields": [ | ||
"feed_segment_id" | ||
], | ||
"fields": [ | ||
{ | ||
"type": "atom", | ||
"value": "feed_segment_id" | ||
} | ||
], | ||
"include": null, | ||
"message": null, | ||
"name": null, | ||
"nulls_distinct": true, | ||
"prefix": null, | ||
"table": null, | ||
"unique": false, | ||
"using": null, | ||
"where": null | ||
}, | ||
{ | ||
"all_tenants?": false, | ||
"concurrently": false, | ||
"error_fields": [ | ||
"audio_image_id" | ||
], | ||
"fields": [ | ||
{ | ||
"type": "atom", | ||
"value": "audio_image_id" | ||
} | ||
], | ||
"include": null, | ||
"message": null, | ||
"name": null, | ||
"nulls_distinct": true, | ||
"prefix": null, | ||
"table": null, | ||
"unique": false, | ||
"using": null, | ||
"where": null | ||
} | ||
], | ||
"custom_statements": [], | ||
"has_create_action": true, | ||
"hash": "D8A1FF82B91190958A59F7146B9D440787938C57346C22CB8B90BF3DF6A76D5A", | ||
"identities": [ | ||
{ | ||
"all_tenants?": false, | ||
"base_filter": null, | ||
"index_name": "audio_image_feed_segments_unique_audio_image_index", | ||
"keys": [ | ||
{ | ||
"type": "atom", | ||
"value": "feed_segment_id" | ||
}, | ||
{ | ||
"type": "atom", | ||
"value": "audio_image_id" | ||
} | ||
], | ||
"name": "unique_audio_image", | ||
"nils_distinct?": true, | ||
"where": null | ||
} | ||
], | ||
"multitenancy": { | ||
"attribute": null, | ||
"global": null, | ||
"strategy": null | ||
}, | ||
"repo": "Elixir.Orcasite.Repo", | ||
"schema": null, | ||
"table": "audio_image_feed_segments" | ||
} |